Jump to content

Help with spell cast on power attack script?


mutantmnms

Recommended Posts

So I looked at a bunch of older topics on this and also looked at the Bloodskal Blade script, but for some reason I still can't get my script to function exactly the way I want it. The Bloodskal Blade script uses an animation event called "AttackPowerBackward_FXstart" and I tried using the same animation event for my script but it does not work. However, when I use the "HitFrame" animation event instead, my spell is cast at the end of every swing of the weapon. Has anybody used the animation events used in the Bloodskal Blade script and had success with it? I can't figure out why "AttackPowerBackward_FXstart" is not working for me.

 

 

 

Scriptname CJ_ReinhardtsHammerFirestrikeAbility extends ActiveMagicEffect
Spell Property CJ_ReinhardtsHammerFireStrikeSpell auto
Event OnEffectStart(Actor akTarget, Actor akCaster)
if (akCaster == Game.GetPlayer())
Debug.Notification("Magic effect started.")
if (RegisterForAnimationEvent(Game.GetPlayer(), "AttackPowerBackward_FXstart") == true)
Debug.Notification("Events registered.")
endif
endif
EndEvent
Event OnAnimationEvent(ObjectReference akSource, string asEventName)
if (akSource == Game.GetPlayer())
if (asEventName == "AttackPowerBackward_FXstart")
Debug.Notification("Spell casted, remove magicka.")
CJ_ReinhardtsHammerFireStrikeSpell.Cast(Game.GetPlayer())
Game.GetPlayer().damageAv("magicka", 30)
endif
endif
EndEvent
Event OnEffectFinish(Actor akTarget, Actor akCaster)
;Automatically unregisters when ability is removed
EndEvent

Link to comment
Share on other sites

The animation events for the bloodskal blade only work for 2handed swords as they were made specifically for that sword (but will work for any 2 handed sword). That said there are animations for power attacks that will work with other weapons as well check which animations your weapons use in CK, and try those.
Link to comment
Share on other sites

  • Recently Browsing   0 members

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