[Home] [Groups] - Message: [Prev in Group] [Next in Group]
10882: [MUD-Dev] dispatching events
[Full Header] [Plain Text]
From: Greg Miller <gmiller@classic-games.com>
Newsgroups: nu.kanga.list.mud-dev
Date: Thu, 22 Jul 1999 01:02:23 -0500
Organization: Kanga.Nu
I'm working on a lockless C&C game driver at the moment, and I'm
wondering how others handle the dispatching of events. I see three
approaches:
[1] Calling object/function pairs by name. This is simple, but it seems
rather less flexible than other approaches.
[2] Subscriptions. In this case I'm referring to events that trigger
calls to all subscribers as a single atomic unit. More flexible, but I
can easily envision situations where events have to be restarted
repeatedly if there are many subscribers.
[3] A combination of the two, using two stage events, where the first
stage generates a list of pending object/function pair calls. This would
allow each call to be handled atomically, but is far more complex.
I'm experimenting with #3 right now--anyone got any comments on the
subject?
--
http://www.classic-games.com/
Conspiracy theorists mistakenly assume others think before acting.
*** Please limit .sigs to four lines and avoid HTML mail or posts. ***
_______________________________________________
MUD-Dev maillist - MUD-Dev@kanga.nu
http://www.kanga.nu/lists/listinfo/mud-dev