I dont know what im doing wrong but for some reason I keep getting an unhandled exception my my entity manager. I try to draw the sprite to the screen and right before the entity manager updates and trys to draw it everything is fine. But as soon as it attempts to draw the sprite i get an exception. Here's the code. Can someone please help me ? This is driving me nuts if you need the whole project just let me know and ill email it to you
If the exception is thrown right before drawing a sprite, then maybe you should use try... catch() to handle the exception. That way, you can handle memory deallocation properly.
Before using a resource, make sure it's there before using it. For example, make sure sure a pointer isn't null before writing to it.