mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Delay initialization of ACE_Modules until settings are properly setup
This commit is contained in:
parent
d46074ad27
commit
333cb80171
@ -264,6 +264,9 @@ GVAR(commonPostInited) = true;
|
||||
|
||||
diag_log text format["[ACE] Settings received from server"];
|
||||
|
||||
// Event so that ACE_Modules have their settings loaded:
|
||||
["InitSettingsFromModules", []] call FUNC(localEvent);
|
||||
|
||||
// Load user settings from profile
|
||||
if (hasInterface) then {
|
||||
call FUNC(loadSettingsFromProfile);
|
||||
|
@ -1,6 +1,7 @@
|
||||
|
||||
#include "script_component.hpp"
|
||||
|
||||
["InitSettingsFromModules", {
|
||||
// TODO This is a basic and limited implementation that mimics some of the functionality from the A3 module framework, but not all of it.
|
||||
// We have to execute this in the postInit XEH because on object init, the parameters of the modules are not yet available. They are if we execute it at the start of postInit execution.
|
||||
{
|
||||
@ -42,3 +43,4 @@
|
||||
};
|
||||
};
|
||||
}foreach GVAR(moduleInitCollection);
|
||||
}] call FUNC(addEventhandler);
|
||||
|
Loading…
Reference in New Issue
Block a user