mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-24 22:14:36 +02:00
[mingw] finally fix broken compilation after rev 3183
This commit is contained in:
parent
6ac70d6a0b
commit
506d54478f
@ -132,7 +132,7 @@ bool CCallback::dismissHero(const CGHeroInstance *hero)
|
||||
}
|
||||
|
||||
// int CCallback::getMySerial() const
|
||||
// {
|
||||
// {
|
||||
// boost::shared_lock<boost::shared_mutex> lock(*gs->mx);
|
||||
// return gs->players[player].serial;
|
||||
// }
|
||||
@ -287,13 +287,19 @@ void CCallback::buildBoat( const IShipyard *obj )
|
||||
sendRequest(&bb);
|
||||
}
|
||||
|
||||
CCallback::CCallback( CGameState * GS, boost::optional<TPlayerColor> Player, CClient *C )
|
||||
CCallback::CCallback( CGameState * GS, boost::optional<TPlayerColor> Player, CClient *C )
|
||||
:CBattleCallback(GS, Player, C)
|
||||
{
|
||||
waitTillRealize = false;
|
||||
unlockGsWhenWaiting = false;
|
||||
}
|
||||
|
||||
CCallback::~CCallback()
|
||||
{
|
||||
//trivial, but required. Don`t remove.
|
||||
}
|
||||
|
||||
|
||||
const CGPathNode * CCallback::getPathInfo( int3 tile )
|
||||
{
|
||||
if (!gs->map->isInTheMap(tile))
|
||||
@ -355,7 +361,7 @@ void CCallback::validatePaths()
|
||||
if(h && ( cl->pathInfo->hero != h //wrong hero
|
||||
|| cl->pathInfo->hpos != h->getPosition(false) //wrong hero positoin
|
||||
|| !cl->pathInfo->isValid)) //paths invalidated by game event
|
||||
{
|
||||
{
|
||||
recalculatePaths();
|
||||
}
|
||||
}
|
||||
|
@ -44,7 +44,7 @@ public:
|
||||
//hero
|
||||
virtual bool moveHero(const CGHeroInstance *h, int3 dst) =0; //dst must be free, neighbouring tile (this function can move hero only by one tile)
|
||||
virtual bool dismissHero(const CGHeroInstance * hero)=0; //dismisses given hero; true - successfuly, false - not successfuly
|
||||
virtual void dig(const CGObjectInstance *hero)=0;
|
||||
virtual void dig(const CGObjectInstance *hero)=0;
|
||||
virtual void castSpell(const CGHeroInstance *hero, SpellID spellID, const int3 &pos = int3(-1, -1, -1))=0; //cast adventure map spell
|
||||
|
||||
//town
|
||||
@ -89,7 +89,7 @@ public:
|
||||
CBattleCallback(CGameState *GS, boost::optional<TPlayerColor> Player, CClient *C);
|
||||
int battleMakeAction(BattleAction* action) OVERRIDE;//for casting spells by hero - DO NOT use it for moving active stack
|
||||
bool battleMakeTacticAction(BattleAction * action) OVERRIDE; // performs tactic phase actions
|
||||
|
||||
|
||||
friend class CCallback;
|
||||
friend class CClient;
|
||||
};
|
||||
@ -102,6 +102,7 @@ private:
|
||||
|
||||
public:
|
||||
CCallback(CGameState * GS, boost::optional<TPlayerColor> Player, CClient *C);
|
||||
virtual ~CCallback();
|
||||
|
||||
//client-specific functionalities (pathfinding)
|
||||
virtual const CGPathNode *getPathInfo(int3 tile); //uses main, client pathfinder info
|
||||
@ -141,7 +142,7 @@ public:
|
||||
void save(const std::string &fname);
|
||||
void sendMessage(const std::string &mess);
|
||||
void buildBoat(const IShipyard *obj);
|
||||
void dig(const CGObjectInstance *hero);
|
||||
void dig(const CGObjectInstance *hero);
|
||||
void castSpell(const CGHeroInstance *hero, SpellID spellID, const int3 &pos = int3(-1, -1, -1));
|
||||
|
||||
//friends
|
||||
|
Loading…
Reference in New Issue
Block a user