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
Treant99
Newbie


Joined: 27 Jul 2002
Posts: 7
Location: USA

PostPosted: Sun May 16, 2004 2:21 pm   

Alias help
 
Is it possible to set up an alias to run a certain number of times?

Like currently I have an alias using variables, set up to scry mobs so i can find the right one to portal too. The alias is set up as follows

Name: Scry
Value:
#if (%1 = @scrymob) {
#ad scrynr 1
c scry @scrynr.@scrymob
} {
#var scrymob %1
#var scrynr 1
c scry @scrynr.@scrymob
}

Now I used to have it send me a tell with the current variable number and i'd use a trigger to move the alias along but it got really spammy and I was wondering if there is another way to make it run a certain amount then stop like if I was to type scry 1-10 mobname. and have it do 1.mob 2.mob etc and stop at 10. I haven't been able to figure out a way as of late, and about to just give up.
Reply with quote
nexela
Wizard


Joined: 15 Jan 2002
Posts: 1644
Location: USA

PostPosted: Sun May 16, 2004 6:23 pm   
 
Lemme nudge you down the right path

NAME: SCRY
VALUE:
#LOOP %1 {c scry %{i}.%{2}}

Usage examples
scry 5 mobname //scrys 1. 2. 3. 4. 5.mobbane
scry 6,10 mobname //Scrys 6. 7. 8. 9. 10.mobname
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Sun May 16, 2004 8:23 pm   
 
#10 scry mobname
Reply with quote
Treant99
Newbie


Joined: 27 Jul 2002
Posts: 7
Location: USA

PostPosted: Sun May 16, 2004 10:26 pm   
 
works like a charm, thanks for the help Nexela.
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