From 1d677927e73e2d66591738777f6a1559527dbab2 Mon Sep 17 00:00:00 2001 From: Alexander Pickering Date: Tue, 31 Jul 2018 16:42:13 -0400 Subject: Added an editbox Added bindings to Irrlicht's EditBox gui element. --- src/client/main.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src/client/main.cpp') diff --git a/src/client/main.cpp b/src/client/main.cpp index eb8eca6..5462e31 100644 --- a/src/client/main.cpp +++ b/src/client/main.cpp @@ -78,7 +78,7 @@ void QuaternionToEuler(const btQuaternion &TQuat, btVector3 &TEuler) { } void UpdateElement(btRigidBody* TObject){ - + if(TObject->getUserPointer() != NULL){ //UpdateRender(*Iterator); scene::ISceneNode *Node = static_cast((TObject)->getUserPointer()); @@ -92,7 +92,7 @@ void UpdateElement(btRigidBody* TObject){ QuaternionToEuler(TObject->getOrientation(), EulerRotation); Node->setRotation(core::vector3df(EulerRotation[0], EulerRotation[1], EulerRotation[2])); } - + } SColor background = SColor(255,100,101,140); @@ -110,7 +110,7 @@ int main(int argc, char *argv[]){ // Initialize bullet phys_genesis(); - + //Create a new lua state, this gets shared everywhere lua_State *state = luaL_newstate(); L = state; @@ -157,8 +157,12 @@ int main(int argc, char *argv[]){ printf("About to check if device run\n"); printf("Device is %p\n",device); while(device->run()){ + //printf("Start gameloop net\n"); gameloop_net(L); + //printf("End gameloop net\n"); + //printf("Start gameloop phys\n"); gameloop_phys(UpdateElement); + //printf("End gameloop phys\n"); if(device->isWindowActive()){ driver->beginScene(true, true, background); @@ -183,7 +187,6 @@ int main(int argc, char *argv[]){ lua_call(state,0,0); lua_pop(state,1); }else{ - printf("Tick was nil...\n"); lua_pop(state,2); } } -- cgit v1.2.3-70-g09d2