diff options
author | aap <aap@papnet.eu> | 2020-05-23 01:19:51 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-23 01:19:51 +0200 |
commit | df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94 (patch) | |
tree | eef75d9927615ef84787aa002ae39e31ec9b00df /src/peds/Ped.cpp | |
parent | Merge pull request #578 from aap/miami (diff) | |
parent | removed debug (diff) | |
download | re3-df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94.tar re3-df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94.tar.gz re3-df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94.tar.bz2 re3-df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94.tar.lz re3-df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94.tar.xz re3-df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94.tar.zst re3-df763bdb9898a67bcdaf94d9b5d3ab542fb5ec94.zip |
Diffstat (limited to 'src/peds/Ped.cpp')
-rw-r--r-- | src/peds/Ped.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/peds/Ped.cpp b/src/peds/Ped.cpp index 2ab3bf48..278e5bef 100644 --- a/src/peds/Ped.cpp +++ b/src/peds/Ped.cpp @@ -6026,7 +6026,6 @@ CPed::SetWaitState(eWaitState state, void *time) case WAITSTATE_GROUND_ATTACK: case WAITSTATE_LANCESITTING: case WAITSTATE_PLAYANIM_HANDSUP_SIMPLE: - assert(0); default: ClearWaitState(); RestoreHeadingRate(); @@ -18534,7 +18533,7 @@ CPed::Save(uint8*& buf) CopyToBuf(buf, m_fHealth); CopyToBuf(buf, m_fArmour); SkipSaveBuf(buf, 148); - for (int i = 0; i < 10; i++) // has to be hardcoded + for (int i = 0; i < 13; i++) // has to be hardcoded m_weapons[i].Save(buf); SkipSaveBuf(buf, 5); CopyToBuf(buf, m_maxWeaponTypeAllowed); @@ -18556,8 +18555,10 @@ CPed::Load(uint8*& buf) SkipSaveBuf(buf, 148); CWeapon bufWeapon; - for (int i = 0; i < 10; i++) { // has to be hardcoded + for (int i = 0; i < 13; i++) { // has to be hardcoded bufWeapon.Load(buf); + if (i >= 10) + continue; // tmp hack before we fix save/load if (bufWeapon.m_eWeaponType != WEAPONTYPE_UNARMED) { int modelId = CWeaponInfo::GetWeaponInfo(bufWeapon.m_eWeaponType)->m_nModelId; |