[Help] Attaching a script as a spelleffect (Doens't work for

Post » Thu Nov 22, 2012 6:16 am

Hey,

I hope you guys can help me out here:

Im trying to make a working "sun blocker" script which is based on the same code as the real Auriels-Bow Player Script. I edited in the code and added some stuff.


Here is my code:

Scriptname DLC1AurielsBowPlayerScriptCustom extends ActiveMagicEffect  Spell Property DLC1AurielsBowEclipseSpell AutoActor SubjectActor casterEvent OnEffectStart(Actor akTarget, Actor akCaster)caster = akTargetdoEclipse()endEventFunction doEclipse()  Debug.Trace("My function called!")Subject = casterDLC1AurielsBowEclipseSpell.Cast(Subject,Subject)RegisterForSingleUpdateGameTime(20 - GameHour.Value)DLC1EclipseActive.Value = http://forums.bethsoft.com/topic/1424986-help-attaching-a-script-as-a-spelleffect-doenst-work-for-me/1.0EndFunctionEvent OnUpdateGameTime()DLC1EclipseActive.Value = 0Subject.DispelSpell(DLC1AurielsBowEclipseSpell)EndEventGlobalVariable Property DLC1EclipseActive  Auto  GlobalVariable Property GameHour  Auto 




and here is my setup in the creation kit:

Spoiler

img688.imageshack(dot)us/img688/8383/skyrim1s.png


For some reason when i try to activate the spell ingame, nothing happens :(

Please help.


Thanks.
User avatar
Charles Weber
 
Posts: 3447
Joined: Wed Aug 08, 2007 5:14 pm

Return to V - Skyrim