diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/echar/init.c | 1 | ||||
-rw-r--r-- | src/ecommon/init.c | 16 | ||||
-rw-r--r-- | src/ecommon/init.h | 1 | ||||
-rw-r--r-- | src/elogin/init.c | 1 | ||||
-rw-r--r-- | src/emap/init.c | 1 |
5 files changed, 20 insertions, 0 deletions
diff --git a/src/echar/init.c b/src/echar/init.c index e40395c..e876065 100644 --- a/src/echar/init.c +++ b/src/echar/init.c @@ -79,6 +79,7 @@ HPExport void server_preinit (void) HPExport void server_online (void) { + common_online(); } HPExport void plugin_final (void) diff --git a/src/ecommon/init.c b/src/ecommon/init.c index 372e5ad..d91792e 100644 --- a/src/ecommon/init.c +++ b/src/ecommon/init.c @@ -33,3 +33,19 @@ void commonClean(void) aFree(mapindex->default_map); mapindex->default_map = NULL; } + +#define checkVar(name, value) \ + if (name != value) \ + { \ + ShowError(#name" wrong value. Found %d but must be %d.\n", \ + name, \ + value); \ + } + +void common_online(void) +{ + checkVar(MAX_SKILL, 1500); + checkVar(MAX_SKILL_ID, 10037); + checkVar(SC_MAX, 647); + checkVar(SI_MAX, 971); +} diff --git a/src/ecommon/init.h b/src/ecommon/init.h index 8e17b08..72a2e8f 100644 --- a/src/ecommon/init.h +++ b/src/ecommon/init.h @@ -7,5 +7,6 @@ void interfaces_init_common(void); void setDefaultMap(void); void commonClean(void); +void common_online(void); #endif // EVOL_COMMON_INTERFACES diff --git a/src/elogin/init.c b/src/elogin/init.c index d420cba..af725a0 100644 --- a/src/elogin/init.c +++ b/src/elogin/init.c @@ -61,6 +61,7 @@ HPExport void server_preinit (void) HPExport void server_online (void) { + common_online(); } HPExport void plugin_final (void) diff --git a/src/emap/init.c b/src/emap/init.c index 0882db6..f03bcd8 100644 --- a/src/emap/init.c +++ b/src/emap/init.c @@ -314,6 +314,7 @@ HPExport void server_online (void) { do_init_craft(); do_init_craftconf(); + common_online(); } HPExport void plugin_final (void) |