9garr Posted June 3, 2018 Share Posted June 3, 2018 Hey so I'm pretty new to scripting in the Creation Kit (as in, I started 6 hours ago) and I've just been trying to work everything out. My goal is to have a script that makes it so that when any npc is hit by a specific arrow/projectile that I've made, it will transform into a specific animal. I copied some of the script for the Wabbajack to see how far I could get but so far it does nothing. (don't worry about the moose, thats just what I named it) Scriptname MakeMoose extends activemagiceffect OBJECTREFERENCE newRefStore ACTORBASE PROPERTY Moose AUTO dunTransmogrifyAnimal mainScript ACTOR victim EVENT onEffectStart(Actor akTarget, Actor akCaster) victim = akTarget IF(akCaster == game.getPlayer()) randomCreatureMoose(akTarget) ENDIF ENDEVENT FUNCTION randomCreatureMoose(ACTOR targ) targ.disable() newRefStore = targ.placeAtMe(Moose) mainScript = newRefstore AS dunTransmogrifyAnimal mainScript.storedActor = targ ENDFUNCTION My thought is that I can make it a spell of some kind and apply it to an explosion effect that triggers with arrow impact. Any help would be greatly appreciated, thanks. Link to comment Share on other sites More sharing options...
Evangela Posted June 3, 2018 Share Posted June 3, 2018 For this, you'd need to change that event to OnHit instead. OnEffectStart can't detect arrows. Link to comment Share on other sites More sharing options...
SeraphimKensai Posted June 3, 2018 Share Posted June 3, 2018 I'm at a hotel away from my computer, but if you send me a message, I can send you a copy of my script that I use for a poison which causes NPCs to turn into raging werewolves for about 2 minutes before they revert back to their normal selves. Link to comment Share on other sites More sharing options...
9garr Posted June 3, 2018 Author Share Posted June 3, 2018 I did try using OnHit instead of OnEffectStart but I think I did it wrong. When I hit someone with the arrow they would not disappear, and the Moose would spawn behind me (I think, it really wasnt clear). Link to comment Share on other sites More sharing options...
Recommended Posts