mirror of
https://github.com/glest/glest-source.git
synced 2025-09-03 04:52:34 +02:00
Fixed potential command-ordering issue
This commit is contained in:
@@ -486,7 +486,7 @@ namespace
|
||||
unitId, commandType->getId(), currPos,
|
||||
-1, targetId, -1, tryQueue, cst_None,
|
||||
-1, unitCommandGroupId);
|
||||
resultCur = pushNetworkCommand(&networkCommand);
|
||||
resultCur = pushNetworkCommand(&networkCommand, isMove);
|
||||
}
|
||||
results.push_back(resultCur);
|
||||
} else if (!ignoreBuildings && unit->isMeetingPointSettable()) {
|
||||
@@ -645,7 +645,7 @@ namespace
|
||||
std::pair < CommandResult,
|
||||
string >
|
||||
Commander::pushNetworkCommand(const NetworkCommand *
|
||||
networkCommand) const {
|
||||
networkCommand, bool insertAtStart) const {
|
||||
GameNetworkInterface *
|
||||
gameNetworkInterface =
|
||||
NetworkManager::getInstance().getGameNetworkInterface();
|
||||
@@ -689,7 +689,7 @@ namespace
|
||||
}
|
||||
|
||||
//add the command to the interface
|
||||
gameNetworkInterface->requestCommand(networkCommand, true);
|
||||
gameNetworkInterface->requestCommand(networkCommand, insertAtStart);
|
||||
|
||||
//calculate the result of the command
|
||||
if (unit != NULL
|
||||
|
@@ -177,7 +177,7 @@ namespace
|
||||
std::pair <
|
||||
CommandResult,
|
||||
string >
|
||||
pushNetworkCommand(const NetworkCommand * networkCommand) const;
|
||||
pushNetworkCommand(const NetworkCommand * networkCommand, bool insertAtStart = false) const;
|
||||
std::pair <
|
||||
CommandResult,
|
||||
string >
|
||||
|
Reference in New Issue
Block a user