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
public function removeShape(shape:Shape):Void {
// first, remove the shape from the linked list so that it will be ignored
M.list_remove(_shapeList, _shapeListLast, _prev, _next, shape);
_numShapes--;
shape._rigidBody = null;
// then remove the shape from the world
if (_world != null) {
_world._removeShape(shape);
}
_shapeModified();
}
Should shape._rigidBody = null go (after) before _shapeModified();?
As _world.removeShape(shape); requires shape._rigidBody(NULL)._contactLinkList
The text was updated successfully, but these errors were encountered:
It's a bug, which i mentioned years ago, when i needed scaling bodies at runtime, but it seems it did not get fixed.
Just move the shape._rigidbody = null, below the if statement and there is no error.
I didn't notice any unwated side effects, by doing so, it now works like i think it is intended.
Should shape._rigidBody = null go (after) before _shapeModified();?
As _world.removeShape(shape); requires shape._rigidBody(NULL)._contactLinkList
The text was updated successfully, but these errors were encountered: