Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Static Bodies cannot be repositioned. #48

Closed
GoogleCodeExporter opened this issue Mar 14, 2015 · 1 comment
Closed

Static Bodies cannot be repositioned. #48

GoogleCodeExporter opened this issue Mar 14, 2015 · 1 comment

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. Create a static body
2. Try to set its transform
3. Transform does not get updated (early return for static entities).

What is the expected output? What do you see instead?

I expect to be able to reposition static bodies.  This is key for making a 
dynamic live level editor or even controlling physics entities after they 
have been created.


What version of the product are you using? On what operating system?

r30 (found this after I ported r30 to Box2D.XNA)


Please provide any additional information below.

It seems like an arbitrary constraint to limit setting transforms on 
static entities.

I want zero-mass, zero-velocity body but i want to be able to set it's 
position/rotation after it has been created.  This comes up in level 
editor scenarios or even with our ZoomEngine entity system (we create the 
entity, which creates corresponding physics bodies, then later the 
position is set).  Kinematic bodies reduces the need for us to use static 
entities in many cases, but for the zero-velocity case we still want 
static, and want to reposition them sometimes.

In my port I removed this early return in Body.SetTransform and I'm back 
to the behavior I want without any negative effects on the rest of the 
system.


Original issue reported on code.google.com by NFurtwan...@gmail.com on 7 Dec 2009 at 2:17

@GoogleCodeExporter
Copy link
Author

Original comment by erinca...@gmail.com on 7 Dec 2009 at 8:14

  • Changed state: Duplicate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant