» Sat Feb 19, 2011 5:41 am
It says mismatched beginning and end
ScriptName SummonSusano01
;This script can be used as a template for custom summoned creatures/NPC's
float timer
float fade
short playonce
ref SUMN
Begin ScriptEffectStart
;Set temp reference for scripting.
;Allows faster transition of script as template. Also allows for leveled summon.
set SUMN to SummonSusano01
;Reset our creature if re-summoned before time runs out on spell
SUMN.disable
;Now we move our creature to the Player
;Move the creature reference to the worldspace of the Player
SUMN.moveto Player 30 30 10
;Make our creature visible and active
SUMN.enable
set fade to 1 ;Resets the alpha fade variable to 1
End
Begin ScriptEffectUpdate
if ( timer > 30 ) ;Creature is dead and fade timer passed
;Move our creature back to it's holding cell
SUMN.kill
SUMN.moveto CreatureCage 0 0 10
;Reset our creature if dead
SUMN.resurrect
;Set our creature to an unprocessed state
SUMN.disable
endif
;Adjust timer state for early fade/disable upon death
if ( SUMN.getdead == 1 ) && ( timer < 28 )
set timer to 28
endif
if ( timer > 0.1 ) && ( playonce == 0 )
;Play effect for creature entrance
SUMN.pms effectSummonMythicDawn 1
set playonce to 1
endif
;Increment timer
set timer to timer + GetSecondsPassed
if ( timer > 28 ) && ( playonce == 1 )
;Play effect for creature exit/death
SUMN.kill
set playonce to 2
endif
if ( playonce == 2 )
;Fade creature for exit/death
set fade to fade - 0.03
SUMN.saa fade
endif
End
Begin ScriptEffectFinish
;Move our creature back to it's holding cell
SUMN.moveto CreatureCageREF 0 0 10
;Reset our creature if dead
SUMN.resurrect
;Set our creature to an unprocessed state
SUMN.disable