summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/main.c b/src/main.c
index e4fb569..f35d2bf 100644
--- a/src/main.c
+++ b/src/main.c
@@ -65,14 +65,15 @@ int main( int argn, const char** argc ) {
else {
printVersion();
stateInit( argn, argc, basePath );
- state->run = luaCallMain();
+ luaCallMain();
+ luaCallInit();
while ( state->run ) {
+ luaCallUpdate();
+ luaCallDraw();
if ( WindowShouldClose() ) {
state->run = false;
}
- luaCallUpdate();
- luaCallDraw();
}
luaCallExit();
}