[Reality] Markov/Probability tables added

Ben Sunshine-Hill sneftel@popmail.com
Sun, 26 Dec 1999 02:33:22 GMT


> Cool.  Do you think you want to do weather too? =) ::subtly attempts to
> avoid responsability...::

Actually, I had put the finishing touches on the weather system on my game about 15 minutes before I read the Markov tables announcement. (Moral: I should've procrastinated.) While the system I developed is probably pretty singular to my game ("raining", "wet", and "dry"), I think one of the first ways I'll play with Markovs is to redo the weather. What I'm really interested in is criticism over my system for distribting the weather.

In my game, there is a special room, called "Outside". All rooms that are outside are actually <I>things in that room</I>. While this is probably a pretty evil bit of hackery on my part, it hasn't caused any problems yet (except when I accidentally put "Outside" in itself...bad craziness). All outside rooms also extend Class_Outside, which is not itself in Outside. Class_Outside has handlers called "UpdateDescHandler" tied to event "motif". Outside contains the code for the weather as a self-propagating handler. If and when it changes the weather, it updates a string "weather" in Outside and broadcasts the "motif" event (i.e. to all the outside rooms). UpdateDescHandler then fetches "weather" from Outside, and adds a descriptor from its own string "weather xxx" to the room, where xxx is the contents of the "weather" string. (actually a bit more complex than that, but that's irrelevant.) Class_Outside has default descriptors, so that I don't have to manually describe every comb!
ination of time and weather for every room.

So (for those of you who are still awake and with me), what do you find wrong with this system? Are any of my techniques going to bite me in the arse later on?

Ben Sunshine-Hill

P.S. Merry Christmas, everyone!