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
remus
Wanderer


Joined: 06 Jul 2002
Posts: 53
Location: Australia

PostPosted: Sat Jul 03, 2004 6:53 pm   

Capturing from a list to a variable
 
Greetings,
Here is what I am trying to do. I set the variable @findexplorer to the person in the list I wish to find. I then run the list and I want it to keep looking until it find the player at which point it will searching and set the @eranking variable to the number prefixing the name and the @nameranking variable to the suffix but removing the an|a|the.
e.g. 7698 Shadowbound Ssathrin an Itinerant
If @findexplorer is set to Ssathrin I want it to find the line above, stop and set @eranking to 7698 and @nameranking to Itinerant.

The things the suffix can be are:
Sightseer
Vagabond
Itinerant
Rambler
Nomad
Wayfarer
Voyager
Landstrider
Forestwalker
Searcher of Horizons
Vashnarian Climber
Penetrator of the Depths
Desert Roamer
Hunter of the Lost World
Continental Wanderer
Terran Master
Sapient Explorer
Questor of the Far Reaches
Hadionic Seeker
Achaean Ranger

Here is what 1 run of the list looks like. It is set at pagelength 20.
I figure that with the addition of a gag trigger I can add a config pagelength 200 to the beginning of the trigger and then simply add a config pagelength 20 that activates when the targetted line is found?

*********************************[ Explorers ]*********************************
Rank Name Title
-------------------------------------------------------------------------------
1 Phainein Bambi Rousseau a Hadionic Seeker
2 Paine "Slippery When Wet" Saer'rac a Hadionic Seeker
3 Asara Eslofe, the Voice of Neraeos a Hadionic Seeker
4 "Thousand Miles Loner" Rakot Mercadia a Questor of the Far Reaches
5 Idempotent Rousseau a Questor of the Far Reaches
6 Dida's sexy warrior, Nimby Shiva, Awen a Questor of the Far Reaches
7 Fist of Dagon, Garth Jaydde-Stormcrow a Questor of the Far Reaches
8 The Daring Eski Windsong, The Hunter a Questor of the Far Reaches
9 Perpetual Damsel in Distress, Felaroff a Questor of the Far Reaches
10 Cartographer Mistress Skye Demaxx-De'L a Questor of the Far Reaches
11 Thana's Vibrating Lupine Kitt Xanatov- a Questor of the Far Reaches
12 Lord Citrus I'stari, the Citrusian a Questor of the Far Reaches
13 Lupine Whirlwind, Josalyn, the Esteeme a Questor of the Far Reaches
14 Master of the Holy Sword, Latus Siorai a Questor of the Far Reaches
15 Keeper Cirdan, Initiate of Honour a Questor of the Far Reaches
16 Yen Jaydde-Stormcrow, Grace Serene a Questor of the Far Reaches
*******************************************************************************
RANKINGS EXPLORERS 17 for more.

I main problem I seem to have is forming a trigger to capture the info. I tried:
#TR {(%d) {@findexplorer} {a|an|the} (*)}
but it doesnt work, I am guessing its a spacing issue of some description or else I am so far out of the square Im not even in the ball park! :)

Any help is very appreciated.

Thanks in advance.
Remus

PS Even if you can just show me the correct trigger to capture the info, I can probably battle through the creating of the actual script part. :)
Reply with quote
jessew
Apprentice


Joined: 03 Mar 2003
Posts: 141

PostPosted: Mon Jul 05, 2004 5:01 am   
 
So Im sure I understand.
This is what your trying to trigger on: 7698 Shadowbound Ssathrin an Itinerant
The variable findexplorer is equal to : Ssathrin
Your trigger is this: #TR {(%d) {@findexplorer} {a|an|the} (*)}

so we can say your trigger in this case will look like this:
#TRIGGER {(%d) {Ssathrin} {a|an|the} (*)}

If thats the case its not matching because of the word Shadowbound between the Number and Ssathrin
I guess thats the players title before there name.

You could handle it for all cases it seems by doing something like this

#TRIGGER {(%d)*{@findexplorer} {a|an|the} (*)}


If I missed something let me know

Cheers
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Mon Jul 05, 2004 7:38 pm   
 
I think you'll probably need to make a list of all the explorer ranks and use that in your pattern. If you are doing this one person at a time, it would probably have been simpler to just get the numeric ranking, then look it up.
explorers 7698

#VAR Eranks {Sightseer|Vagabond|Hadionic Seeker|Achaean Ranger}
#TR {(%d)* @findexplorer%p* ({@Eranks})} {#VAR eranking %1;#VAR nameranking {%2}}
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