Re: Delay skills

From: Glover, Rick I. (RIGLOVER@PHJW.com)
Date: 05/24/00


-----Original Message-----
From: Alex Mann [mailto:alex4501@HOTMAIL.COM]
Sent: Wednesday, May 24, 2000 12:49 PM
To: CIRCLE@post.queensu.ca
Subject: [CIRCLE] Delay skills


Hi I wanted to add

send_to_char("blah")
delay(100);
send_to_char("blah")

To make my skills and spells more interesting by giving the cast stages
which are time delayed.

However i put it into the code, and I get an implicite declaration error,
any one know, what the problem is, I'm not sure if i need to spcify a
specific .h file to make it work.

Any help Mucho Appriciated
Alex mann

-----Reply-----

Well, you can't put in delays like that in a MUD.  It is a Multi-User
Dungeon and has several people connected to it.  Even if you did get the
code working that you attempted in your post, you would have a single user
delaying the entire MUD every time they cast a spell.  The MUD is a
continuously flowing loop that accepts input from several sources and sends
output to several sources called descriptors.  If you put a gets() command
in your mud it would wait for one user to input some data which would make
the rest of the players wait.  Therefore, as the others on the list have
mentioned, you need an "event" system, where the mud will put up a flag that
that character is unable to type a command until the timer on that event is
over then allow them to continue, possibly along with a nice colorful
message.  You could do a version of this with WAIT_STATE in the stock code,
but it wouldn't be as nice as what you could create with DG Events or other
events code out there.

Good luck,
Rick


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     |  http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html  |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 04/10/01 PDT