mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-23 22:37:55 +02:00
Remove serialization of raw pointers from serialization
This commit is contained in:
@@ -40,6 +40,8 @@ CampaignHeroReplacement::CampaignHeroReplacement(std::shared_ptr<CGHeroInstance>
|
||||
{
|
||||
}
|
||||
|
||||
CGameStateCampaign::CGameStateCampaign() = default;
|
||||
|
||||
CGameStateCampaign::CGameStateCampaign(CGameState * owner):
|
||||
gameState(owner)
|
||||
{
|
||||
@@ -47,6 +49,11 @@ CGameStateCampaign::CGameStateCampaign(CGameState * owner):
|
||||
assert(gameState->scenarioOps->campState != nullptr);
|
||||
}
|
||||
|
||||
void CGameStateCampaign::setGamestate(CGameState * owner)
|
||||
{
|
||||
gameState = owner;
|
||||
}
|
||||
|
||||
std::optional<CampaignBonus> CGameStateCampaign::currentBonus() const
|
||||
{
|
||||
auto campaignState = gameState->scenarioOps->campState;
|
||||
|
||||
Reference in New Issue
Block a user