rustgd / rhusics

A cgmath physics library that can be used with Specs
https://docs.rs/rhusics/
Apache License 2.0
106 stars 10 forks source link

How to implement a basic 3D player controller #80

Closed LaylBongers closed 6 years ago

LaylBongers commented 6 years ago

Looking over the docs and examples I'm at a bit of a loss on how to implement a basic player controller. In other engines this is generally implemented as a capsule with constraints on rotation so it doesn't fall over.

Rhuagh commented 6 years ago

Constraints do not exist yet in rhusics. You could perhaps emulate the same behavior by adding infinite inertia around the Z and X axis in local coordinates. For capsule support look at Capsule in collision-rs.

LaylBongers commented 6 years ago

Thanks, yea that should work for my purposes