User controlled entities?

Discuss any questions about BEPUphysics or problems encountered.
Post Reply
00se7en
Posts: 9
Joined: Tue Dec 18, 2007 1:19 am

User controlled entities?

Post by 00se7en »

Is there support for user controlled entities? By this, I mean entities that the user can tell to move around resulting in them pushing other dynamic entities, but they are unaffected as though they have innfinite mass. I know PhysX calls these kinematic actors and, I think, Havok calls them keyframed actors. I have no idea if this is an advanced feature, though.

The reason that I ask, is that I was trying to create a moving platform earlier without much success. I tried moving a static entity, but that was unstable at best :shock: . I considered applying corrective forces to a dynamic entity, but I think it would end up being twitchy.
Norbo
Site Admin
Posts: 4929
Joined: Tue Jul 04, 2006 4:45 am

Re: User controlled entities?

Post by Norbo »

A static entity should work exactly as you want. If collision handling is important, you will still have to move the entity with velocities rather than entity.move/moveTo. Since move/moveTo teleports the object, the velocity remains unchanged. Entities respond to collisions based on velocities and the assumption that objects are moving continuously.
00se7en
Posts: 9
Joined: Tue Dec 18, 2007 1:19 am

Re: User controlled entities?

Post by 00se7en »

Wow, that works great! I had been using move so that was the issue with getting wierd collisions. I didn't realize that static entities paid attention to their velocities. Now other dynamic entities can even remain stable on platforms while they are under constant velocity. In case anyone else tries this, be sure to activate a static entity that you are trying to move. (in my case I just set my moving platforms to always active)
Post Reply