~parasiteofchar/s25rttr/AIpoc2

« back to all changes in this revision

Viewing changes to src/GameCommands.h

  • Committer: poc
  • Date: 2015-02-14 18:27:20 UTC
  • Revision ID: parasiteofchar@googlemail.com-20150214182720-9p884ms594wgs1j1
new addon: Individual Custom Military
allows players to set the requested_soldier count for each individual military building

Show diffs side-by-side

added added

removed removed

Lines of Context:
56
56
        UPGRADEROAD,
57
57
                SENDSOLDIERSHOME,
58
58
                ORDERNEWSOLDIERS,
59
 
                NOTIFYALLIESOFLOCATION
 
59
                NOTIFYALLIESOFLOCATION,
 
60
                REQUESTED_SOLDIERS_INC,
 
61
                REQUESTED_SOLDIERS_DEC,
 
62
                REQUESTED_SOLDIERS_RES
60
63
    };
61
64
 
62
65
 
323
326
            void Execute(GameWorldGame& gwg, GameClientPlayer& player, const unsigned char playerid);
324
327
    };
325
328
 
 
329
/// Increase requested soldiers
 
330
    class RequestedSoldiersInc : public Coords
 
331
    {
 
332
            friend class GameClient;
 
333
        public:
 
334
            RequestedSoldiersInc(const MapCoord x, const MapCoord y)
 
335
                : Coords(REQUESTED_SOLDIERS_INC, x, y) {}
 
336
            RequestedSoldiersInc(Serializer* ser)
 
337
                : Coords(REQUESTED_SOLDIERS_INC, ser) {}
 
338
 
 
339
            /// F�hrt das GameCommand aus
 
340
            void Execute(GameWorldGame& gwg, GameClientPlayer& player, const unsigned char playerid);
 
341
    };
 
342
 
 
343
/// Decrease requested soldiers
 
344
    class RequestedSoldiersDec : public Coords
 
345
    {
 
346
            friend class GameClient;
 
347
        public:
 
348
            RequestedSoldiersDec(const MapCoord x, const MapCoord y)
 
349
                : Coords(REQUESTED_SOLDIERS_DEC, x, y) {}
 
350
            RequestedSoldiersDec(Serializer* ser)
 
351
                : Coords(REQUESTED_SOLDIERS_DEC, ser) {}
 
352
 
 
353
            /// F�hrt das GameCommand aus
 
354
            void Execute(GameWorldGame& gwg, GameClientPlayer& player, const unsigned char playerid);
 
355
    };
 
356
 
 
357
/// return requested soldiers to default
 
358
    class RequestedSoldiersRes : public Coords
 
359
    {
 
360
            friend class GameClient;
 
361
        public:
 
362
            RequestedSoldiersRes(const MapCoord x, const MapCoord y)
 
363
                : Coords(REQUESTED_SOLDIERS_RES, x, y) {}
 
364
            RequestedSoldiersRes(Serializer* ser)
 
365
                : Coords(REQUESTED_SOLDIERS_RES, ser) {}
 
366
 
 
367
            /// F�hrt das GameCommand aus
 
368
            void Execute(GameWorldGame& gwg, GameClientPlayer& player, const unsigned char playerid);
 
369
    };
 
370
 
326
371
/// call for new min rank soldiers (used by ai to upgrade troops instead of changing mil settings all the time)
327
372
    class OrderNewSoldiers : public Coords
328
373
    {