Update ControllablePhysicsComponent.cpp

This commit is contained in:
David Markowitz 2024-03-10 01:51:22 -08:00
parent 0f6b47a833
commit f71b774a0a

View File

@ -65,7 +65,9 @@ ControllablePhysicsComponent::~ControllablePhysicsComponent() {
}
void ControllablePhysicsComponent::Update(float deltaTime) {
if (m_Velocity == NiPoint3Constant::ZERO) return;
SetPosition(m_Position + (m_Velocity * deltaTime));
Game::entityManager->SerializeEntity(m_Parent);
}
void ControllablePhysicsComponent::Serialize(RakNet::BitStream& outBitStream, bool bIsInitialUpdate) {