On Sun, Jul 01, 2001 at 01:51:17PM +0900, Jarratt Davis came up with this idea: > Hi folks, I'm currently debating how far I will want to go with replacing > library loading, player saving and loading etc. with a database engine. Putting the finishing touches on the bulk of it tonight. (A few things I'm not sure I want to move there, just because of how dynamic the info is.) > 1) Did you completely replace the in-memory linked lists as well the the > data saved to or loaded from disk, (which would make more sense to me) or > did you just use it to replace the ascii/binary save/load systems? No, they're still stored in memory. Just ripped out/apart as many of the load/save portions as I felt were static enough to make a database method feasable. > 2) If your answer was 'yes', how much of an effect did it have on the speed > of your MUD? Slowed a few things down at first. Threading the slower calls at the moment (That's what I'm recompiling as I type this. That being done, it's equally as fast. I'll gprof it after I'm sure it's stable; I'm not overly thrilled with HOW I'm threading it at the moment. > 3) Again if your answer was 'yes', how exactly did you structure it. For > example would you have the item/NPC/Shop/Room databases only used as > read-only (templates for each particular area within the MUD), and have a > game session database that kept track of changes happening while people > played - which doesn't make a lot of sense to me. Obviously for players it > doesnt matter so much so the in-game database and the saved information > database can be the same database ie. all changes that happen to a player > while playing can happen to their information saved in the player database... No, and I don't particularly see the reason for it (at least as you described here, lack of sleep and too much code might be messing something up here) Right now, I'm keeping plr_index, playerfiles[1], objects[2], rooms[2], shops, and helpfiles happily there. Only the playerfiles have any redundancy yet. So far, the plr_index was corrupted once and 3 player files were trashed. All the information was just fine in the database. So to me it's worth it. My implementation of it is going to probably be redone from the ground up once I've got it completely finished, as my MySQL skills aren't exactly, umm... shall we say "sharp". [1] Except for the skills practiced. [2] Except for extra descriptions. -mike -- +---------------------------------------------------------------+ | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html | +---------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/06/01 PST