behdad / box2d

Automatically exported from code.google.com/p/box2d
2 stars 12 forks source link

Bodies don't sleep when static e.g. only have fixtures with zero-density. #2

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Activate "sleeping" in the test-bed then set the pyramid blocks to have
zero density (see attached file).

Although the body is static, it should perhaps sleep by default upon start-up?

Original issue reported on code.google.com by melv....@gmail.com on 11 Aug 2009 at 10:29

Attachments:

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Additionally, I have noticed that these bodies do indeed sleep if they are in 
contact
with dynamic bodies e.g. they are part of an island?

Original comment by melv....@gmail.com on 11 Aug 2009 at 10:35

GoogleCodeExporter commented 9 years ago
Is this a bug or a comment? Is there a problem?

Sleeping and static are not exclusive. One does not imply the other. This is 
part of 
design.

Original comment by erinca...@gmail.com on 19 Sep 2009 at 3:47

GoogleCodeExporter commented 9 years ago
What I was seeing was that a static body wasn't sleeping unless any of its 
fixtures
have collided with something.  I was basically getting bodies not sleeping and I
couldn't figure out why.  I noticed that if the body was involved in a 
collision, it
would then go to sleep.

I will retry this in my code to see if it's still there.

Original comment by melv....@gmail.com on 19 Sep 2009 at 1:28