Sign in to follow this  
EyesOfDarkShine

Release Build Outside of IDE issue

Recommended Posts

Hello Everyone,
New to the forums, but have signed up to get some suggestions on an issue my Development Team and I are having during our Full Sail final project. We have been building our game mainly in debug mode for the past week or so.

Our core build from last month runs fine in release, but now that we have begun implementing new systems, and have built it in release, we are having some strange issues. Using Visual Studios 2008 as our IDE, and C++ as our primary language, we have pulled the .exe out and have it running properly without crashes, but we are getting weird behaviors. The game will seem to run properly, but some random textures will not load correctly, and collision functions that should be getting called every frame are begging completely skipped. In attaching the process to our debugger and stepping through some things, we have seen odd errors such as getting into if checks such as if(nObjID != 1), but according to our watch window and the id's set up in the object, the value is 1.

The results are not consistent, as sometime none of these functions will be called, and other times, it will arbitrarily decide to skip them, causing floor fall through. We have recently done a full code clean to make sure all values in our code were initialized and have used Dependency Walker to check that all needed files are loading properly, but we cannot seem to find what is causing the game to preform so differently. I know this is a long wall of text, but I am trying to give enough detail into our issue, that hopefully someone has seen a similar performance error and potentially point us in a way of finding a solution. Any help, suggestions, or relevant past experiences would be greatly appreciated.

Share this post


Link to post
Share on other sites
wqking    761
I didn't read all your post (I will do if you can format your message in lines and paragraphs).

But it sounds like you are using free-ed, or uninitialized data?
Then if possible, you can comment out some code, execute, see if it's OK. This will help to nail down the problem.

Share this post


Link to post
Share on other sites
Dunge    405
I've seen invalid debugger behavior like you mention quite often, in debug mode. Usually a "rebuild solution" do the trick. But trying to debug code in release mode with optimizations on and debug info off is sure to give you invalid results, don't count on it. You have to do as wqking said and remove parts of the code or use console printing to nail down the problem. Probably happens because you read/write beyond an allocated memory array size, or call methods on invalid (deleted) pointer of some class. An utility like Visual Leak Detector can help you to find out parts of code that could cause problem.

Share this post


Link to post
Share on other sites
We have used VLD already to to check for leaks, and our code clean today was specifically targeted at initializing all memory before it is used or even stored into. We have also taken the time to double check constructors and destructors of all of our classes for leaked, or overwritten pointers, and are coming up blank. We have also done more research and determined the debugger info when attaching the release mode process was invalid, but have not yet attached a console window to the release exe for seeing event firings and other notifications.

With the constructors being called as they are now, they should never be filled with invalid data, and this has been checked by each of us, checking both our own systems and each other's. Our next step is the console window for following the process, but with the inconsistency of the errors, and the fact that sometimes it will preform exactly as it is supposed to accept for one or two floor tiles having no collision, we aren't sure where to begin the search.

As a precaution, we have also turned on the drawing of hit boxes in release mode, and they are all drawing right on the world locations properly. The only odd, and bizarre error we have been able to coome across with debugging was random times when our update time between frames was 0.0f or sometimes even negative. Again, we have reviewed the code and logic of the timer, as well as checking for all references of it or it's functions and have found nowhere that would cause a 0.0f or negative timestep. Scarily, this has even occurred when we have locked the update to the video refresh rate.

Thank you for you suggestions, and anymore the community may have, we are going to implement some of these and try some more starting tomorrow.


Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this