After my game has been running for a certain amount of time, the same Warning shows up and my game breaks. I am not sure why this is and I cannot find a solution for it.
The message that keeps popping up is as follows:
Microsoft Visual Studio Express 2013 for Windows Desktop
An unhandled exception of type 'System.ComponentModel.Win32Exception' occurred in System.Drawing.dll
Additional information: The operation completed successfully
I have an Object class that deals with all of the Objects displayed on screen (position, collisions etc) and the warning seems to be coming from this class. When the warning is displayed, one line in-particular is highlighted every time, that is:
public Obj(Vector2 pos)
{
position = pos;
}
Any help resolving my problem will be appreciated