2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-08 21:07:42 +00:00

Work on CPlayer

This commit is contained in:
Jack Andersen
2017-08-17 15:30:15 -10:00
parent 7e492e0db4
commit 98b2fb6855
23 changed files with 637 additions and 112 deletions

View File

@@ -99,11 +99,7 @@ void CPhysicsActor::AddMotionState(const CMotionState& mst)
{
zeus::CNUQuaternion q{x34_transform.buildMatrix3f()};
q += mst.xc_orientation;
x34_transform = zeus::CTransform(q, x34_transform.origin);
xe4_27_ = true;
xe4_28_ = true;
xe4_29_actorLightsDirty = true;
SetTransform(zeus::CTransform(q, x34_transform.origin));
SetTranslation(x34_transform.origin + mst.x0_translation);
@@ -119,11 +115,7 @@ CMotionState CPhysicsActor::GetMotionState() const
void CPhysicsActor::SetMotionState(const CMotionState& mst)
{
x34_transform = zeus::CTransform(mst.xc_orientation, x34_transform.origin);
xe4_27_ = true;
xe4_28_ = true;
xe4_29_actorLightsDirty = true;
SetTransform(zeus::CTransform(mst.xc_orientation, x34_transform.origin));
SetTranslation(mst.x0_translation);
xfc_constantForce = mst.x1c_velocity;
@@ -265,10 +257,7 @@ bool CPhysicsActor::WillMove(const CStateManager&)
void CPhysicsActor::SetPhysicsState(const CPhysicsState& state)
{
SetTranslation(state.GetTranslation());
x34_transform = zeus::CTransform(state.GetOrientation(), x34_transform.origin);
xe4_27_ = true;
xe4_28_ = true;
xe4_29_actorLightsDirty = true;
SetTransform(zeus::CTransform(state.GetOrientation(), x34_transform.origin));
xfc_constantForce = state.GetConstantForceWR();
x108_angularMomentum = state.GetAngularMomentumWR();