diff options
author | aap <aap@papnet.eu> | 2019-07-02 07:43:00 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-07-02 07:43:00 +0200 |
commit | b2d1433392483c3e1faafcf5127885cb425527e0 (patch) | |
tree | 477b9853bea245d9cbdaa8700e02ff980abe79d5 /src/weapons | |
parent | Merge pull request #85 from erorcun/erorcun (diff) | |
parent | Kangaroo cheat and bug fixes (diff) | |
download | re3-b2d1433392483c3e1faafcf5127885cb425527e0.tar re3-b2d1433392483c3e1faafcf5127885cb425527e0.tar.gz re3-b2d1433392483c3e1faafcf5127885cb425527e0.tar.bz2 re3-b2d1433392483c3e1faafcf5127885cb425527e0.tar.lz re3-b2d1433392483c3e1faafcf5127885cb425527e0.tar.xz re3-b2d1433392483c3e1faafcf5127885cb425527e0.tar.zst re3-b2d1433392483c3e1faafcf5127885cb425527e0.zip |
Diffstat (limited to '')
-rw-r--r-- | src/weapons/Weapon.h | 2 | ||||
-rw-r--r-- | src/weapons/WeaponInfo.cpp | 8 |
2 files changed, 4 insertions, 6 deletions
diff --git a/src/weapons/Weapon.h b/src/weapons/Weapon.h index 055e2ff3..8cb435ce 100644 --- a/src/weapons/Weapon.h +++ b/src/weapons/Weapon.h @@ -47,7 +47,7 @@ public: eWeaponState m_eWeaponState; uint32 m_nAmmoInClip; uint32 m_nAmmoTotal; - int32 m_nTimer; + uint32 m_nTimer; bool m_bAddRotOffset; CWeapon() { diff --git a/src/weapons/WeaponInfo.cpp b/src/weapons/WeaponInfo.cpp index 46ecfb54..4830c86a 100644 --- a/src/weapons/WeaponInfo.cpp +++ b/src/weapons/WeaponInfo.cpp @@ -61,7 +61,7 @@ CWeaponInfo::LoadWeaponData(void) char animToPlay[32], anim2ToPlay[32]; CAnimBlendAssociation *animAssoc; - AnimationId animId, anim2Id; + AnimationId animId; int bp, buflen; int lp, linelen; @@ -101,7 +101,6 @@ CWeaponInfo::LoadWeaponData(void) fireOffsetY = 0.0f; fireOffsetZ = 0.0f; animId = ANIM_WALK; - anim2Id = ANIM_WALK; sscanf( &line[lp], "%s %s %f %d %d %d %d %f %f %f %f %f %f %f %s %s %f %f %f %f %d %d", @@ -136,9 +135,9 @@ CWeaponInfo::LoadWeaponData(void) animAssoc = CAnimManager::GetAnimAssociation(ASSOCGRP_STD, animToPlay); animId = static_cast<AnimationId>(animAssoc->animId); - if (strncmp(anim2ToPlay, "null", 5) != 0) { + if (strncmp(anim2ToPlay, "null", 4) != 0) { animAssoc = CAnimManager::GetAnimAssociation(ASSOCGRP_STD, anim2ToPlay); - anim2Id = static_cast<AnimationId>(animAssoc->animId); + ms_apWeaponInfos[weaponType].m_Anim2ToPlay = static_cast<AnimationId>(animAssoc->animId); } CVector vecFireOffset(fireOffsetX, fireOffsetY, fireOffsetZ); @@ -155,7 +154,6 @@ CWeaponInfo::LoadWeaponData(void) ms_apWeaponInfos[weaponType].m_fSpread = spread; ms_apWeaponInfos[weaponType].m_vecFireOffset = vecFireOffset; ms_apWeaponInfos[weaponType].m_AnimToPlay = animId; - ms_apWeaponInfos[weaponType].m_Anim2ToPlay = anim2Id; ms_apWeaponInfos[weaponType].m_fAnimLoopStart = animLoopStart * 0.03f; ms_apWeaponInfos[weaponType].m_fAnimLoopEnd = animLoopEnd * 0.03f; ms_apWeaponInfos[weaponType].m_fAnimFrameFire = delayBetweenAnimAndFire * 0.03f; |