From fbc9b90ebe01c02fd313d244f6f458393f41ad64 Mon Sep 17 00:00:00 2001 From: scrawl Date: Mon, 5 Sep 2016 00:04:11 +0200 Subject: [PATCH] Cleanup --- apps/openmw/mwmechanics/spellcasting.cpp | 2 -- apps/openmw/mwworld/projectilemanager.cpp | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/apps/openmw/mwmechanics/spellcasting.cpp b/apps/openmw/mwmechanics/spellcasting.cpp index f1c920421..95f2d940f 100644 --- a/apps/openmw/mwmechanics/spellcasting.cpp +++ b/apps/openmw/mwmechanics/spellcasting.cpp @@ -283,8 +283,6 @@ namespace MWMechanics { } - /// Get projectile properties (model, sound and speed) for a spell with the given effects and launch. - /// If \a model is empty, the spell has no ranged effects and should not spawn a projectile. void CastSpell::launchMagicBolt (const ESM::EffectList& effects) { osg::Vec3f fallbackDirection (0,1,0); diff --git a/apps/openmw/mwworld/projectilemanager.cpp b/apps/openmw/mwworld/projectilemanager.cpp index aa5a1b650..844800a41 100644 --- a/apps/openmw/mwworld/projectilemanager.cpp +++ b/apps/openmw/mwworld/projectilemanager.cpp @@ -143,7 +143,7 @@ namespace MWWorld attachTo = rotateNode; } - osg::ref_ptr ptr = mResourceSystem->getSceneManager()->getInstance(model, attachTo); + mResourceSystem->getSceneManager()->getInstance(model, attachTo); if (state.mIdMagic.size() > 1) for (size_t iter = 1; iter != state.mIdMagic.size(); ++iter) @@ -209,7 +209,7 @@ namespace MWWorld state.mEffects = getMagicBoltData(state.mIdMagic, state.mSoundIds, state.mSpeed, effects); // Non-projectile should have been removed by getMagicBoltData - if (state.mEffects.mList.size() == 0) + if (state.mEffects.mList.empty()) return; MWWorld::ManualRef ref(MWBase::Environment::get().getWorld()->getStore(), state.mIdMagic.at(0));