mirror of
https://github.com/vcmi/vcmi.git
synced 2025-02-03 13:01:33 +02:00
Fix game loading
This commit is contained in:
parent
4f47555977
commit
8df39c43a0
@ -593,8 +593,7 @@ static void loadBonusSourceInstance(BonusSourceID & sourceInstance, BonusSource
|
||||
}
|
||||
case BonusSource::OBJECT_INSTANCE:
|
||||
case BonusSource::HERO_BASE_SKILL:
|
||||
assert(0); // TODO
|
||||
sourceInstance = ObjectInstanceID();
|
||||
sourceInstance = ObjectInstanceID(ObjectInstanceID::decode(node.String()));
|
||||
break;
|
||||
case BonusSource::CREATURE_ABILITY:
|
||||
{
|
||||
@ -641,8 +640,7 @@ static void loadBonusSourceInstance(BonusSourceID & sourceInstance, BonusSource
|
||||
break;
|
||||
}
|
||||
case BonusSource::CAMPAIGN_BONUS:
|
||||
assert(0); // TODO
|
||||
sourceInstance = CampaignScenarioID();
|
||||
sourceInstance = CampaignScenarioID(CampaignScenarioID::decode(node.String()));
|
||||
break;
|
||||
case BonusSource::ARMY:
|
||||
case BonusSource::STACK_EXPERIENCE:
|
||||
|
@ -2553,7 +2553,7 @@ void PlayerCheated::applyGs(CGameState * gs) const
|
||||
|
||||
void PlayerStartsTurn::applyGs(CGameState * gs) const
|
||||
{
|
||||
assert(gs->actingPlayers.count(player) == 0);
|
||||
//assert(gs->actingPlayers.count(player) == 0);//Legal - may happen after loading of deserialized map state
|
||||
gs->actingPlayers.insert(player);
|
||||
}
|
||||
|
||||
|
@ -455,11 +455,6 @@ std::string GameResID::entityType()
|
||||
return "resource";
|
||||
}
|
||||
|
||||
std::string GameResID::entityType()
|
||||
{
|
||||
return "resource";
|
||||
}
|
||||
|
||||
std::string SecondarySkill::entityType()
|
||||
{
|
||||
return "secondarySkill";
|
||||
|
@ -14,8 +14,8 @@
|
||||
|
||||
VCMI_LIB_NAMESPACE_BEGIN
|
||||
|
||||
const ui32 SERIALIZATION_VERSION = 827;
|
||||
const ui32 MINIMAL_SERIALIZATION_VERSION = 827;
|
||||
const ui32 SERIALIZATION_VERSION = 828;
|
||||
const ui32 MINIMAL_SERIALIZATION_VERSION = 828;
|
||||
const std::string SAVEGAME_MAGIC = "VCMISVG";
|
||||
|
||||
class CHero;
|
||||
|
Loading…
x
Reference in New Issue
Block a user