Ayclaes Newbie
Joined: 31 Mar 2005 Posts: 9
|
Posted: Mon Apr 04, 2005 12:23 am
Problem evaluating first and last entries in a string list |
I'm just having a problem with my triggers not evaluating the first and last entries in a string list. The code and concept are quite simple, but I've added 'spacers' at the beginning and end of the list to get it to highlight. Any ideas?
#CLASS {Games}
#ALIAS gtb {@gteamb = %push( "%1", @gteamb);#ECHO Name : %1;#ECHO Blue List : @gteamb}
#ALIAS gtr {@gteamr = %push( "%1", @gteamr);#ECHO Name : %1;#ECHO Red List : @gteamr}
#ALIAS gtw {@gteamw = %push( "%1", @gteamw);#ECHO Name : %1;#ECHO White List : @gteamw}
#ALIAS gteamreset {#VARIABLE gteamb "spacer";#VARIABLE gteamr "spacer";#VARIABLE gteamw "spacer";#ECHO Blue, Red, and White team lists are reset.}
#ALIAS gteamlist {#ECHO This is the blue team : <@gteamb>;#ECHO This is the red team : <@gteamr>;#ECHO This is the white team : <@gteamw>}
#ALIAS gteamsay {say This is the blue team : <@gteamb>;say This is the red team : <@gteamr>;say This is the white team : <@gteamw>}
#ALIAS gteamfinish {@gteamb = %push( spacer, @gteamb);@gteamr = %push( spacer, @gteamr);@gteamw = %push( spacer, @gteamw);#WAIT 250;gteamlist}
#ALIAS gameshelp {#ECHO Note that zmud won't parse the first and last entries of the lists...hence the spacers;#ECHO Use the 3 aliases to enter teams:;#ECHO gtb <name> adds that name to the blue list;#ECHO gtr <name> adds that name to the red list;#ECHO gtw <name> adds that name to the white list;#ECHO gteamfinish Puts a spacer on all the lists;#ECHO gteamreset resets all the lists;#ECHO gteamlist list all the teams (locally in an echo);#ECHO gteamsay says all the teams for others}
#TRIGGER {{<@gteamb>}} {#CW blue}
#TRIGGER {{<@gteamr>}} {#CW red}
#TRIGGER {{<@gteamw>}} {#CW white}
#CLASS 0 |
|