I am attempting to make my http://www.nexusmods.com/skyrim/images/399015/? http://www.nexusmods.com/skyrim/images/399320/? launch a magicka absorb effect wave when power-bashing. However, after examining the Auriel's Shield scripts and adapting the Dawnguard Rune Hammer script to my own ends... it seems that I did not figure out the anim event for a powerbash.
I reverted it to a regular bash to just make sure the effect was working at all, and it does... so the problem is not knowing what the power bash anim event is.
Here's my script:
Scriptname ShieldOfMagnusAbsorbBlastSCRIPT extends ActiveMagicEffect ;derived from Dawnguard Rune Hammer scriptSPELL PROPERTY AbsorbBlast AUTOEVENT OnEffectStart(Actor target, Actor caster) if(caster == game.getPlayer()) if(RegisterForAnimationEvent(game.getPlayer(), "bashExit") == true) ;debug.trace("bashExit registered") endif endifENDEVENTEVENT OnAnimationEvent(ObjectReference akSource, string asEventName) if(asEventName == "bashExit") ;Debug.trace("Magnus Blast!") ; //cast the Magnus blast AbsorbBlast.cast(game.getPlayer()) endIfENDEVENTEVENT OnUnload() UnregisterForAnimationEvent(game.getPlayer(), "bashExit") ENDEVENT
bashExit works as expected... except that it does it on a normal bash too, not just a powerbash as I want it to. I *thought* it would be bashRelease, but it is not. I cannot use a perk that applies a spell when a powerbash connects, as that only works when the powerbash hits someone, and I want the powerbash to launch a projectile-based spell.