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


Joined: 30 Mar 2005
Posts: 3

PostPosted: Wed Mar 30, 2005 2:30 am   

Problem with capturing a line from a mud
 
I want to tell whether a person is standing in the room with me for a trigger. I'm not sure on how to do this, I just started messing with zmud triggers. The mud is setup with Title, Description, Exits, Items, Person/Affects, Person/Affects.. The normal mud, Thanks.
Reply with quote
Hazmeech
Novice


Joined: 27 Mar 2005
Posts: 31

PostPosted: Wed Mar 30, 2005 3:09 am   
 
On your mud you type a command to look in your room?
It's best if there is a command that just lists the people in the room so that you can capture their names.

You should give an exact example of what it looks like in the game when you look and have people in the room with you after you type a command to look.

Or do you want to capture names when you walk into a room?

It's not really clear what you want
Reply with quote
Sathrynn
Newbie


Joined: 30 Mar 2005
Posts: 3

PostPosted: Wed Mar 30, 2005 5:50 am   
 
Sorry, I say I want to have a trigger to spellup someone. Yet there's someone in the same room that has the trigger also. I want to be able to check the room for that person so we both don't waste our time doing the same thing to the person. I don't want to check if people are in the rooms I walk into, I just want to check the current room.

You type Look to see who's in the room in the mud and here's an example of the layout of a room:

The Great Hall
A large, almost oppressing wall of water shimmers beyond the crystal
doors to the east. Swirls of energy crackle within the water, somehow
keeping it at bay. A grand stone staircase spirals upwards into a second
level of the castle. A circular pool filled with a viscous, reflective
liquid has been built into the center of this hall.
[ Exits: n e s w u ]
A board of crackling energy floats above the surface of the pool.
Crescendo is hovering here.
...she is covered by a crackling field of energy!
...she is invisible to the unaided eye.
...her body is completely transparent.
Essah Mindrage is standing here.
...a blazing sheet of fire floats before her body!
...her body is completely transparent.
A lithe nymph swims in the pool, her long hair swirling about.
...she glows with a bright light!

Thanks again
Reply with quote
Hazmeech
Novice


Joined: 27 Mar 2005
Posts: 31

PostPosted: Wed Mar 30, 2005 5:19 pm   
 
Where it says "unwantedpersonsname" you would put the persons name
which IS case sensitive, and where it says "cast spell" you would put the action you want to do if the person is not present.
To activate the process type check

#CLASS {Unwanted}
#ALIAS check {
person = 0
#T+ looktrig
look
#ALARM +2 {#IF (!@person) {
Cast Spell
#T- looktrig
} {#ECHO @unwanted Is Present.}}
}
#VAR person {0} {0}
#VAR unwanted {UnwantedPersonsName}
#TRIGGER "looktrig" {{@unwanted}*is*here.$} {
Person = 1
#ALARM +2 {person = 0}
#T- looktrig
} "" {disable}
#CLASS 0
Reply with quote
Hazmeech
Novice


Joined: 27 Mar 2005
Posts: 31

PostPosted: Wed Mar 30, 2005 5:26 pm   
 
One thing though, this small script doesn't take lag into consideration so if the mud has a prompt I can make the script work more efficiently and it will not do anything if there is lag.
Reply with quote
Sathrynn
Newbie


Joined: 30 Mar 2005
Posts: 3

PostPosted: Wed Mar 30, 2005 7:15 pm   
 
This will work great, I can finish it from here. Thanks for all the help.
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