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


Joined: 05 Feb 2005
Posts: 4

PostPosted: Wed Mar 09, 2005 12:47 pm   

need help in making a varible path
 
I have an area on zmud mapped out and have paths set up from monster to monster, such as,
start
mob1 e;e;s;e
mob2 e;s;e
mob3 e;e;e

ect....

is there anyway i can set up a variable off the
"You don't see that target here." which is the message i get after i killed everything in the room and try to backstab again but nothing is there.
I would like it to add 1 to a variable and that trigger my route to my next mob, such as from mob1 to mob2.


Hope you can help
Rfallengods
Reply with quote
Dharkael
Enchanter


Joined: 05 Mar 2003
Posts: 593
Location: Canada

PostPosted: Wed Mar 09, 2005 1:48 pm   
 
Code:
#CLASS {Test}
#VAR count {0}
#VAR mobspath {(mob1|e|e|s|e)|(mob2|e|s|e)|(mob3|e|e|e)}
#VAR mobname {}
#VAR templ {}
#TRIGGER {^You don't see that target here.} {#add count 1
#if (@count <= %numitems(@mobspath) {#var templ %item(@mobspath,@count)
#var mobname %pop(templ)
#loop %numitems(@templ) {%pop(templ)}
kill @mobname
} {done}}
#CLASS 0


The mobspath variable is a list containing other sublists.
The sublists have the name of the mob as the first item,
and the other items inthe sublist are directions on how to get to that mob.
done could be an alias you fire when your done the list
_________________
-Dharkael-
"No matter how subtle the wizard, a knife between the shoulder blades will seriously cramp his style."
Reply with quote
Spartacus
Wanderer


Joined: 23 Apr 2001
Posts: 53
Location: USA

PostPosted: Wed Mar 09, 2005 4:21 pm   
 
What I would do in this situation is make sure that all the possible rooms you want to go to have short names (%roomid) or [IDName] if you want to hit it through a query. If you name them mob1, mob2, mob3, etc it might make things easier to automate.

Then set up a list of those shortnames:
#VA myRoomList {%mapquery([IDName] like 'mob%')}

You could also manually populate your list with the room numbers...

Then use #walk to go to the next room:
#walk %item(@myRoomList,@count)
_________________
Spartacus
rm -rf .*
Reply with quote
rfallengods23
Newbie


Joined: 05 Feb 2005
Posts: 4

PostPosted: Wed Mar 09, 2005 11:33 pm   still haveing a problem
 
For some reason i entered in the list of varibles and the add counts
for some reason it isn`t working at all
can you please explain in what order and if i need to have each one in its own trigger,varible, ect ....
Reply with quote
Dharkael
Enchanter


Joined: 05 Mar 2003
Posts: 593
Location: Canada

PostPosted: Thu Mar 10, 2005 12:00 am   
 
Why dont you show us what you have now, then maybe we can see whats going on.
_________________
-Dharkael-
"No matter how subtle the wizard, a knife between the shoulder blades will seriously cramp his style."
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