forked from mirror/openmw-tes3mp
Merge pull request #1089 from Allofich/bound
Corrections for bound equipment
This commit is contained in:
commit
721062a4bd
2 changed files with 11 additions and 12 deletions
|
@ -146,9 +146,6 @@ namespace MWClass
|
||||||
|
|
||||||
float epsilon = 0.0005f;
|
float epsilon = 0.0005f;
|
||||||
|
|
||||||
if (ref->mBase->mData.mWeight == 0)
|
|
||||||
return ESM::Skill::Unarmored;
|
|
||||||
|
|
||||||
if (ref->mBase->mData.mWeight <= iWeight * gmst.find ("fLightMaxMod")->getFloat() + epsilon)
|
if (ref->mBase->mData.mWeight <= iWeight * gmst.find ("fLightMaxMod")->getFloat() + epsilon)
|
||||||
return ESM::Skill::LightArmor;
|
return ESM::Skill::LightArmor;
|
||||||
|
|
||||||
|
@ -220,16 +217,19 @@ namespace MWClass
|
||||||
std::string text;
|
std::string text;
|
||||||
|
|
||||||
// get armor type string (light/medium/heavy)
|
// get armor type string (light/medium/heavy)
|
||||||
int armorType = getEquipmentSkill(ptr);
|
|
||||||
std::string typeText;
|
std::string typeText;
|
||||||
if (armorType == ESM::Skill::LightArmor)
|
if (ref->mBase->mData.mWeight == 0)
|
||||||
typeText = "#{sLight}";
|
|
||||||
else if (armorType == ESM::Skill::MediumArmor)
|
|
||||||
typeText = "#{sMedium}";
|
|
||||||
else if (armorType == ESM::Skill::HeavyArmor)
|
|
||||||
typeText = "#{sHeavy}";
|
|
||||||
else // if (armorType == ESM::Skill::Unarmored)
|
|
||||||
typeText = "";
|
typeText = "";
|
||||||
|
else
|
||||||
|
{
|
||||||
|
int armorType = getEquipmentSkill(ptr);
|
||||||
|
if (armorType == ESM::Skill::LightArmor)
|
||||||
|
typeText = "#{sLight}";
|
||||||
|
else if (armorType == ESM::Skill::MediumArmor)
|
||||||
|
typeText = "#{sMedium}";
|
||||||
|
else
|
||||||
|
typeText = "#{sHeavy}";
|
||||||
|
}
|
||||||
|
|
||||||
text += "\n#{sArmorRating}: " + MWGui::ToolTips::toString(getEffectiveArmorRating(ptr,
|
text += "\n#{sArmorRating}: " + MWGui::ToolTips::toString(getEffectiveArmorRating(ptr,
|
||||||
MWMechanics::getPlayer()));
|
MWMechanics::getPlayer()));
|
||||||
|
|
|
@ -1160,7 +1160,6 @@ namespace MWClass
|
||||||
|
|
||||||
switch(boots->getClass().getEquipmentSkill(*boots))
|
switch(boots->getClass().getEquipmentSkill(*boots))
|
||||||
{
|
{
|
||||||
case ESM::Skill::Unarmored:
|
|
||||||
case ESM::Skill::LightArmor:
|
case ESM::Skill::LightArmor:
|
||||||
return (name == "left") ? "FootLightLeft" : "FootLightRight";
|
return (name == "left") ? "FootLightLeft" : "FootLightRight";
|
||||||
case ESM::Skill::MediumArmor:
|
case ESM::Skill::MediumArmor:
|
||||||
|
|
Loading…
Reference in a new issue