jimhsu Posted July 9, 2012 Share Posted July 9, 2012 Trying something non serious, but wacky fun. But here's the setup: 1. A single actor in the world is initialized with, say, a disease (with a ReferenceAlias script).2. SetAV aggression 3 and hilarity ensues.3. OnDeath of that actor, infect the killer of that actor with the disease (with say some probability).4. SetAV aggression 3 and hilarity ensues, again.5. OnDeath of the second actor .. so on and so forth. Eventually the whole of skyrim goes insane (probably) unless I intervene. The problem I am having with the script in the Reference Alias panel is that while I get the alias handoffs just fine (with ForceRefTo), I can't get the alias script to run on the 2nd actor (so OnDeath doesn't work on step 5). Is this at all possible or should I use a different approach? Bear in mind that the killer can be ANY actor, so obviously having OnDeath scripts for every actor in the game is not practical. Link to comment Share on other sites More sharing options...
jimhsu Posted July 9, 2012 Author Share Posted July 9, 2012 Could this work if I wrapped the entire thing up as an ActiveMagicEffect? I still need to get OnDeath somehow though. Link to comment Share on other sites More sharing options...
pauderek Posted July 9, 2012 Share Posted July 9, 2012 (edited) The OnDeath() event can be used in magic effect, it will detect the actor that has that magic effect. For what you are trying to do I think it's the best way. If the magic effect is dispelled on death I recommend you to use the OnDying() event instead. Edited July 9, 2012 by pauderek Link to comment Share on other sites More sharing options...
jimhsu Posted July 9, 2012 Author Share Posted July 9, 2012 (edited) Oh, I neglected to read the final line from the Creation Kit wiki: "ActiveMagicEffects will also receive events from the Actor they are attached to. " Interesting. Will try this out. Edited July 9, 2012 by jimhsu Link to comment Share on other sites More sharing options...
Recommended Posts