This project has moved and is read-only. For the latest updates, please go here.

Using PhysicsSimulatorView

Jul 9, 2010 at 6:10 PM
Edited Jul 9, 2010 at 6:25 PM
Hey, I have been trying to debug something and I thought the SimulatorView would make it alot easier. But I just cannot get it to work! It seems like just adding the Sim to the view and enabling its draw in your draw line would make it work. But it will give tons of null reference errors whenever I do that. Enabling diagnostics on the sim did nothing. I really cannot get it to work. The first null reference error is right here _verticeCircleBrush.Draw(spriteBatch, _physicsSimulator.GeomList[i].WorldVertices[j]); (at the world vertices).
Jul 15, 2010 at 4:20 PM
Any details? Is there any sort of documentation in using the PhysicsSimulatorVIew? It would be really handy to see a clear picture of all the bodies/geoms.
Jul 16, 2010 at 5:42 AM

Look at the samples project.  They use PhysicsSimulatorView, so you can just look at how they do things.

Jul 16, 2010 at 6:54 AM
Edited Jul 16, 2010 at 7:00 AM

Alright got it working, was just a matter of improper references. Was just as easy as it looked!