Jump to content

Any reason Why this Script isn't workig?


Videniofthesith

Recommended Posts

All I want to do is make a spell that only effects the aaafear creatures, cast a light spell, it burns them and uses the fire effect. If it is cast on someone, just uses the normal light spell. And this is what I was given with a few changes took out that the error message said was wrong. It keeps says line 11 is wrong. Help?

 

 

 

 

ScriptName aaaLightUpTheDarknessScript

 

float effecttime

float timer

short targetref

short doonce

 

Begin ScriptEffectStart

set timer to 45

If targetref == aaafear

targetref.addspell abatronachflameeffect

targetref.addspell aaafire

targetref.addspell aaalight

Else

targetref.addspell aaalight

Return

Endif

End

Begin ScriptEffectUpdate

if ( timer > effecttime )

targetref.kill

Return

endif

if ( targetref.getdead == 1 ) && ( timer < ( effecttime-2 )

set timer to ( effecttime-2 )

endif

if ( timer > 0.1 ) && ( doonce == 0 )

targetref.pms effectAtronachFlame 1

set doonce to 1

endif

set timer to timer + GetSecondsPassed

if ( timer > ( effecttime-2 ) ) && ( doonce == 1 )

targetref.kill

set doonce to 2

endif

if ( doonce == 2 )

set fade to fade - 0.03

targetref.saa fade

endif

 

End

 

Begin ScriptEffectFinish

If targetref == aaafear

targetref.removespell abatronachflameeffect

targetref.removespell aaafire

targetref.removespell aaalight

Else

targetref.removespell aaalight

End

Link to comment
Share on other sites

All I want to do is make a spell that only effects the aaafear creatures, cast a light spell, it burns them and uses the fire effect. If it is cast on someone, just uses the normal light spell. And this is what I was given with a few changes took out that the error message said was wrong. It keeps says line 11 is wrong. Help?

 

 

 

 

 

ScriptName aaaLightUpTheDarknessScript

 

float effecttime

float timer

short targetref

short doonce

 

Begin ScriptEffectStart

set timer to 45

If targetref == aaafear

targetref.addspell abatronachflameeffect

targetref.addspell aaafire

targetref.addspell aaalight

Else

targetref.addspell aaalight

Return

Endif

End

Begin ScriptEffectUpdate

if ( timer > effecttime )

targetref.kill

Return

endif

if ( targetref.getdead == 1 ) && ( timer < ( effecttime-2 )

set timer to ( effecttime-2 )

endif

if ( timer > 0.1 ) && ( doonce == 0 )

targetref.pms effectAtronachFlame 1

set doonce to 1

endif

set timer to timer + GetSecondsPassed

if ( timer > ( effecttime-2 ) ) && ( doonce == 1 )

targetref.kill

set doonce to 2

endif

if ( doonce == 2 )

set fade to fade - 0.03

targetref.saa fade

endif

 

End

 

Begin ScriptEffectFinish

If targetref == aaafear

targetref.removespell abatronachflameeffect

targetref.removespell aaafire

targetref.removespell aaalight

Else

targetref.removespell aaalight

End

 

 

 

** script put into spoiler tags **

Why could you not have kept this in the original thread? I give up!

Link to comment
Share on other sites

  • Recently Browsing   0 members

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