mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-20 06:23:52 +00:00
Fix typo (should be Strength, not Luck). Use GMSTs for strength damage.
This commit is contained in:
parent
1617a4f7d9
commit
82a07af72c
2 changed files with 9 additions and 1 deletions
|
@ -252,6 +252,8 @@ namespace MWClass
|
|||
fKnockDownMult = gmst.find("fKnockDownMult");
|
||||
iKnockDownOddsMult = gmst.find("iKnockDownOddsMult");
|
||||
iKnockDownOddsBase = gmst.find("iKnockDownOddsBase");
|
||||
fDamageStrengthBase = gmst.find("fDamageStrengthBase");
|
||||
fDamageStrengthMult = gmst.find("fDamageStrengthMult");
|
||||
|
||||
inited = true;
|
||||
}
|
||||
|
@ -524,7 +526,8 @@ namespace MWClass
|
|||
if(attack)
|
||||
{
|
||||
damage = attack[0] + ((attack[1]-attack[0])*stats.getAttackStrength());
|
||||
damage *= 0.5f + (stats.getAttribute(ESM::Attribute::Luck).getModified() / 100.0f);
|
||||
damage *= fDamageStrengthBase->getFloat() +
|
||||
(stats.getAttribute(ESM::Attribute::Strength).getModified() * fDamageStrengthMult->getFloat() * 0.1);
|
||||
if(weaphashealth)
|
||||
{
|
||||
int weapmaxhealth = weapon.get<ESM::Weapon>()->mBase->mData.mHealth;
|
||||
|
@ -1254,4 +1257,7 @@ namespace MWClass
|
|||
const ESM::GameSetting *Npc::fKnockDownMult;
|
||||
const ESM::GameSetting *Npc::iKnockDownOddsMult;
|
||||
const ESM::GameSetting *Npc::iKnockDownOddsBase;
|
||||
const ESM::GameSetting *Npc::fDamageStrengthBase;
|
||||
const ESM::GameSetting *Npc::fDamageStrengthMult;
|
||||
|
||||
}
|
||||
|
|
|
@ -36,6 +36,8 @@ namespace MWClass
|
|||
static const ESM::GameSetting *fKnockDownMult;
|
||||
static const ESM::GameSetting *iKnockDownOddsMult;
|
||||
static const ESM::GameSetting *iKnockDownOddsBase;
|
||||
static const ESM::GameSetting *fDamageStrengthBase;
|
||||
static const ESM::GameSetting *fDamageStrengthMult;
|
||||
|
||||
public:
|
||||
|
||||
|
|
Loading…
Reference in a new issue