remus Wanderer
Joined: 06 Jul 2002 Posts: 53 Location: Australia
|
Posted: Mon Feb 03, 2003 7:35 pm
Empty variable stop and message |
Hello everyone,
Anyone have any ideas how to acomplish what I am trying to do?
Here is the problem at present. I have a spellup script I wrote. I have listed it below. What I would like to do is stop it firing on the last after the string defs is empty. As an example if I set @targ as Mastermune what happens is that it fires off to the string is empty and then fires a line with just Mastermune causing the infamous HUH? response from the mud.
It needs to stay with the @targ on the end so that if I set #var targ {} then I can use the script on myself
Anyways here is the script:
#CLASS {DEFENCE_SYS}
#ALIAS adddef {#ADDI spellupX "cast %1";#echo %1 has been added to your defences list.}
#ALIAS defup {#ECHO Def system Active;%item( @defs, "1") @targ}
#ALIAS resetdefs {#VAR defs @spellupX;#ECHO Defences reset}
#VAR defs {}
#VAR spellupX {cast dragonskin|cast barkskin|cast iceshield|cast fireshield|cast cloak|cast camo|cast float|cast detect|cast nature|cast gaincon|cast gainint|cast sanctum|}
#TRIGGER {You enchant yourself (*)} {#DELN defs 1;%item( @defs, "1") @targ}
#TRIGGER {FIZZLE....the player has (*) already up} {#DELN defs 1;%item( @defs, "1") @targ}
#TRIGGER {You lost your concentration.} {%item( @defs, "1") @targ}
#TRIGGER {^You cast the spell (*) on (*).} {#DELN defs 1;%item( @defs, "1") @targ}
#TRIGGER {Your cloak of nature adds} {#DELN defs 1;%item( @defs, "1") @targ}
#TRIGGER {Your cloak of nature is already cast upon you.} {#DELN defs 1;%item( @defs, "1") @targ}
#TRIGGER (@defs=) {#var @targ {};#echo Defence system completed}
#CLASS 0
Remus Parish aka
Rangek, Fist of the Slayers Hand.
coa.servegame.com port:23 |
|