You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After switching states the InversePointProxy for the p2 world physics is broken, this is because the actual array the proxy refers to is no longer used by the p2 world.
On reset the world reruns the ctor which creates a new array for the world gravity. The InversePointProxy in Phaser's P2.World still refers to the old one so you have to access the world gravity manually instead of using the point proxy.
The text was updated successfully, but these errors were encountered:
…. All of the bodies, springs, fixtures, materials and constraints are removed - but config settings such as gravity, restitution, the contact solver, etc are all retained. The P2.World object is only created the very first time you call Physics.startSystem. Every subsequent call hits P2.World.reset instead (#1292)
After switching states the
InversePointProxy
for the p2 world physics is broken, this is because the actual array the proxy refers to is no longer used by the p2 world.On reset the world reruns the ctor which creates a new array for the world gravity. The
InversePointProxy
in Phaser's P2.World still refers to the old one so you have to access the world gravity manually instead of using the point proxy.The text was updated successfully, but these errors were encountered: