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.h14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/map/atcommand.h b/src/map/atcommand.h
index 8d0399f25..c1f451ad3 100644
--- a/src/map/atcommand.h
+++ b/src/map/atcommand.h
@@ -22,6 +22,9 @@ struct block_list;
#define ATCOMMAND_LENGTH 50
#define MAX_MSG 1500
#define msg_txt(idx) atcommand->msg(idx)
+#define msg_sd(sd,msg_number) atcommand->msgsd((sd),(msg_number))
+#define msg_fd(fd,msg_number) atcommand->msgfd((fd),(msg_number))
+
/**
* Enumerations
**/
@@ -74,8 +77,12 @@ struct atcommand_interface {
/* other vars */
DBMap* db; //name -> AtCommandInfo
DBMap* alias_db; //alias -> AtCommandInfo
- /* */
- char* msg_table[MAX_MSG]; // Server messages (0-499 reserved for GM commands, 500-999 reserved for others)
+ /**
+ * msg_table[lang_id][msg_id]
+ * Server messages (0-499 reserved for GM commands, 500-999 reserved for others)
+ **/
+ char*** msg_table;
+ uint8 max_message_table;
/* */
void (*init) (bool minimal);
void (*final) (void);
@@ -112,6 +119,9 @@ struct atcommand_interface {
void (*base_commands) (void);
bool (*add) (char *name, AtCommandFunc func, bool replace);
const char* (*msg) (int msg_number);
+ void (*expand_message_table) (void);
+ const char* (*msgfd) (int fd, int msg_number);
+ const char* (*msgsd) (struct map_session_data *sd, int msg_number);
};
struct atcommand_interface *atcommand;