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
fasad
Beginner


Joined: 07 Dec 2003
Posts: 16
Location: USA

PostPosted: Sun Dec 07, 2003 11:54 am   

capturing text into a variable
 

This has frustrated me for a long while now
It seems so simple and probly is I just can't see it right

"makeblade a sharp knife"

i want to put "" into @project
so i can just hit the button and doit
without having to use a #PR

Thanks in advance i hope
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Sun Dec 07, 2003 12:30 pm   
 
I don't understand what you want to do. When do you want this text to be put into a variable? When some message appears in the MUD or when you type something? Is this the same text that will always be entered into the variable, or does it have to be extracted from somewhere else? Try explaining what you want to do again with some more info please.
Reply with quote
Toetag
Magician


Joined: 10 Oct 2000
Posts: 356
Location: USA

PostPosted: Sun Dec 07, 2003 2:48 pm   
 
in the command line type:

#variable project {makeblade a sharp knife}

If i understand what you are looking for.
Reply with quote
fasad
Beginner


Joined: 07 Dec 2003
Posts: 16
Location: USA

PostPosted: Sun Dec 07, 2003 10:32 pm   
 
That worked beautifuly

#variable project {makeblade a sharp knife}

thank you very much
Reply with quote
Toetag
Magician


Joined: 10 Oct 2000
Posts: 356
Location: USA

PostPosted: Sun Dec 07, 2003 11:11 pm   
 
it just dawned on me that what you really need is an Alias not a variable. An alias is like a shortcut for a single or multiple commands. with an alias you can do things like:

#VAR bladetype {a sharp knife}
#ALIAS mb {makeblade @bladetype}


now all you need do is type "mb" and since a variable was used in the command, whatever you set the "bladetype", it will make that type of blade.

Check the Help file for #ALIAS.
Reply with quote
fasad
Beginner


Joined: 07 Dec 2003
Posts: 16
Location: USA

PostPosted: Sun Dec 07, 2003 11:37 pm   
 
they way my project problem is

i start a project say (makeblade a sharp knife)
i get interupted and have to go somewhere else
when i get back to my workshop i want to just hit the project button and i gather my materials and pick up where i left off
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