mirror of
https://github.com/vcmi/vcmi.git
synced 2025-04-15 11:46:56 +02:00
Fix for starting hero being passable
This commit is contained in:
parent
ef61456681
commit
cef25cca03
@ -150,6 +150,11 @@ bool CGHeroInstance::isCoastVisitable() const
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool CGHeroInstance::isBlockedVisitable() const
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
BattleField CGHeroInstance::getBattlefield() const
|
BattleField CGHeroInstance::getBattlefield() const
|
||||||
{
|
{
|
||||||
return BattleField::NONE;
|
return BattleField::NONE;
|
||||||
@ -281,6 +286,7 @@ CGHeroInstance::CGHeroInstance():
|
|||||||
ID = Obj::HERO;
|
ID = Obj::HERO;
|
||||||
secSkills.emplace_back(SecondarySkill::NONE, -1);
|
secSkills.emplace_back(SecondarySkill::NONE, -1);
|
||||||
blockVisit = true;
|
blockVisit = true;
|
||||||
|
removable = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
PlayerColor CGHeroInstance::getOwner() const
|
PlayerColor CGHeroInstance::getOwner() const
|
||||||
@ -301,6 +307,7 @@ void CGHeroInstance::setHeroType(HeroTypeID heroType)
|
|||||||
|
|
||||||
void CGHeroInstance::initHero(CRandomGenerator & rand, const HeroTypeID & SUBID)
|
void CGHeroInstance::initHero(CRandomGenerator & rand, const HeroTypeID & SUBID)
|
||||||
{
|
{
|
||||||
|
blockVisit = true;
|
||||||
subID = SUBID.getNum();
|
subID = SUBID.getNum();
|
||||||
initHero(rand);
|
initHero(rand);
|
||||||
}
|
}
|
||||||
|
@ -301,6 +301,7 @@ public:
|
|||||||
void updateFrom(const JsonNode & data) override;
|
void updateFrom(const JsonNode & data) override;
|
||||||
|
|
||||||
bool isCoastVisitable() const override;
|
bool isCoastVisitable() const override;
|
||||||
|
bool isBlockedVisitable() const override;
|
||||||
BattleField getBattlefield() const override;
|
BattleField getBattlefield() const override;
|
||||||
protected:
|
protected:
|
||||||
void setPropertyDer(ObjProperty what, ObjPropertyID identifier) override;//synchr
|
void setPropertyDer(ObjProperty what, ObjPropertyID identifier) override;//synchr
|
||||||
|
Loading…
x
Reference in New Issue
Block a user