gamecreator Posted December 20, 2016 Share Posted December 20, 2016 Since I'm not ready to upgrade to VS2015, I decided to roll back to 4.1 To my surprise, my program now seems to crash on window commands. bool App::Loop() { printf("1\n"); if(window->KeyDown(Key::Escape)) return false; printf("2\n"); if(window->Closed()) return false; printf("3\n"); The above prints 1 but not 2 or 3. If I comment out the KeyDown line, it will crash on the Closed line instead. Any idea what's going on? I'll try to create a clean project from scratch just in case but this seems strange to me. Quote Link to comment Share on other sites More sharing options...
Josh Posted December 20, 2016 Share Posted December 20, 2016 Clean your project, first of all. Then set a breakpoint and see what's going on with the window variable. 1 Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
gamecreator Posted December 20, 2016 Author Share Posted December 20, 2016 + this 0x0087b478 {window=0xcdcdcdcd {hwnd=??? hdc=??? devmode={dmDeviceName=0xcdcdcded <Error reading characters of string.> ...} ...} ...} App * Not sure if that's what you're looking for. I haven't ever really used the debugger. Edit: I'm testing what's going on. A blank project with just a few lines did not crash so the issue is somewhere else. I hate this part of coding... Edit 2: Figured I might as well just bite the bullet and upgrade to 2015. Fingers crossed. Edit 3: Got 2015 working with a project after a fix to the working directory. So far so good. Quote Link to comment Share on other sites More sharing options...
gamecreator Posted December 22, 2016 Author Share Posted December 22, 2016 Turns out that once I found the solution, I remembered that I came across this before. I previously moved Leadwerks::Window* window; Context* context; World* world; Camera* camera; to my own world.h/world.cpp files. However, when I made a clean 4.1, and later 4.2 project, I forgot to remove them from the App class. The compiler doesn't give you an error but it will definitely make your project crash. Stupidity on my part and pretty frustrating. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.