Closed AbyssMorgan closed 8 years ago
Performing hook on OnFilterScriptInit and OnGameModeInit provided #if defined FILTERSCRIPT is not necessary. The server performs only one callback, depending on the type of script. Therefore both callbacks use is not a problem.
No. The server performs "OnGameModeInit" for every script.
Second suggestion if you could add other detection systems commands :)
Not all command processors use "CMD" macros.
Run this script as a gamemode and then as filterscript :D
main(){ printf("main"); }
public OnFilterScriptInit(){ printf("script"); return 1; }
public OnGameModeInit(){ printf("gamemode"); return 1; }
gamemode: [19:59:44] gamemode [19:59:44] main filterscript: [20:00:59] script [20:00:59] gamemode
Performing hook on OnFilterScriptInit and OnGameModeInit provided #if defined FILTERSCRIPT is not necessary. The server performs only one callback, depending on the type of script. Therefore both callbacks use is not a problem.
Second suggestion if you could add other detection systems commands :)
if defined CMD
endif