Should now correctly track if another player takes your last capture point

This commit is contained in:
Tleety
2016-03-02 13:56:35 +01:00
parent 6968e71e07
commit ab7fd89546
4 changed files with 57 additions and 68 deletions
+2 -3
View File
@@ -104,9 +104,8 @@ void CapturePointSystem::UpdateComponent(EntityWrapper& capturePointEntity, Comp
}
if (m_RecentlyCapturedNeedNextCapturePointNow) {
//TODO: Next capture point for both teams
m_CapturedEvent.NextCapturePoint = m_CapturedEvent.TeamNumberThatCapturedCapturePoint == blueTeam ?
m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Blue"]] :
m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Red"]];
m_CapturedEvent.BlueTeamNextCapturePoint = m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Blue"]];
m_CapturedEvent.RedTeamNextCapturePoint = m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Red"]];
m_EventBroker->Publish(m_CapturedEvent);
m_RecentlyCapturedNeedNextCapturePointNow = false;
}