|
hwired Newbie
Joined: 08 Nov 2006 Posts: 5
|
Posted: Thu Nov 09, 2006 3:08 am
lets give this another try! |
sorry my last post may have been a bit confusing so i'll start again...
mud output will be this:
[quote]
Quote: |
+* A Darkie *+, +* A Darkie *+, +* A Darkie *+, a mob and +* A Darkie *+ are fairly far off north from here |
pretty close = 1 room, fairly far off = 2 rooms, long ways off = 3 rooms
so basically i want zmud to read that and put in a command
gtell 4 darkies 2 north from here
so it needs to read how many rooms what direction and number of enemies...btw enemies are the +* *+ and can be anything in them
ta guys hopefully someone can help |
|
|
|
umdbandit Wanderer
Joined: 31 Oct 2004 Posts: 94
|
Posted: Thu Nov 09, 2006 10:31 pm sample |
do you think you could post a sample output of the text you were describing?
All and all, i think this will be fairly easy to get it to do what you want |
|
_________________ Rufus- Winner of Stuff |
|
|
|
hwired Newbie
Joined: 08 Nov 2006 Posts: 5
|
Posted: Fri Nov 10, 2006 12:05 am |
Quote: |
You scan in all directions:
+* A Darkie *+, +* A Darkie *+, +* A Darkie *+, a mob and +* A Darkie *+ are fairly far off north from here.
|
thats the output,
hope that helps |
|
|
|
umdbandit Wanderer
Joined: 31 Oct 2004 Posts: 94
|
Posted: Fri Nov 10, 2006 2:30 am |
yarr it does help,
but real quick. why dont you care about that mob? And do you just want this to work for darkies, or are you trying to make this as something that will work for all npc's without them being pre-defined?
hrm. ah the mob isnt an enemy |
|
_________________ Rufus- Winner of Stuff |
|
|
|
hwired Newbie
Joined: 08 Nov 2006 Posts: 5
|
Posted: Fri Nov 10, 2006 3:05 am |
basically the mud is a playerkilling mud...Evil players vs Good players
so for example it could be
Quote: |
You scan in all directions:
+* A Pixie *+, +* A Giant *+, +* A High-Elf *+ are pretty close down from here.
|
anything in +* *+ are the opposite aligned players that we gotta kill :)......so yeah anything not inside the +* i want left out
so pretty mud if i scan any enemies i want to inform my group through the command gtell
gtell 3 darkies 1 down from here!!!
thanks hope that clears it up |
|
|
|
umdbandit Wanderer
Joined: 31 Oct 2004 Posts: 94
|
Posted: Fri Nov 10, 2006 3:08 am |
Yeah, i'm just about done with churning out some stuffs to do this. do you have AIM by any chance? Lets chat and we can fine tune this.
|
|
_________________ Rufus- Winner of Stuff |
|
|
|
umdbandit Wanderer
Joined: 31 Oct 2004 Posts: 94
|
Posted: Fri Nov 10, 2006 4:41 am |
alright, so here's what i got for you.
have the first statement reset your variables, and turn on the trigger that will tally up the enemies, and the temp trigger tallies and does the command, then turns it off after it has done its work.
Code: |
#TR {You scan in all directions} {@moblist = 0;@mobdir = 0;@mobdirnum = 0;@mobtypes = 0;#T+ tallytrigger;#T+ dirdisttrigger;#TEMP {from here} {#T- tallytrigger;#T- dirdisttrigger;tallytell}} |
now the tally trigger
Code: |
#TR {~+~*%s&mob%s~*~+} {@temp1 = %ismember(%1,mobtypes;#IF @temp1=0 {#ADDITEM mobtypes %1;@temp2 = %ismember(%1,@mobtypes);#VA type@temp2 1} {#ADD type@temp1 1}} |
now the dirdist trigger
Code: |
#TR {&dist &%wdir from here} {#if %1="pretty close" {@dist = 1};#if %1="long ways off" {@dist = 3};#if %1="fairly far off" {@dist = 2}} |
and the alias that compresses all the strings and sends the tell
Code: |
#ALIAS tallytell {#LOO 1,%numitems(mobtypes) {@temp3 = %concat(%item(mobtypes, %{i}," x",@type%{i});@tellmessage = %concat(@tellmessage,@temp3)};gt @tellmessage are @dist @dir } |
yarrr..... you have to give the triggers the correct id's cause i forgot to do that |
|
_________________ Rufus- Winner of Stuff |
|
|
|
umdbandit Wanderer
Joined: 31 Oct 2004 Posts: 94
|
Posted: Fri Nov 10, 2006 4:43 am |
Also that was a lot more of a pain than i figured it would be!
|
|
_________________ Rufus- Winner of Stuff |
|
|
|
|
|