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
Chipmunk_unsafe.h allows changing the shapes attached to a body but does not expose functions for creating unattached shapes - to the body. Is there a reason for this? One possible scenario this would be useful is changing the collision area of a body during runtime to correlate with that body's animation. Shapes bounding the frames of the animation could be loaded from a file, initialized and attached when needed. Thoughts?
The text was updated successfully, but these errors were encountered:
To enable or disable a shape, you just need to add or remove it from the space. Keep in mind that as the comments in the header warn, Chipmunk will have no idea how the shape of a body changed. If adding a new shape causes it to overlap something else, they will sort of mush apart from each like sponges and not rigid objects.
Thanks for the clarification. Attaching all the shapes to a body and enabling/disabling when needed should yield the same results without using chipmunk_unsafe.h. Nice.
Chipmunk_unsafe.h allows changing the shapes attached to a body but does not expose functions for creating unattached shapes - to the body. Is there a reason for this? One possible scenario this would be useful is changing the collision area of a body during runtime to correlate with that body's animation. Shapes bounding the frames of the animation could be loaded from a file, initialized and attached when needed. Thoughts?
The text was updated successfully, but these errors were encountered: