Re: [code][newbie] Echoing to a room via spec_proc

From: Daniel Koepke (
Date: 01/26/97

On Sun, 26 Jan 1997, John Evans wrote:

> 	I am trying to get a random string to echo to a certain room via a special 
> procedure for that room.  Here is a shorter version of what I have:
>         act("The squeaking of rats can be heard echoing through the sewers.",
>             TRUE, ch, 0, 0, TO_ROOM);
> This method works great for mobs, but not for rooms. :(
> This snippet of code will compile and won't crash the mud, but it just won't do 
> anything, and I've sat in the room for a good 10 minutes waiting for SOMETHING 
> to happen. :)
> I didn't think that it would work, but it was all that I could think of. 
> Perhaps, if I went to bed and came back to it, I'd think of a different way of 
> doing it. :)

Perhaps I'm wrong here, but your problem might be that you don't have
a 'ch' when someone doesn't directly initiate the special procedure.
There's two things that come to me.  This seems like it'll be forced
to do something whenever a person types a command in the room because
it lacks a 'if (cmd) return FALSE;'.  Secondly, your act() calls should
be something like:

  act("Whatever", FALSE, 0, 0, 0, TO_ROOM);

Now, I wouldn't suggest using any of the act codes in that, as it
would (quite obviously) cause problems, since you aren't passing any
pointers for act() to use to replace the codes.

I think the latter part is why the act()'s aren't working.  The former
might be worthless precautions or disillusionment upon my part.

Daniel Koepke
Forgive me father, for I am sin.

| Ensure that you have read the CircleMUD Mailing List FAQ: |
|   |

This archive was generated by hypermail 2b30 : 12/18/00 PST