
* separated the execution part of command code into interface part and internal part to better see which checks are done and when (fixes problem where 'nocommand' mapflag blocked server npcs) * moved the internal commands list (array) to the end of the file, this let me discard that long block of ACMD_FUNC() declarations * removed enum AtCommandType from command headers and commands array; its purpose was perhaps to identify aliased commands, but apparently it was never finished because the rest of the code doesn't use it (also doing aliases like this is not a very good idea) * internally, commands are now referenced to using their function name * removed the @/# symbols from the command lists; all lookup functions will now properly deal with strings with- and without a command symbol (commands interface still requires the symbol tho', so TODO for later) * removed several unneeded commands (*id2 code, dmalloc debug commands) * reverted atcommand config from alphabetically-sorted to how it was before (with additional fixes; see /conf changelog) * added missing code for #dropall / #storeall * added a warning when trying to set gm level of an undefined command The structure of the commands table has changed, please adjust docs/guides to match the new format (sorry for the inconvenience). git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@11607 54d463be-8e91-2dee-dedb-b68131a5f0ec
20 lines
677 B
C
20 lines
677 B
C
// Copyright (c) Athena Dev Teams - Licensed under GNU GPL
|
|
// For more information, see LICENCE in the main folder
|
|
|
|
#ifndef _CHARCOMMAND_H_
|
|
#define _CHARCOMMAND_H_
|
|
|
|
//#include "map.h"
|
|
struct map_session_data;
|
|
|
|
extern char charcommand_symbol;
|
|
typedef int (*CharCommandFunc)(const int fd, struct map_session_data* sd, const char* command, const char* message);
|
|
|
|
bool is_charcommand(const int fd, struct map_session_data* sd, const char* message);
|
|
bool is_charcommand_sub(const int fd, struct map_session_data* sd, const char* str, int gmlvl);
|
|
int get_charcommand_level(const CharCommandFunc func);
|
|
|
|
int charcommand_config_read(const char* cfgName);
|
|
|
|
#endif /* _CHARCOMMAND_H_ */
|