Jump to content

Script Help: forceav on event or alternative?


eschaeon

Recommended Posts

I'm trying to create a spell effect that basically stops a NPC immediately. The idea is they can still attack/range spells but can't move. I've gone through a bunch of trial/errors with carryweight and the like but it seems like NPCs are not affected by encumbrance (I can't find out why for the life of me).

 

So my next idea was doing a speedmult of 1, to basically make them unable to move. Unfortunately the spell effect of speedmult only seems to be able to do positive amounts (Even with detrimental selected). I was also unable to achieve the effect using console commands. Only forceav can set it to 1 on NPCs or me.

 

Anyone have a suggestion for a script for this? Or maybe does anyone know how to force NPCs to be affected by their carryweight like the player is?

Link to comment
Share on other sites

What do you mean by the papyrus speedmult? I only know about the actor value.

 

Nevermind I was confusing myself.

 

What I'm talking about is the speedmult value modifier under spells. Normal speed is 100%, so a detrimental magnitude of 99 should take it to 1%?

Link to comment
Share on other sites

I was wrong about speedmult having 1.0 default value, it really is 100.0. I tried making a spell myself but it doesn't seem to work. It seems to be bugged similar to 'Marked For Death'. Try using a script like this instead:

 

Scriptname Example extends ActiveMagicEffect

float OldSpeedMult

Event OnEffectStart(Actor akTarget, Actor akCaster)
OldSpeedMult = akTarget.GetAV("SpeedMult")
akTarget.SetAV("SpeedMult", 1)
EndEvent

Event OnEffectFinish(Actor akTarget, Actor akCaster)
akTarget.SetAV("SpeedMult", OldSpeedMult)
EndEvent

Link to comment
Share on other sites

I attached the script to a script spell but still no go. I'm thinking the entire speedmult is either currently completely borked and nothing will work or its being overridden somewhere in the files. I even did something as simple as increasing the magnitude on the Frostslow effect but it did nothing. Edited by eschaeon
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...