mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-07-28 07:13:03 +00:00
Fix issues with motionManager / bae258f9a1
Fixes bae258f9a1.
As reported by Freagarach, garrisoned units trigger error messages.
As reported by Vladislavbelov, noPCH was broken & there were some style
issues.
Differential Revision: https://code.wildfiregames.com/D3707
This was SVN commit r25078.
This commit is contained in:
@@ -914,7 +914,8 @@ void CCmpUnitMotion::OnTurnStart()
|
||||
void CCmpUnitMotion::PreMove(ICmpUnitMotionManager::MotionState& state)
|
||||
{
|
||||
// If we were idle and will still be, no need for an update.
|
||||
state.needUpdate = m_CurSpeed != fixed::Zero() || m_MoveRequest.m_Type != MoveRequest::NONE;
|
||||
state.needUpdate = state.cmpPosition->IsInWorld() &&
|
||||
(m_CurSpeed != fixed::Zero() || m_MoveRequest.m_Type != MoveRequest::NONE);
|
||||
}
|
||||
|
||||
void CCmpUnitMotion::Move(ICmpUnitMotionManager::MotionState& state, fixed dt)
|
||||
|
||||
Reference in New Issue
Block a user