Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Cuthalion
Beginner


Joined: 29 Jun 2003
Posts: 18
Location: USA

PostPosted: Wed Jul 30, 2003 4:33 am   

Letter's case syntax problem
 
#CLASS {Team}
#ALIAS tcount {#IF (%numparam( ) > 0) {
#ADDI Team {%1}
#ADDK TCount {%1} {1}
}}
#ALIAS unteam {#IF (%numparam( ) > 0) {
#DELI Team {%1}
#DELK TCount {%1}
}}
#ALIAS TeamHealth {
#CLASS {Team|tmp|%1}
#VA %1HP 11 11 {Team|tmp|%1}
#TRIGGER {^%1*death's door} {#VAR %1HP 1} {Team|tmp|%1}
#TRIGGER {^%1*barely alive} {#VAR %1HP 2} {Team|tmp|%1}
#TRIGGER {^%1*terribly hurt} {#VAR %1HP 3} {Team|tmp|%1}
#TRIGGER {^%1*very bad shape} {#VAR %1HP 4} {Team|tmp|%1}
#TRIGGER {^%1*in a bad shape} {#VAR %1HP 5} {Team|tmp|%1}
#TRIGGER {^%1*very hurt} {#VAR %1HP 6} {Team|tmp|%1}
#TRIGGER {^%1*feeling rather hurt} {#VAR %1HP 7} {Team|tmp|%1}
#TRIGGER {^%1*physically hurt} {#VAR %1HP 8} {Team|tmp|%1}
#TRIGGER {^%1*somewhat hurt} {#VAR %1HP 9} {Team|tmp|%1}
#TRIGGER {^%1*slightly hurt} {#VAR %1HP 10} {Team|tmp|%1}
#TRIGGER {^%1*physically feeling very well} {#VAR %1HP 11} {Team|tmp|%1}
#BUTTON 0 "%1" {@%1HP} {} {} {@%1HP} {} {} {Size} {75} {15} {} {} {} {16} {} {Gauge||12|11|3|7} {} {Team|tmp|%1} {Explore|Inset} {ToolTip} {%1} {3}
}
#ALIAS TeamHealthDestroy {#DELCLASS %1}
#TRIGGER {^* with ({@Team}) riding *} {#ADDK TCount {%1} 2}
#TRIGGER {^({@Team}) * mounts *} {#ADDK TCount {%1} 2}
#TRIGGER {^({@Team}) * dismounts *} {#ADDK TCount {%1} 1}
#TRIGGER {^({@Team}) * lands gracefully on *} {#ADDK TCount {%1} 2}
#TRIGGER {^({@Team}) * gracefully climb off *} {#ADDK TCount {%1} 1}
#CLASS 0rc get
#LOOPDB @TCount {#IF {%val = 1} {
buy ticket
give ticket to %key
} {
buy ticket
buy ticket
give ticket to %key
give ticket to %key
}}
#IF {@Horse = 1} {buy ticket} {
buy ticket
buy ticket
}
board
rc put


guess what?
this script does everything it is suppose to do and that is great

BUT

The very evil mud I am playing outputs names in uppercase and takes names within commands only in lower case so

I need an idea

I never know who is going to join my team...
that is the reason for the script...
can it be added to this script to change upper case characters to lower case?
thanks,
Cuthalion
Reply with quote
Cuthalion
Beginner


Joined: 29 Jun 2003
Posts: 18
Location: USA

PostPosted: Wed Jul 30, 2003 4:58 am   
 
what if in every instance I used #ADDK I do...{#ADDK TCount %lower{%1} 1}
will that work?
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Wed Jul 30, 2003 8:17 am   
 
Yes, that should do it. The two main methods would be:
1. Use %lower to change names to lowercase on input (your solution)
2. Use %lower to change names to lowercase on output (give ticket to %lower( %key))

You can use either method or both.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net