mirror of
https://github.com/vcmi/vcmi.git
synced 2025-01-26 03:52:01 +02:00
Merge pull request #4457 from mikeiit/bug_double_dialog_7_days
Removed Redundant Info Window
This commit is contained in:
commit
11ac768599
@ -1418,18 +1418,6 @@ void CGameHandler::setOwner(const CGObjectInstance * obj, const PlayerColor owne
|
|||||||
if (town->hasBuilt(BuildingSubID::PORTAL_OF_SUMMONING))
|
if (town->hasBuilt(BuildingSubID::PORTAL_OF_SUMMONING))
|
||||||
setPortalDwelling(town, true, false);
|
setPortalDwelling(town, true, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (oldOwner.isValidPlayer()) //old owner is real player
|
|
||||||
{
|
|
||||||
if (getPlayerState(oldOwner)->towns.empty() && getPlayerState(oldOwner)->status != EPlayerStatus::LOSER) //previous player lost last town
|
|
||||||
{
|
|
||||||
InfoWindow iw;
|
|
||||||
iw.player = oldOwner;
|
|
||||||
iw.text.appendLocalString(EMetaText::GENERAL_TXT, 6); //%s, you have lost your last town. If you do not conquer another town in the next week, you will be eliminated.
|
|
||||||
iw.text.replaceName(oldOwner);
|
|
||||||
sendAndApply(&iw);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const PlayerState * p = getPlayerState(owner);
|
const PlayerState * p = getPlayerState(owner);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user