API:SetCheckForCircularDependencies
From RoR Wiki
UI Lua API · Interface functions
Version: WAR 1.4.8
Turns load-order tracking for UI module initialization on or off. With it on, circular-dependency errors include the load order.
SetCheckForCircularDependencies(enabled)
Arguments
- enabled
boolean–trueto track the load order while modules are initialized.
Returns
Nothing.
Details
- The flag is read by ModulesInitializeAllEnabled and ModuleInitialize. When it is set, the client keeps a list of the modules it is currently initializing.
- Circular dependencies are detected either way. The flag only changes the error text: with tracking on, the message
Error Loading UiMod %s: Circular Dependency detected with %s. Load Order = %sends with the chain of module names in parentheses, joined by->. With tracking off it ends withNot Tracked. - The flag is off when the client starts. GetCheckForCircularDependencies returns the current value.
enabledmust be a real boolean. Passingnilor a number raises an Invalid Parameters error.- The stock UI never calls this function.
Errors
None besides the Invalid Parameters argument check.
Example
A minimal example built from the signature:
SetCheckForCircularDependencies( true ) ModulesInitializeAllEnabled()
