summaryrefslogtreecommitdiff
path: root/src/map/atcommand.h
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2013-05-02 17:14:01 -0300
committershennetsind <ind@henn.et>2013-05-02 17:14:01 -0300
commita2c45a8db6d724b98ab41fe9e75e1f7ea7523d5d (patch)
tree710a44f94cceff2f0198211d21ddfbe99b66f02c /src/map/atcommand.h
parent219a4f5267b33349649f952266532a132a48c2a3 (diff)
downloadhercules-a2c45a8db6d724b98ab41fe9e75e1f7ea7523d5d.tar.gz
hercules-a2c45a8db6d724b98ab41fe9e75e1f7ea7523d5d.tar.bz2
hercules-a2c45a8db6d724b98ab41fe9e75e1f7ea7523d5d.tar.xz
hercules-a2c45a8db6d724b98ab41fe9e75e1f7ea7523d5d.zip
Introducing Hercules Plugin Mananger
http://hercules.ws/board/topic/549-introducing-hercules-plugin-manager/ Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src/map/atcommand.h')
-rw-r--r--src/map/atcommand.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/map/atcommand.h b/src/map/atcommand.h
index cea59a416..f09b1f2b8 100644
--- a/src/map/atcommand.h
+++ b/src/map/atcommand.h
@@ -5,6 +5,8 @@
#ifndef _ATCOMMAND_H_
#define _ATCOMMAND_H_
+#include "../common/db.h"
+
/**
* Declarations
**/
@@ -66,14 +68,19 @@ struct atcommand_interface {
/* atcommand binding */
struct atcmd_binding_data** binding;
int binding_count;
+ unsigned int *group_ids;
+ /* other vars */
+ DBMap* db; //name -> AtCommandInfo
+ DBMap* alias_db; //alias -> AtCommandInfo
/* */
void (*init) (void);
void (*final) (void);
/* */
bool (*parse) (const int fd, struct map_session_data* sd, const char* message, int type);
+ bool (*create) (char *name, AtCommandFunc func);
bool (*can_use) (struct map_session_data *sd, const char *command);
bool (*can_use2) (struct map_session_data *sd, const char *command, AtCommandType type);
- void (*load_groups) (int* group_ids);
+ void (*load_groups) (void);
AtCommandInfo* (*exists) (const char* name);
int (*msg_read) (const char* cfgName);
void (*final_msg) (void);
@@ -85,5 +92,8 @@ struct atcommand_interface *atcommand;
const char* msg_txt(int msg_number);
void atcommand_defaults(void);
+/* stay here */
+#define ACMD(x) static bool atcommand_ ## x (const int fd, struct map_session_data* sd, const char* command, const char* message, struct AtCommandInfo *info)
+#define ACMD_A(x) atcommand_ ## x
#endif /* _ATCOMMAND_H_ */