Move singleton management from ProjectSettings to Engine
This commit is contained in:
parent
3732b2318e
commit
9b7b46143d
25 changed files with 130 additions and 109 deletions
|
|
@ -29,6 +29,7 @@
|
|||
/*************************************************************************/
|
||||
#include "gd_script.h"
|
||||
|
||||
#include "engine.h"
|
||||
#include "gd_compiler.h"
|
||||
#include "global_constants.h"
|
||||
#include "io/file_access_encrypted.h"
|
||||
|
|
@ -1347,9 +1348,9 @@ void GDScriptLanguage::init() {
|
|||
|
||||
//populate singletons
|
||||
|
||||
List<ProjectSettings::Singleton> singletons;
|
||||
ProjectSettings::get_singleton()->get_singletons(&singletons);
|
||||
for (List<ProjectSettings::Singleton>::Element *E = singletons.front(); E; E = E->next()) {
|
||||
List<Engine::Singleton> singletons;
|
||||
Engine::get_singleton()->get_singletons(&singletons);
|
||||
for (List<Engine::Singleton>::Element *E = singletons.front(); E; E = E->next()) {
|
||||
|
||||
_add_global(E->get().name, E->get().ptr);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue