summaryrefslogtreecommitdiff
path: root/src/map/atcommand.h
diff options
context:
space:
mode:
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_ */