forked from teamnwah/openmw-tes3coop
Issue #342: various fixes
This commit is contained in:
parent
76de2f7360
commit
beb18282bb
2 changed files with 4 additions and 4 deletions
|
@ -18,8 +18,8 @@ namespace MWMechanics
|
||||||
{
|
{
|
||||||
// magic effects
|
// magic effects
|
||||||
adjustMagicEffects (ptr);
|
adjustMagicEffects (ptr);
|
||||||
calculateDynamicStats (ptr);
|
|
||||||
calculateCreatureStatModifiers (ptr);
|
calculateCreatureStatModifiers (ptr);
|
||||||
|
calculateDynamicStats (ptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Actors::updateNpc (const MWWorld::Ptr& ptr, float duration, bool paused)
|
void Actors::updateNpc (const MWWorld::Ptr& ptr, float duration, bool paused)
|
||||||
|
@ -78,7 +78,7 @@ namespace MWMechanics
|
||||||
int modifier = creatureStats.mMagicEffects.get (EffectKey (79, i)).mMagnitude
|
int modifier = creatureStats.mMagicEffects.get (EffectKey (79, i)).mMagnitude
|
||||||
- creatureStats.mMagicEffects.get (EffectKey (17, i)).mMagnitude;
|
- creatureStats.mMagicEffects.get (EffectKey (17, i)).mMagnitude;
|
||||||
|
|
||||||
creatureStats.mAttributes[0].setModifier (modifier);
|
creatureStats.mAttributes[i].setModifier (modifier);
|
||||||
}
|
}
|
||||||
|
|
||||||
// dynamic stats
|
// dynamic stats
|
||||||
|
@ -87,7 +87,7 @@ namespace MWMechanics
|
||||||
int modifier = creatureStats.mMagicEffects.get (EffectKey (80+i)).mMagnitude
|
int modifier = creatureStats.mMagicEffects.get (EffectKey (80+i)).mMagnitude
|
||||||
- creatureStats.mMagicEffects.get (EffectKey (18+i)).mMagnitude;
|
- creatureStats.mMagicEffects.get (EffectKey (18+i)).mMagnitude;
|
||||||
|
|
||||||
creatureStats.mDynamic[0].setModifier (modifier);
|
creatureStats.mDynamic[i].setModifier (modifier);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,7 @@ namespace MWWorld
|
||||||
|
|
||||||
void ActionApplyWithSkill::execute()
|
void ActionApplyWithSkill::execute()
|
||||||
{
|
{
|
||||||
if (MWWorld::Class::get (mTarget).apply (mTarget, mId, mActor))
|
if (MWWorld::Class::get (mTarget).apply (mTarget, mId, mActor) && mUsageType!=-1)
|
||||||
MWWorld::Class::get (mTarget).skillUsageSucceeded (mActor, mSkillIndex, mUsageType);
|
MWWorld::Class::get (mTarget).skillUsageSucceeded (mActor, mSkillIndex, mUsageType);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue