MOO-cows Mailing List Archive


Re: Making a chat room

On Fri, 29 Sep 1995, Rich Connamacher wrote:

> As I said before, the only real difference between these two approaches 
> is that room:* would be used if the command cant be found on the player, 
> and room:huh would be used if the command can't be found anywhere: the 
> player, the room, or any other objects that may have the verb in 
> question.  I'm not sure if this'll override other verbs on itself as 
> well.. ie if you type 'say hey there', and there's both a 'say' and a '*' 
> verb on the room, I'm not sure which one it'll run.

The parser always checks the objects' own verbs before heading to the 
parent. Thus, having a *-verb on a room will mean _no_ roomverbs what so 
ever, except you define them before defineing the *-verb. (the parser 
goes from verb 0 till verb(length(verbs(object)) :)
That is a bad idea, by the way, because it would block out a few of many 
important verbs: look, @eject, emote. And if you put it +x, for whatever 
reason, it would also block out acceptable, enterfunc, look_self, etc. 
*-verbs are never a good idea, unless you _want_ those wicked things to 
happen :)

If you make a :huh verb, which is by far the smartest way, you have to 
remember to put it +x, and probbably this none this. I think any any any 
works too, but it might break with other verbs. The only drawback AFAIS 
of using :huh is the fact that typing a verb with the proper arguments 
will activate the verb, not the :huh. For instance, if i was to say 'say 
what ?' in a room like that, everyone would see: Ynnoz says, "what?". And 
if i was to say 'Bash thorin with club !!' and i would have a club in my 
vicinity with a verb 'bash (any with this)' or a thorin in my vicinity 
with a verb 'bash this with any' i would activate that verb, and _not_ 
the :huh. Note that a verb on yourself, 'bash any with any' would work 
also if you use a *-verb on the room.

A way to really rule out any verb calls _at_ _all_ is to store away all
verbs on a player, and give him a * verb himself. He won't be able to do
_anything_ except talk.  Or, alternatively, and a nicer way, you could put
a while((text=read(>person<))!="QUIT");<do what you want with the
text>;endwhile loop on every player entering the room. Note you must be 
wizard or player==task_perms(), and not suspended since initial verb call 
(note there is a way around this, a hard way but usable, using 
open_network_connection to the MOO itself, and connecting to a dummy object)

This last part is more for the experienced and the daring tho :)


Thomas Wouters   |   Visit The Digitale City (DDS)   | Forever an Addict to |    The Dutch Digital Community    | Virtual, Digital,
Ynnoz @ MOOs     | | Unconventional Rubbish
Jay_* @ MUS[HE]s |  WWW -- World Wide Wackos :)      | (Except for Windows)

Follow-Ups: References:

Home | Subject Index | Thread Index