use fProjectileMaxSpeed for ranged weapons distance

pull/335/head^2
rexelion 7 years ago
parent 801f2d42d5
commit a1d9f11b04

@ -115,6 +115,7 @@ namespace MWMechanics
isRanged = false;
static const float fCombatDistance = MWBase::Environment::get().getWorld()->getStore().get<ESM::GameSetting>().find("fCombatDistance")->getFloat();
static const float fProjectileMaxSpeed = MWBase::Environment::get().getWorld()->getStore().get<ESM::GameSetting>().find("fProjectileMaxSpeed")->getFloat();
if (mWeapon.isEmpty())
{
@ -128,7 +129,7 @@ namespace MWMechanics
if (weapon->mData.mType >= ESM::Weapon::MarksmanBow)
{
isRanged = true;
return 1000.f;
return fProjectileMaxSpeed;
}
else
return weapon->mData.mReach * fCombatDistance;

Loading…
Cancel
Save