From b631b5f3a198b99b045f1ca5ed767c4832054fbc Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sun, 12 Apr 2020 11:31:25 -0400 Subject: [PATCH] CGunWeapon: Mark skShootAnim as constexpr Enforce it as constexpr. The initializer is likely optimized away anyways, given the array only contains primitives, but this is more consistent. --- Runtime/Weapon/CGunWeapon.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Runtime/Weapon/CGunWeapon.cpp b/Runtime/Weapon/CGunWeapon.cpp index 5a24b9028..1954fd08a 100644 --- a/Runtime/Weapon/CGunWeapon.cpp +++ b/Runtime/Weapon/CGunWeapon.cpp @@ -178,7 +178,7 @@ void CGunWeapon::UpdateGunFx(bool shotSmoke, float dt, const CStateManager& mgr, } } -const std::array CGunWeapon::skShootAnim{4, 3}; +constexpr std::array CGunWeapon::skShootAnim{4, 3}; void CGunWeapon::Fire(bool underwater, float dt, EChargeState chargeState, const zeus::CTransform& xf, CStateManager& mgr, TUniqueId homingTarget, float chargeFactor1, float chargeFactor2) {