#ifndef STATIC_H
#define STATIC_H
-void __static_init_early() { }
-void __static_init() { CALL_ACCUMULATED_FUNCTION(__static_init_early); }
+void __static_init() { }
#define static_init() CALL_ACCUMULATED_FUNCTION(__static_init)
-#define REGISTER_REGISTRY(func) ACCUMULATE_FUNCTION(__static_init_early, func)
+void __static_init_late() { }
+#define static_init_late() CALL_ACCUMULATED_FUNCTION(__static_init_late)
+
+#define REGISTER_REGISTRY(func) ACCUMULATE_FUNCTION(__static_init, func)
#define _STATIC_INIT(where, func) \
void _static_##func(); \
ACCUMULATE_FUNCTION(where, _static_##func) \
void _static_##func()
-#define STATIC_INIT(func) _STATIC_INIT(__static_init_early, func##_early)
-#define STATIC_INIT_LATE(func) _STATIC_INIT(__static_init, func)
+#define STATIC_INIT(func) _STATIC_INIT(__static_init, func)
+#define STATIC_INIT_LATE(func) _STATIC_INIT(__static_init_late, func##_late)
#endif
// needs to be done so early because of the constants they create
static_init();
+ static_init_late();
MapInfo_Enumerate();
MapInfo_FilterGametype(MapInfo_CurrentGametype(), MapInfo_CurrentFeatures(), MapInfo_RequiredFlags(), MapInfo_ForbiddenFlags(), 0);
// needs to be done so early because of the constants they create
static_init();
+ static_init_late();
ServerProgsDB = db_load(strcat("server.db", autocvar_sessionid));