mirror of
https://github.com/vcmi/vcmi.git
synced 2025-03-05 15:05:40 +02:00
* minor fixes for #1145
This commit is contained in:
parent
7a45f707a0
commit
226a8a8102
@ -1284,10 +1284,12 @@ void CGDwelling::fightOver(const CGHeroInstance *h, BattleResult *result) const
|
||||
int CGTownInstance::getSightRadious() const //returns sight distance
|
||||
{
|
||||
if (subID == 2) //tower
|
||||
{
|
||||
if ((builtBuildings.find(17)) != builtBuildings.end()) //skyship
|
||||
return cb->getMapSize().first + cb->getMapSize().second;
|
||||
else if ((builtBuildings.find(21)) != builtBuildings.end()) //lookout tower
|
||||
return 20;
|
||||
}
|
||||
return 5;
|
||||
}
|
||||
|
||||
@ -1466,10 +1468,10 @@ void CGTownInstance::initObj()
|
||||
switch (alignment)
|
||||
{ //add new visitable objects
|
||||
case 2: case 3: case 5: case 6:
|
||||
bonusingBuildings.push_back(*new CTownBonus(23, this));
|
||||
bonusingBuildings.push_back(CTownBonus(23, this));
|
||||
break;
|
||||
case 7:
|
||||
bonusingBuildings.push_back(*new CTownBonus(17, this));
|
||||
bonusingBuildings.push_back(CTownBonus(17, this));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user