mirror of
https://github.com/vcmi/vcmi.git
synced 2025-08-13 19:54:17 +02:00
Actually this one contains fixed Pyramid
This commit is contained in:
@@ -4220,24 +4220,11 @@ void CBank::onHeroVisit (const CGHeroInstance * h) const
|
||||
else
|
||||
{
|
||||
InfoWindow iw;
|
||||
if (ID == 85)
|
||||
{
|
||||
iw.components.push_back (Component (Component::MORALE, 0 , -1, 0));
|
||||
GiveBonus gbonus;
|
||||
gbonus.hid = h->id;
|
||||
gbonus.bonus.duration = HeroBonus::ONE_BATTLE;
|
||||
gbonus.bonus.source = HeroBonus::OBJECT;
|
||||
gbonus.bonus.id = ID;
|
||||
gbonus.bdescr << "\n" << VLC->generaltexth->arraytxt[ID];
|
||||
gbonus.bonus.type = HeroBonus::MORALE;
|
||||
gbonus.bonus.val = -1;
|
||||
cb->giveHeroBonus(&gbonus);
|
||||
}
|
||||
iw.soundID = soundBase::GRAVEYARD;
|
||||
iw.player = h->getOwner();
|
||||
//if (ID == 16 || ID == 24 || ID == 25 || ID == 84)
|
||||
iw.text << VLC->generaltexth->advobtxt[33];
|
||||
if (ID == 16 || ID == 24 || ID == 85)
|
||||
iw.text.addReplacement (VLC->objh->creBanksNames[index]);
|
||||
iw.text.addReplacement (VLC->objh->creBanksNames[index]);
|
||||
cb->showInfoDialog(&iw);
|
||||
}
|
||||
}
|
||||
@@ -4260,7 +4247,7 @@ void CBank::endBattle (const CGHeroInstance *h, const BattleResult *result) cons
|
||||
|
||||
switch (ID)
|
||||
{
|
||||
case 16: case 25: case 84:
|
||||
case 16: case 25:
|
||||
textID = 34;
|
||||
break;
|
||||
case 24: //derelict ship
|
||||
@@ -4268,10 +4255,39 @@ void CBank::endBattle (const CGHeroInstance *h, const BattleResult *result) cons
|
||||
textID = 43;
|
||||
else
|
||||
{
|
||||
iw.components.push_back (Component (Component::MORALE, 0 , -2, 0));
|
||||
GiveBonus gbonus;
|
||||
gbonus.hid = h->id;
|
||||
gbonus.bonus.duration = HeroBonus::ONE_BATTLE;
|
||||
gbonus.bonus.source = HeroBonus::OBJECT;
|
||||
gbonus.bonus.id = ID;
|
||||
gbonus.bdescr << "\n" << VLC->generaltexth->arraytxt[ID];
|
||||
gbonus.bonus.type = HeroBonus::MORALE;
|
||||
gbonus.bonus.val = -2;
|
||||
cb->giveHeroBonus(&gbonus);
|
||||
textID = 42;
|
||||
iw.components.push_back (Component (Component::MORALE, 0 , -2, 0));
|
||||
}
|
||||
break;
|
||||
case 84: //Crypt
|
||||
if (bc->resources.size() != 0)
|
||||
textID = 121;
|
||||
else
|
||||
{
|
||||
iw.components.push_back (Component (Component::MORALE, 0 , -1, 0));
|
||||
GiveBonus gbonus;
|
||||
gbonus.hid = h->id;
|
||||
gbonus.bonus.duration = HeroBonus::ONE_BATTLE;
|
||||
gbonus.bonus.source = HeroBonus::OBJECT;
|
||||
gbonus.bonus.id = ID;
|
||||
gbonus.bdescr << "\n" << VLC->generaltexth->arraytxt[ID];
|
||||
gbonus.bonus.type = HeroBonus::MORALE;
|
||||
gbonus.bonus.val = -1;
|
||||
cb->giveHeroBonus(&gbonus);
|
||||
textID = 120;
|
||||
iw.components.push_back (Component (Component::MORALE, 0 , -1, 0));
|
||||
}
|
||||
break;
|
||||
case 85: //shipwreck
|
||||
if (bc->resources.size() != 0)
|
||||
textID = 124;
|
||||
|
@@ -955,7 +955,7 @@ public:
|
||||
|
||||
template <typename Handler> void serialize(Handler &h, const int version)
|
||||
{
|
||||
h & static_cast<CGObjectInstance&>(*this);
|
||||
h & static_cast<CBank&>(*this);
|
||||
h & spell;
|
||||
}
|
||||
};
|
||||
|
@@ -2040,12 +2040,12 @@ bool CGameHandler::buildStructure( si32 tid, si32 bid )
|
||||
ssi.creatures[bid-30].first = VLC->creh->creatures[crid].growth;
|
||||
ssi.creatures[bid-30].second.push_back(crid);
|
||||
sendAndApply(&ssi);
|
||||
}
|
||||
else if(bid == 11)
|
||||
ns.bid.insert(27);
|
||||
else if(bid == 12)
|
||||
ns.bid.insert(28);
|
||||
else if(bid == 13)
|
||||
}
|
||||
else if(bid == 11)
|
||||
ns.bid.insert(27);
|
||||
else if(bid == 12)
|
||||
ns.bid.insert(28);
|
||||
else if(bid == 13)
|
||||
ns.bid.insert(29);
|
||||
|
||||
ns.bid.insert(bid);
|
||||
|
Reference in New Issue
Block a user