tjheldna Posted September 21, 2013 Share Posted September 21, 2013 Hi Josh, Just starting a new thread as the other is locked. Here is a project where Releasing an entity with a velocity crashes the program In my project it doesn't matter where it do it it always causes a crash. I did the project really quickly, so hope it's OK (or not so OK as it should be!). Cheers! Link to comment Share on other sites More sharing options...
shadmar Posted September 21, 2013 Share Posted September 21, 2013 You should probably check if it exists since you release it every loop. Something like : if (box->isrenderable) box->Release(); HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB Link to comment Share on other sites More sharing options...
tjheldna Posted September 21, 2013 Author Share Posted September 21, 2013 Damn, I did that project really fast and missed that, I'll take another look. Thanks! Link to comment Share on other sites More sharing options...
tjheldna Posted September 21, 2013 Author Share Posted September 21, 2013 OK I've finished coding like a noob. I've added in a quick timer as if you delete it on the fist loop it deletes successfully which I didn't realise also. Just replace the App.ccp and App.h in any new project Link to comment Share on other sites More sharing options...
Admin Posted September 21, 2013 Share Posted September 21, 2013 if (box->isrenderable) box->Release(); This is very wrong because you are accessing a member on a pointer that has been deleted. The correct way to do this is check to see if box is NULL (and set the pointer to NULL after it is first released). Link to comment Share on other sites More sharing options...
shadmar Posted September 21, 2013 Share Posted September 21, 2013 That's why he shouldn't listen to me HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB Link to comment Share on other sites More sharing options...
Admin Posted October 8, 2013 Share Posted October 8, 2013 Is this issue resolved? Link to comment Share on other sites More sharing options...
tjheldna Posted October 8, 2013 Author Share Posted October 8, 2013 Hi Josh, Just sent you a message, but no it's not resolved. Chuck this in a new project for an example, hopefully it will do the same for you as it does for me. Code.zip 1.33K 1 downloads Cheers Link to comment Share on other sites More sharing options...
Josh Posted October 8, 2013 Share Posted October 8, 2013 Thank you for this excellent bug report. This allowed me to find and fix a problem I did not know existed. A new update will be posted next week that fixes this and other issues. 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...
Recommended Posts