1997Q2/
<!-- MHonArc v2.4.4 -->
<!--X-Subject: Re: Event&#45;driven? -->
<!--X-From-R13: Oqnz Ivttvaf <avtugsnyyNhfre1.vasvpnq.pbz> -->
<!--X-Date: from tacitus.globecomm.net [207.51.48.7] by mx5.ibm.net id 860124870.74792&#45;1 Fri Apr  4 03:34:30 1997 -->
<!--X-Message-Id: 199704040347.UAA20824#user1,inficad.com -->
<!--X-Content-Type: text/plain -->
<!--X-Reference: 199704040122.BAA613821#out2,ibm.net -->
<!--X-Head-End-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<html>
<head>
<title>MUD-Dev message, Re: Event-driven?</title>
<!-- meta name="robots" content="noindex,nofollow" -->
<link rev="made" href="mailto:nightfall#user1,inficad.com">
</head>
<body background="/backgrounds/paperback.gif" bgcolor="#ffffff"
      text="#000000" link="#0000FF" alink="#FF0000" vlink="#006000">

  <font size="+4" color="#804040">
    <strong><em>MUD-Dev<br>mailing list archive</em></strong>
  </font>
      
<br>
[&nbsp;<a href="../">Other Periods</a>
&nbsp;|&nbsp;<a href="../../">Other mailing lists</a>
&nbsp;|&nbsp;<a href="/search.php3">Search</a>
&nbsp;]
<br clear=all><hr>
<!--X-Body-Begin-->
<!--X-User-Header-->
<!--X-User-Header-End-->
<!--X-TopPNI-->

Date:&nbsp;
[&nbsp;<a href="msg00009.html">Previous</a>
&nbsp;|&nbsp;<a href="msg00011.html">Next</a>
&nbsp;]
&nbsp;&nbsp;&nbsp;&nbsp;
Thread:&nbsp;
[&nbsp;<a href="msg00008.html">Previous</a>
&nbsp;|&nbsp;<a href="msg00011.html">Next</a>
&nbsp;]
&nbsp;&nbsp;&nbsp;&nbsp;
Index:&nbsp;
[&nbsp;<A HREF="author.html#00010">Author</A>
&nbsp;|&nbsp;<A HREF="#00010">Date</A>
&nbsp;|&nbsp;<A HREF="thread.html#00010">Thread</A>
&nbsp;]

<!--X-TopPNI-End-->
<!--X-MsgBody-->
<!--X-Subject-Header-Begin-->
<H1>Re: Event-driven?</H1>
<HR>
<!--X-Subject-Header-End-->
<!--X-Head-of-Message-->
<UL>
<LI><em>To</em>: <A HREF="mailto:mud-dev#null,net">mud-dev#null,net</A></LI>
<LI><em>Subject</em>: Re: Event-driven?</LI>
<LI><em>From</em>: Adam Wiggins &lt;<A HREF="mailto:nightfall#user1,inficad.com">nightfall#user1,inficad.com</A>&gt;</LI>
<LI><em>Date</em>: Thu, 3 Apr 1997 20:47:19 -0700 (MST)</LI>
</UL>
<!--X-Head-of-Message-End-->
<!--X-Head-Body-Sep-Begin-->
<HR>
<!--X-Head-Body-Sep-End-->
<!--X-Body-of-Message-->
<PRE>
&gt; Precisely how does an event-driven mud work?  I understand the idea, but 
&gt; I don't see how it could be run efficiently, and be coded neatly...
&gt; Can somebody enlighten me?

That's quite a question.  In a nutshell, it works like any other event
driven system - it only does something when it 'needs to'.  In order
to define 'needs to', however, you need very good flow of information and
control.  In other words, it's more difficult to both conceptualize and code,
and there's a lot more potential for things to go wrong.  But if you can
pull it off, you get what is essentially an optimal system - if nothing
is happening, then almost no processor time is being used; if many, many
things are happening then processor usage goes up to match this.  Versus
brute-force (polling/looping) which is fairly static - even if there's
no on online, it's still sucking down a fair amount of CPU time.
A simple and highly applicable example for this is strength versus
weapon wielded.  On a tick-oriented mud, where it updates everything
on a tick (typically 35 to 75 seconds long), if someone casts weaken
on your character or otherwise affects their strength in such a way that
they are no longer strong enough to wield their weapon, the weapon won't
fall out of their hand until the polling loop (tick) makes its scan of
all the characters and updates stuff like this.  Versus event driven, where
the weaken spell triggers a strength update event, which triggers a check-to
see-if-I-can-wield-my-weapon event.
Even driven is also much nicer once coded, because it's easy to just toss
an event on the queue and 'forget' about it.  When the given even goes
off (which could be hours or even days later), the appropriate handler will
be called.

</PRE>

<!--X-Body-of-Message-End-->
<!--X-MsgBody-End-->
<!--X-Follow-Ups-->
<HR>
<!--X-Follow-Ups-End-->
<!--X-References-->
<!--X-References-End-->
<!--X-BotPNI-->
<UL>
<LI>Prev by Date:
<STRONG><A HREF="msg00009.html">No Subject</A></STRONG>
</LI>
<LI>Next by Date:
<STRONG><A HREF="msg00011.html">Re: Event-driven?</A></STRONG>
</LI>
<LI>Prev by thread:
<STRONG><A HREF="msg00008.html">Event-driven?</A></STRONG>
</LI>
<LI>Next by thread:
<STRONG><A HREF="msg00011.html">Re: Event-driven?</A></STRONG>
</LI>
<LI>Index(es):
<UL>
<LI><A HREF="index.html#00010"><STRONG>Date</STRONG></A></LI>
<LI><A HREF="thread.html#00010"><STRONG>Thread</STRONG></A></LI>
</UL>
</LI>
</UL>

<!--X-BotPNI-End-->
<!--X-User-Footer-->
<!--X-User-Footer-End-->
<ul><li>Thread context:
<BLOCKQUOTE><UL>
<LI><strong><A NAME="00013" HREF="msg00013.html">A late introduction</A></strong>, 
Jon A. Lambert <a href="mailto:jlsysinc#ix,netcom.com">jlsysinc#ix,netcom.com</a>, Fri 04 Apr 1997, 15:18 GMT
<LI><strong><A NAME="00009" HREF="msg00009.html">No Subject</A></strong>, 
Dan Mazeau <a href="mailto:dmazeau#wco,com">dmazeau#wco,com</a>, Fri 04 Apr 1997, 09:03 GMT
<UL>
<li>&lt;Possible follow-up(s)&gt;<br>
<LI><strong><A NAME="01426" HREF="msg01426.html">No Subject</A></strong>, 
mud-dev <a href="mailto:mud-dev#null,net">mud-dev#null,net</a>, Mon 23 Jun 1997, 01:09 GMT
</LI>
</UL>
</LI>
<LI><strong><A NAME="00008" HREF="msg00008.html">Event-driven?</A></strong>, 
Michael Hohensee <a href="mailto:michael#sparta,mainstream.net">michael#sparta,mainstream.net</a>, Fri 04 Apr 1997, 04:49 GMT
<UL>
<li>&lt;Possible follow-up(s)&gt;<br>
<LI><strong><A NAME="00010" HREF="msg00010.html">Re: Event-driven?</A></strong>, 
Adam Wiggins <a href="mailto:nightfall#user1,inficad.com">nightfall#user1,inficad.com</a>, Fri 04 Apr 1997, 11:34 GMT
</LI>
<LI><strong><A NAME="00011" HREF="msg00011.html">Re: Event-driven?</A></strong>, 
Nathan Yospe <a href="mailto:yospe#hawaii,edu">yospe#hawaii,edu</a>, Fri 04 Apr 1997, 12:23 GMT
</LI>
<LI><strong><A NAME="00015" HREF="msg00015.html">Re: Event-driven?</A></strong>, 
Shawn Halpenny <a href="mailto:rsh#dos,nortel.com">rsh#dos,nortel.com</a>, Fri 04 Apr 1997, 23:05 GMT
</LI>
<LI><strong><A NAME="00019" HREF="msg00019.html">Re: Event-driven?</A></strong>, 
Chris Gray <a href="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA">cg#ami-cg,GraySage.Edmonton.AB.CA</a>, Sun 06 Apr 1997, 02:14 GMT
</LI>
<LI><strong><A NAME="00028" HREF="msg00028.html">Re: Event-driven?</A></strong>, 
coder <a href="mailto:coder#ibm,net">coder#ibm,net</a>, Mon 07 Apr 1997, 01:05 GMT
</LI>
</UL>
</LI>
</UL></BLOCKQUOTE>

</ul>
<hr>
<center>
[&nbsp;<a href="../">Other Periods</a>
&nbsp;|&nbsp;<a href="../../">Other mailing lists</a>
&nbsp;|&nbsp;<a href="/search.php3">Search</a>
&nbsp;]
</center>
<hr>
</body>
</html>