[Server] Rename getNextMpNum() into incrementMpNum()

0.6.1
David Cernat 8 years ago
parent 068835ba71
commit 316720e710

@ -300,7 +300,7 @@ void Networking::setCurrentMpNum(int value)
currentMpNum = value; currentMpNum = value;
} }
int Networking::getNextMpNum() int Networking::incrementMpNum()
{ {
currentMpNum++; currentMpNum++;
Script::Call<Script::CallbackIdentity("OnMpNumIncrement")>(currentMpNum); Script::Call<Script::CallbackIdentity("OnMpNumIncrement")>(currentMpNum);

@ -40,7 +40,7 @@ namespace mwmp
int getCurrentMpNum(); int getCurrentMpNum();
void setCurrentMpNum(int value); void setCurrentMpNum(int value);
int getNextMpNum(); int incrementMpNum();
MasterClient *getMasterClient(); MasterClient *getMasterClient();
void InitQuery(std::string queryAddr, unsigned short queryPort, std::string serverAddr, unsigned short serverPort); void InitQuery(std::string queryAddr, unsigned short queryPort, std::string serverAddr, unsigned short serverPort);

@ -22,7 +22,7 @@ namespace mwmp
{ {
for (unsigned int i = 0; i < event.objectChanges.count; i++) for (unsigned int i = 0; i < event.objectChanges.count; i++)
{ {
event.objectChanges.objects.at(i).mpNum = mwmp::Networking::getPtr()->getNextMpNum(); event.objectChanges.objects.at(i).mpNum = mwmp::Networking::getPtr()->incrementMpNum();
} }
// Send this packet back to the original sender with the mpNum generation from above, // Send this packet back to the original sender with the mpNum generation from above,

Loading…
Cancel
Save