Update Physics2D Component and Body (#178)

* Update

* Add: [Get/Set]AngularDaming for standardization

* Fix: Name error

* Add: [Get/Set][AngularDamping/MomentOfInertia] in PhysicsComponent2D

* Forgot in last commit

* Add: param coordSys in [PhysicsComponent2D/RigidBody2D]::SetMassCenter

* Add: Some forgotten inline

* Fix little error

* Fix: Indentation before case

* Move and Change GetCenterOfGravity
This commit is contained in:
Faymoon
2018-08-02 11:25:57 +02:00
committed by Jérôme Leclercq
parent 4a09de7e0b
commit 2f3f02b2fc
5 changed files with 143 additions and 37 deletions

View File

@@ -12,6 +12,11 @@ namespace Nz
return GetMomentOfInertia();
}
inline Vector2f RigidBody2D::GetCenterOfGravity(CoordSys coordSys) const
{
return GetMassCenter(coordSys);
}
inline void RigidBody2D::SetAngularDamping(float angularDamping)
{
SetMomentOfInertia(angularDamping);