mirror of
https://gitea.wildfiregames.com/0ad/0ad
synced 2026-08-15 14:43:32 -07:00
|
Some checks failed
checkrefs / lfscheck (push) Has been cancelled
checkrefs / checkrefs (push) Has been cancelled
lint / cppcheck (push) Has been cancelled
lint / copyright (push) Has been cancelled
lint / jenkinsfiles (push) Has been cancelled
pre-commit / build (push) Has been cancelled
CSimulation2 used , CSimulation2Impl mixed /, and CTurnManager used for the same turn-count concept, forcing a static_cast<int64_t> at the one place these types already met (rejoin-test comparison). Add (alias for std::int32_t) in SimulationCommand.h and use it consistently for every turn counter in CSimulation2/Impl, CTurnManager and its subclasses (CLocalTurnManager, CReplayTurnManager), CNetServerTurnManager/CNetClientTurnManager, and the network wire format (m_Turn in CEndCommandBatchMessage, CSimulationMessage, CSyncCheckMessage, CSyncErrorMessage, and m_CurrentTurn in CLoadedGameMessage). Turn *duration* fields (m_TurnLength, m_CommandDelay, DEFAULT_TURN_LENGTH, COMMAND_DELAY_SP/MP, SetTurnLength, GetSavedTurnLength return type) are left as u32 — they're milliseconds, not a counter, and out of scope here. Remaining turn_id_t vs size_t comparisons use std::cmp_equal or explicit casts, matching the existing pattern in Simulation2.cpp. Fixes #8718 |
||
|---|---|---|
| .. | ||
| scripting | ||
| tests | ||
| FSM.h | ||
| HttpServer.cpp | ||
| HttpServer.h | ||
| NetClient.cpp | ||
| NetClient.h | ||
| NetClientSession.cpp | ||
| NetClientSession.h | ||
| NetClientTurnManager.cpp | ||
| NetClientTurnManager.h | ||
| NetEnet.cpp | ||
| NetEnet.h | ||
| NetFileTransfer.cpp | ||
| NetFileTransfer.h | ||
| NetHost.cpp | ||
| NetHost.h | ||
| NetMessage.cpp | ||
| NetMessage.h | ||
| NetMessages.h | ||
| NetMessageSim.cpp | ||
| NetProtocol.cpp | ||
| NetProtocol.h | ||
| NetServer.cpp | ||
| NetServer.h | ||
| NetServerSession.cpp | ||
| NetServerSession.h | ||
| NetServerTurnManager.cpp | ||
| NetServerTurnManager.h | ||
| NetStats.cpp | ||
| NetStats.h | ||
| NMTCreator.h | ||
| Serialization.h | ||
| StringConverters.h | ||
| StunClient.cpp | ||
| StunClient.h | ||