diff options
Diffstat (limited to 'src/engine.cpp')
-rw-r--r-- | src/engine.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/engine.cpp b/src/engine.cpp index b1d9a56..81e0272 100644 --- a/src/engine.cpp +++ b/src/engine.cpp @@ -59,13 +59,11 @@ int Engine::init(void) // Load game script and entity data auto* script = systems.system<ScriptSystem>().get(); script->addToGameNamespace("loadFont", - [this](std::string name, std::string file, int size) { - systems.system<TextSystem>().get()->loadFont(name, file, size); - }); + bindInstance(&TextSystem::loadFont, + systems.system<TextSystem>().get())); script->addToGameNamespace("puts", - [this](std::string name, float x, float y, std::string text) { - systems.system<TextSystem>().get()->put(name, x, y, text); - }); + bindInstance(&TextSystem::put, + systems.system<TextSystem>().get())); script->init(); |