Update of bug #11672 (project wormux):

                Category:              Game rules => translation            
                  Status:                    None => In Progress            
             Assigned to:                    None => drayan                 

    _______________________________________________________

Follow-up Comment #2:

In order to adress this kind of problem, I have created this patch.

To summarize the idea, now we update m_last_move (in physics.h) every time an
object is moving (falling, setting speed, stoping etc) and we use a new method
IsSleeping in the IsImmobile function. An object is sleeping if we didn't see
any move since 400 ms. As far as I can see I didn't see any regression (but I
can't say that there's any :)

Other refinement is now, if an object is sleeping, we didn't run the physical
engine on it so we are saving precious CPU time and as every body know, time
is money ;)

To be honest, I have taken this idea from Box2d while doing my physical
engine.

Now, we still have the problem of is_active boolean from weapon class but at
least no more never-ending-turn from an object in a bad
non-moving-object-but-still-in-vaccum state.

(file #4442)
    _______________________________________________________

Additional Item Attachment:

File name: sleeping_object.diff           Size:5 KB


    _______________________________________________________

Reply to this item at:

  <http://gna.org/bugs/?11672>

_______________________________________________
  Message posté via/par Gna!
  http://gna.org/


_______________________________________________
Wormux-gna mailing list
[email protected]
https://mail.gna.org/listinfo/wormux-gna

Reply via email to