|
Aiolos Newbie
Joined: 10 Apr 2007 Posts: 1
|
Posted: Tue Apr 10, 2007 3:59 pm
Disarm trigger |
My scripting skills are non-existant, so I'd love if someone could help me out here.
I have a disarm trigger that works fine -
#TRIGGER {(*) flies from your grasp} {#COLOR orange;#VAR num %numwords( %1);get %word( %1, @num);hold %word( %1, @num)}
But, if I get disarmed while casting a spell it won't work because I can't pick stuff up while casting.
Is it possible to repeat the command when the spell-finishing message is recieved?
The message you get while casting is 'You are busy casting a spell.' (minus the quotes and not always on a new line) and the spell finish message is 'You utter the final words of the incantation.' |
|
|
|
Qaiia Wanderer
Joined: 06 Apr 2007 Posts: 59
|
Posted: Tue Apr 10, 2007 4:36 pm |
Take a look at #COND, maybe?
|
|
|
|
Wyndle Beginner
Joined: 28 Mar 2007 Posts: 20 Location: < here and there >
|
Posted: Tue Apr 10, 2007 6:21 pm |
As a fellow low-level scripter, my advice would be to create a var for spellcasting. When you cast a spell trigger the var to become 1 and when the spell is done trigger it to 0. Then try something like:
Code: |
#VAR spellcasting 0
#TRIGGER {You begin an incantation} {#VAR spellcasting 1}
#TRIGGER {You utter the final words of the incantation.} {#VAR spellcasting 0}
#TRIGGER {(*) flies from your grasp} {#IF (@spellcasting = 0) {#COLOR orange;#VAR num %numwords( %1);get %word( %1, @num);hold %word( %1, @num)} {#ALARM +5 {#COLOR orange;#VAR num %numwords( %1);get %word( %1, @num);hold %word( %1, @num)}} |
You can adapt this in any way or even just adjust the alarm time for the average length of your spellcasting.
Edit: I forgot to mention that setting your spellcasting state in that fashion also leaves it available to be checked by any other code you want to write. |
|
|
|
|
|