From fa635f8f1962e45c4aa3c3777f54fab74b843e2c Mon Sep 17 00:00:00 2001 From: David Markowitz Date: Sat, 26 Sep 2026 00:38:02 -0700 Subject: [PATCH] remove flag --- dGame/dComponents/ModelComponent.cpp | 8 ++------ dGame/dComponents/ModelComponent.h | 3 --- resources/worldconfig.ini | 3 --- 3 files changed, 2 insertions(+), 12 deletions(-) diff --git a/dGame/dComponents/ModelComponent.cpp b/dGame/dComponents/ModelComponent.cpp index fccd565f2..f3b289988 100644 --- a/dGame/dComponents/ModelComponent.cpp +++ b/dGame/dComponents/ModelComponent.cpp @@ -6,7 +6,6 @@ #include "Game.h" #include "Logger.h" -#include "dConfig.h" #include "dMath.h" #include "BehaviorStates.h" @@ -323,10 +322,7 @@ bool ModelComponent::TryStartRotation(const int axis, const float direction) { if (m_RotationDirection[axis] != 0.0f) return false; // Rebase only when nothing is rotating so simultaneous rotations stay relative to the same base - if (m_RotationDirection == NiPoint3Constant::ZERO) { - ResetRotationState(m_Parent->GetRotation()); - m_SendAngularVelocity = Game::config->GetValue("model_rotation_send_angular_velocity") != "0"; - } + if (m_RotationDirection == NiPoint3Constant::ZERO) ResetRotationState(m_Parent->GetRotation()); m_RotationDegrees[axis] = std::fmod(m_RotationDegrees[axis], 360.0f); m_RotationActionStart[axis] = m_RotationDegrees[axis]; @@ -362,7 +358,7 @@ void ModelComponent::SetSpeed(const float newSpeed) { void ModelComponent::SyncAngularVelocity() const { GameMessages::SetAngularVelocity setAngVel{}; setAngVel.target = m_Parent->GetObjectID(); - setAngVel.angVelocity = m_SendAngularVelocity ? m_RotationDirection * Math::DegToRad(GetAngularSpeed()) : NiPoint3Constant::ZERO; + setAngVel.angVelocity = m_RotationDirection * Math::DegToRad(GetAngularSpeed()); setAngVel.Send(); } diff --git a/dGame/dComponents/ModelComponent.h b/dGame/dComponents/ModelComponent.h index 3a1dec0f4..10a75930d 100644 --- a/dGame/dComponents/ModelComponent.h +++ b/dGame/dComponents/ModelComponent.h @@ -248,7 +248,4 @@ private: // Per axis -1, 0 or 1. Non-zero means a behavior currently owns rotation on that axis. NiPoint3 m_RotationDirection{}; - - // Whether the client is sent an angular velocity to extrapolate rotation between updates - bool m_SendAngularVelocity{ true }; }; diff --git a/resources/worldconfig.ini b/resources/worldconfig.ini index 415db64b3..5d23a32f6 100644 --- a/resources/worldconfig.ini +++ b/resources/worldconfig.ini @@ -105,6 +105,3 @@ hardcore_coin_keep= # save pre-split lxfmls to disk for debugging save_lxfmls=0 - -# Send models' angular velocity to clients so they extrapolate rotation between updates (1) or only send rotation (0) -model_rotation_send_angular_velocity=1