mirror of https://github.com/AxioDL/metaforce.git
CGameState: Set HP value in LoadGameFileState()
GM8E v0 stores the HP value of the loaded player state into the returned GameFileStateInfo instance. This prevents the health member from being returned uninitialized.
This commit is contained in:
parent
fc87bd8022
commit
9fba0bf50b
|
@ -111,6 +111,7 @@ CGameState::GameFileStateInfo CGameState::LoadGameFileState(const u8* data) {
|
|||
|
||||
CPlayerState playerState(stream);
|
||||
ret.x10_energyTanks = playerState.GetItemCapacity(CPlayerState::EItemType::EnergyTanks);
|
||||
ret.xc_health = playerState.GetHealthInfo().GetHP();
|
||||
|
||||
u32 itemPercent;
|
||||
if (origMLVL == 0x158EFE17)
|
||||
|
|
Loading…
Reference in New Issue