From 65740ac8ae78b03e848a2a0f746b9ed15a72f19f Mon Sep 17 00:00:00 2001 From: Lynix Date: Sun, 28 Aug 2016 18:26:35 +0200 Subject: [PATCH] Example/FirstScene: Setup Spaceship and World lua variables Former-commit-id: 7d37419cc0636bc1271660cf4518a0c08332f364 [formerly cd5984e732b464c9d31ed34ec072b9039b07163d] [formerly 43de557c346987fa965b60a88eb5a08c7a73e5e5 [formerly 671d1bde65cf2ee3dcb69711d59bd3c8ebde6a1a]] Former-commit-id: d52eed5ca2f7b4a12139b560278051349d4c5947 [formerly 322c6e78f8a487fb5dcef586d74d792d27065d6a] Former-commit-id: 3c7b7d706d45ea2731708b502364bb1dad7b3a56 --- examples/FirstScene/main.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/examples/FirstScene/main.cpp b/examples/FirstScene/main.cpp index b1e7e2a64..e7c5b2c90 100644 --- a/examples/FirstScene/main.cpp +++ b/examples/FirstScene/main.cpp @@ -269,6 +269,10 @@ int main() application.EnableConsole(true); application.EnableFPSCounter(true); + Ndk::Application::ConsoleOverlay& consoleOverlay = application.GetConsoleOverlay(); + consoleOverlay.lua.PushGlobal("Spaceship", spaceship->CreateHandle()); + consoleOverlay.lua.PushGlobal("World", world->CreateHandle()); + // Début de la boucle de rendu du programme (s'occupant par exemple de mettre à jour le monde) while (application.Run()) {