Problems integrating tIDE into GSM from Microsoft

Aug 6, 2013 at 4:41 PM
As the title says, I'm having a few problems getting maps loaded into the game state management sample from Microsoft.

The problem is that I need to load the map in a different class than the main Game class. But when I do this, I get "ArgumentNullException was unhandled" because of this line of code mapDisplayDevice = new XnaDisplayDevice(this.content, this.graphicsDevice);. I'm not really sure what to do to fix it, although I'm fairly certain it's something simple (I'm new to C#/programming in general). Any help would be greatly appreciated.
Aug 7, 2013 at 9:33 AM
In the absence of sample code to see the actual problem, I suspect you are trying to create the XnaDisplayDevice before content and graphicsDevice are initialised. I suggest you step through the code in debug mode to understand the order in which various methods are called.