1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

Add LeaveGame netpack and avoid replying on it and CloseServer

This commit is contained in:
Arseniy Shestakov
2017-05-31 09:45:26 +03:00
parent c7e7a4d7be
commit 4b0f702e7e
7 changed files with 68 additions and 12 deletions

View File

@@ -223,6 +223,7 @@ public:
bool arrangeStacks( ObjectInstanceID id1, ObjectInstanceID id2, ui8 what, SlotID p1, SlotID p2, si32 val, PlayerColor player);
void save(const std::string &fname);
void close();
void playerLeftGame(int cid);
void handleTimeEvents();
void handleTownEvents(CGTownInstance *town, NewTurn &n);
bool complain(const std::string &problem); //sends message to all clients, prints on the logs and return true
@@ -298,4 +299,9 @@ private:
void checkVictoryLossConditionsForAll();
};
class clientDisconnectedException : public std::exception
{
};
void makeStackDoNothing();