|
|
|
@ -182,29 +182,11 @@ namespace MWMechanics
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
float bestArrowRating = 0;
|
|
|
|
|
MWWorld::Ptr bestArrow;
|
|
|
|
|
for (MWWorld::ContainerStoreIterator it = store.begin(); it != store.end(); ++it)
|
|
|
|
|
{
|
|
|
|
|
float rating = rateWeapon(*it, actor, enemy, ESM::Weapon::Arrow);
|
|
|
|
|
if (rating > bestArrowRating)
|
|
|
|
|
{
|
|
|
|
|
bestArrowRating = rating;
|
|
|
|
|
bestArrow = *it;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
float bestArrowRating = rateAmmo(actor, enemy, bestArrow, ESM::Weapon::Arrow);
|
|
|
|
|
|
|
|
|
|
float bestBoltRating = 0;
|
|
|
|
|
MWWorld::Ptr bestBolt;
|
|
|
|
|
for (MWWorld::ContainerStoreIterator it = store.begin(); it != store.end(); ++it)
|
|
|
|
|
{
|
|
|
|
|
float rating = rateWeapon(*it, actor, enemy, ESM::Weapon::Bolt);
|
|
|
|
|
if (rating > bestBoltRating)
|
|
|
|
|
{
|
|
|
|
|
bestBoltRating = rating;
|
|
|
|
|
bestBolt = *it;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
float bestBoltRating = rateAmmo(actor, enemy, bestBolt, ESM::Weapon::Bolt);
|
|
|
|
|
|
|
|
|
|
for (MWWorld::ContainerStoreIterator it = store.begin(); it != store.end(); ++it)
|
|
|
|
|
{
|
|
|
|
@ -277,25 +259,9 @@ namespace MWMechanics
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
float bestArrowRating = 0;
|
|
|
|
|
for (MWWorld::ContainerStoreIterator it = store.begin(); it != store.end(); ++it)
|
|
|
|
|
{
|
|
|
|
|
float rating = rateWeapon(*it, actor, enemy, ESM::Weapon::Arrow);
|
|
|
|
|
if (rating > bestArrowRating)
|
|
|
|
|
{
|
|
|
|
|
bestArrowRating = rating;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
float bestArrowRating = rateAmmo(actor, enemy, ESM::Weapon::Arrow);
|
|
|
|
|
|
|
|
|
|
float bestBoltRating = 0;
|
|
|
|
|
for (MWWorld::ContainerStoreIterator it = store.begin(); it != store.end(); ++it)
|
|
|
|
|
{
|
|
|
|
|
float rating = rateWeapon(*it, actor, enemy, ESM::Weapon::Bolt);
|
|
|
|
|
if (rating > bestBoltRating)
|
|
|
|
|
{
|
|
|
|
|
bestBoltRating = rating;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
float bestBoltRating = rateAmmo(actor, enemy, ESM::Weapon::Bolt);
|
|
|
|
|
|
|
|
|
|
for (MWWorld::ContainerStoreIterator it = store.begin(); it != store.end(); ++it)
|
|
|
|
|
{
|
|
|
|
|