1998Q1/
<!-- MHonArc v2.4.4 -->
<!--X-Subject: Re: [MUD&#45;Dev] DBs and Events -->
<!--X-From-R13: @nguna Kbfcr <lbfcrNunjnvv.rqh> -->
<!--X-Date: Wed, 11 Feb 1998 19:10:26 +0000 -->
<!--X-Message-Id: Pine.GSO.3.95q.980211083504.13903A&#45;100000@uhunix1 -->
<!--X-Content-Type: text/plain -->
<!--X-Reference: Pine.LNX.3.91.980210211015.65K&#45;100000@uni&#45;corn.demon.co.uk -->
<!--X-Head-End-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<html>
<head>
<title>MUD-Dev message, Re: [MUD-Dev] DBs and Events</title>
<!-- meta name="robots" content="noindex,nofollow" -->
<link rev="made" href="mailto:yospe#hawaii,edu">
</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="msg00401.html">Previous</a>
&nbsp;|&nbsp;<a href="msg00403.html">Next</a>
&nbsp;]
&nbsp;&nbsp;&nbsp;&nbsp;
Thread:&nbsp;
[&nbsp;<a href="msg00526.html">Previous</a>
&nbsp;|&nbsp;<a href="msg00436.html">Next</a>
&nbsp;]
&nbsp;&nbsp;&nbsp;&nbsp;
Index:&nbsp;
[&nbsp;<A HREF="author.html#00402">Author</A>
&nbsp;|&nbsp;<A HREF="#00402">Date</A>
&nbsp;|&nbsp;<A HREF="thread.html#00402">Thread</A>
&nbsp;]

<!--X-TopPNI-End-->
<!--X-MsgBody-->
<!--X-Subject-Header-Begin-->
<H1>Re: [MUD-Dev] DBs and Events</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: [MUD-Dev] DBs and Events</LI>
<LI><em>From</em>: Nathan Yospe &lt;<A HREF="mailto:yospe#hawaii,edu">yospe#hawaii,edu</A>&gt;</LI>
<LI><em>Date</em>: Wed, 11 Feb 1998 09:08:08 -1000</LI>
</UL>
<!--X-Head-of-Message-End-->
<!--X-Head-Body-Sep-Begin-->
<HR>
<!--X-Head-Body-Sep-End-->
<!--X-Body-of-Message-->
<PRE>
On Tue, 10 Feb 1998, Greg Munt wrote:

:On Tue, 10 Feb 1998, Nathan Yospe wrote:

:&gt; On Tue, 10 Feb 1998, Greg Munt wrote:

:&gt; :Also, any references to caches?

:&gt; Again, can't help you. I've done caches, but not for my mud... and there
:&gt; is such a broad spectrum of things that qualify as cache. Do you want to
:&gt; know more about cached in-memory storage for a disk-based DB? 

:Yes.

The best sources for this would be J C, any of the Cold people, or, if a
member of the DGD development team is still around... was that the LPmud
disk-based project? All I can tell you is, you don't want to be doing it
in the form of frequent access to the disk, so if you can find a way for
the data to reside in memory for a while after any read, and for data to
be held for writing until a significant chunk of contiguous memory is in
the cache, you're better off. Hopefully others can advise better than I.

:&gt; Or bottleneck spot caching?

:What's that?

An element of assembly coding and RISC compiler design. It might also be
significant for VM construction. It has to do with the repeated register
loading of the same data over and over. Essentially means finding where,
when, and how information can be loaded onto the stack/into registers to
minimize the number of loads (This opposed to operational instructions.)

:&gt; :Any references to Event Management? Is there any alternative to using a 
:&gt; :pointer to a function, to store the Event-&gt;function()? (This has the 
:&gt; :disadvantage of every Event-&gt;function() needing to have the same number 
:&gt; :and type of parameters being passed to it.)

:&gt; Here we go. This I can help you with. Events don't have to be functions,
:&gt; for a start. An event could be stored as anything, from a script on down
:&gt; to a held thread. I store mine as classes... any action is executed from
:&gt; an event class, which grabs the nearest available execution thread, sets
:&gt; it to the event's references, and frees it to go. Events are, by design,
:&gt; only actually capable of grabbing one specific thread, such that any set
:&gt; of events cannot execute asynchronously on the same resources. Functions
:&gt; are actually pulled up _after_ execution begins... Event.Process() is at
:&gt; its basis a normalization check, which tries to match a list of objects,
:&gt; and upon success, changes the values of the objects to a new norm, then,
:&gt; with its still-active thread, allows those objects to update. The object
:&gt; update methods are the actual functions involved, and once each object's
:&gt; updates are complete (and affected objects with zero delay complete such
:&gt; updates as the modified objects have made available) the thread is wiped
:&gt; clear of variables, set to sleep, and returned to the pool. 

:I'm not sure I understand this too well. Are you suggesting this?

:class Event
:  {
:     private:
:       DataType1 *a;
:       DataType2 *b;
:       ...
:
:     public:
:       ...
:       process();
:  };

class Event{
  SortedList&lt;ObjectReference&lt;BaseObject&gt;, PrioriList&lt;AttributeType,
      AttributeValue&gt; &gt; objectList;
  TimeValue  timeCheck; // for purpose of sanity checks
public:
  process(); // set values... for each object in objectList, call
             // BaseObject::update();
};

:I still can't see how the event isn't a function. The tasks that the 
:event does have to be stored in a function?

Well, yes and no. I operate entirely on the principal of creation, value
modification, full instantiation, partial destantiation, and deletion. I
don't tolerate the sort of procedural functions that most languages use.

:Am I wrong in thinking that the data that an Event needs (eg pointer to a 
:Player) are stored in the class, with a function - which takes no 
:parameters - calling class methods to do whatever it is that the Event is 
:trying to achieve? Also, it looks like Event would need to be a template. 
:Forget that, am using Linux g++ :(

I'm using g++ too... so far, the templates haven't bit me. Not Linux, if
that makes a difference, but still. I know that some of the advanced and
esoteric template functionalities, g++ won't work. Nevertheless, there's
no reason I couldn't have done without, aside from my pointer and Lists.

:I feel like I have totally gotten the wrong end of the stick here... 

Nah. You'll learn. Give it some time. Use Java for a while, if you want.
It is crippled, but you learn a lot from programming with it. Seriously.

:&gt; This is just
:&gt; one approach to events that doesn't actually require a function pointer,
:&gt; and a good number of others can be found in deja news archives of thread
:&gt; and event related newsgroups.

:Could you lead me in the right direction here? Searches on dejanews 
:revealed not very much (read: nothing)...

Can't remember the ngs right now myself, but... I'll take a look Friday.
Got work and school until then, so I'll be a bit too busy. Can you hold?

:&gt; Nathan F. Yospe - Aimed High, Crashed Hard, In the Hanger, Back Flying Soon
:&gt; Jr Software Engineer, Textron Systems Division (On loan to Rocketdyne Tech)
:&gt; (Temporarily on Hold) Physics student, University of Hawaii dept of Physics
:&gt; yospe#hawaii,edu nyospe#premeir,mhpcc.af.mil <A  HREF="http://www2.hawaii.edu/~yospe/">http://www2.hawaii.edu/~yospe/</A>

:I'll use this opportunity to keep you updated on my work activities: I 
:finally got a job, C++/Unix, using such tools as Rational Rose, etc. I'll 
:be maintaining and developing planning and scheduling software for the 
:steel industry. Will post a FAQ update soon.

Congratulations. Rational Rose, eh? I have misery in my company. I mean,
company in my misery. No the first time was right. We use Rose too. Dang
piece of ill concieved code. Powerful, though. But... how can a tool for
object oriented design be so... inconsistant? It seems to have spaghetti
for innards, and the user interface changes from one tool to the next so
radically that the keys for _copy_ and _paste_ are never the same, and I
don't even want to go into the deletion and selection procedures. Bleah!

:I'm free of Cobol now! Hurrah!

That must be a relief. Congratulations again, and here's hoping it stays
good. BTW, sounds similar to myself, except mine was Fortran. C++ RULES!

-- 

Nathan F. Yospe - Aimed High, Crashed Hard, In the Hanger, Back Flying Soon
Jr Software Engineer, Textron Systems Division (On loan to Rocketdyne Tech)
(Temporarily on Hold) Physics student, University of Hawaii dept of Physics
yospe#hawaii,edu nyospe#premeir,mhpcc.af.mil <A  HREF="http://www2.hawaii.edu/~yospe/">http://www2.hawaii.edu/~yospe/</A>



</PRE>

<!--X-Body-of-Message-End-->
<!--X-MsgBody-End-->
<!--X-Follow-Ups-->
<HR>
<ul compact><li><strong>Follow-Ups</strong>:
<ul>
<li><strong><A NAME="00436" HREF="msg00436.html">Re: [MUD-Dev] DBs and Events</A></strong>
<ul compact><li><em>From:</em> "Jon A. Lambert" &lt;jlsysinc#ix,netcom.com&gt;</li></ul>
</UL></LI></UL>
<!--X-Follow-Ups-End-->
<!--X-References-->
<UL><LI><STRONG>References</STRONG>:
<UL>
<LI><STRONG><A NAME="00399" HREF="msg00399.html">Re: [MUD-Dev] DBs and Events</A></STRONG>
<UL><LI><EM>From:</EM> Greg Munt &lt;greg#uni-corn,demon.co.uk&gt;</LI></UL></LI>
</UL></LI></UL>
<!--X-References-End-->
<!--X-BotPNI-->
<UL>
<LI>Prev by Date:
<STRONG><A HREF="msg00401.html">META: Unsubscribed users dur to bounces</A></STRONG>
</LI>
<LI>Next by Date:
<STRONG><A HREF="msg00403.html">Re: [MUD-Dev]  Clients</A></STRONG>
</LI>
<LI>Prev by thread:
<STRONG><A HREF="msg00526.html">Re: [MUD-Dev]  OT: Linux g++</A></STRONG>
</LI>
<LI>Next by thread:
<STRONG><A HREF="msg00436.html">Re: [MUD-Dev] DBs and Events</A></STRONG>
</LI>
<LI>Index(es):
<UL>
<LI><A HREF="index.html#00402"><STRONG>Date</STRONG></A></LI>
<LI><A HREF="thread.html#00402"><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>OT: Linux g++</STRONG>, <EM>(continued)</EM>
<ul compact>
<ul compact>
<ul compact>
<ul compact>
<LI><strong><A NAME="00432" HREF="msg00432.html">OT: Linux g++</A></strong>, 
Greg Munt <a href="mailto:greg#uni-corn,demon.co.uk">greg#uni-corn,demon.co.uk</a>, Thu 12 Feb 1998, 11:52 GMT
<UL>
<LI><strong><A NAME="00444" HREF="msg00444.html">Re: [MUD-Dev]  OT: Linux g++</A></strong>, 
Ben Greear <a href="mailto:greear#cyberhighway,net">greear#cyberhighway,net</a>, Fri 13 Feb 1998, 00:30 GMT
<UL>
<LI><strong><A NAME="00487" HREF="msg00487.html">Re: [MUD-Dev]  OT: Linux g++</A></strong>, 
coder <a href="mailto:coder#ibm,net">coder#ibm,net</a>, Mon 16 Feb 1998, 11:29 GMT
<UL>
<LI><strong><A NAME="00526" HREF="msg00526.html">Re: [MUD-Dev]  OT: Linux g++</A></strong>, 
Shawn Halpenny <a href="mailto:malachai#iname,com">malachai#iname,com</a>, Wed 18 Feb 1998, 17:02 GMT
</LI>
</UL>
</LI>
</UL>
</LI>
</UL>
</LI>
</ul>
<LI><strong><A NAME="00402" HREF="msg00402.html">Re: [MUD-Dev] DBs and Events</A></strong>, 
Nathan Yospe <a href="mailto:yospe#hawaii,edu">yospe#hawaii,edu</a>, Wed 11 Feb 1998, 19:10 GMT
<UL>
<LI><strong><A NAME="00436" HREF="msg00436.html">Re: [MUD-Dev] DBs and Events</A></strong>, 
Jon A. Lambert <a href="mailto:jlsysinc#ix,netcom.com">jlsysinc#ix,netcom.com</a>, Thu 12 Feb 1998, 17:45 GMT
<UL>
<LI><strong><A NAME="00472" HREF="msg00472.html">Re: [MUD-Dev] DBs and Events</A></strong>, 
coder <a href="mailto:coder#ibm,net">coder#ibm,net</a>, Mon 16 Feb 1998, 02:47 GMT
<UL>
<LI><strong><A NAME="00500" HREF="msg00500.html">Re: [MUD-Dev] Version Control (was: DBs and Events)</A></strong>, 
Vadim Tkachenko <a href="mailto:vadimt#4cs,com">vadimt#4cs,com</a>, Mon 16 Feb 1998, 23:30 GMT
<UL>
<LI><strong><A NAME="00524" HREF="msg00524.html">Re: [MUD-Dev] Version Control (was: DBs and Events)</A></strong>, 
coder <a href="mailto:coder#ibm,net">coder#ibm,net</a>, Wed 18 Feb 1998, 10:34 GMT
</LI>
</UL>
</LI>
</UL>
</LI>
</UL>
</LI>
</UL>
</LI>
</ul>
</ul>
</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>