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
Latent
Apprentice


Joined: 19 Aug 2002
Posts: 120
Location: USA

PostPosted: Sat Dec 06, 2003 3:21 am   

Removing part of a variable when using it?
 
Ok, for this example, I have a variable called @test, now inside of @test is 5.hotdog. I want to call the contents of the variable but chop off the 5. OR another way it would work is if I have a variable, let's say "chomp" that will store the following word into @test, and when I use chomp 5.hotdog, instead of storing 5.hotdog, have it store just hotdog instead, there won't ALWAYS be a 5., but when there is, I want it gone when I store hotdog

Is there a way I can do this?
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Sat Dec 06, 2003 4:22 am   
 
#AL chomp {#VAR test %right( "%1", %pos( ".", "%1"))}
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