1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-04-01 20:36:40 +00:00

Fix clang warning: -Wunused-but-set-variable

apps/openmw/mwmechanics/spellcasting.cpp:45:13: warning: variable 'index' set but not used [-Wunused-but-set-variable]
   45 |         int index = -1;
      |             ^
This commit is contained in:
elsid 2024-03-27 23:00:56 +01:00
parent f456978cc3
commit 262b31cf08
No known key found for this signature in database
GPG key ID: 4DE04C198CBA7625

View file

@ -42,10 +42,8 @@ namespace MWMechanics
{
const auto world = MWBase::Environment::get().getWorld();
std::map<MWWorld::Ptr, std::vector<ESM::IndexedENAMstruct>> toApply;
int index = -1;
for (const ESM::IndexedENAMstruct& effectInfo : effects.mList)
{
++index;
const ESM::MagicEffect* effect = world->getStore().get<ESM::MagicEffect>().find(effectInfo.mData.mEffectID);
if (effectInfo.mData.mRange != rangeType