On Thu, 27 Jul 1995, Ron Poulton wrote: > > I've been working on something like that too (just in my head so far). > > My plan is to write a simple parser for each file type (maybe just start > > by having it recognize room #'s and titles). Then write a world saver > > which would read the existing file as a long string. Edit what the > > editor supports (like the room titles), and save the string with your > > changes. > > > > In addition to giving you the backbone of olc, this kind of setup would > > give you instant functionality on a small scale, have room to grow, and > > it would just ignore any data types it doesn't recognize (though it would > > write them back out). > > I'm not sure what you mean by a long string. The parser routine is > already installed in CircleMUD as far as reading goes, however, as I > assume from the presence of write-routines in the editor sources I've > picked up, I assume CircleMUD doesn't have any routines to save world files. > > I patched a world-save routine with a few modifications into the rset > command, and now I can edit room titles and save the worlds flawlessly. > The next step is getting the description edited, then the flags and > doors. The routines themselves are in external files, ie: the "rset" > command is in rset.c, so it should technically be easy to patch it in > once 3.0gamma is released. And hopefully the two editing variations > should compliment each other. > What I meant about the long string is when you're ready to save the edited world, read the current world in as is (no parsing). Then make changes to the world as a string, and save it as a string (which is what it has to end up as anyway. The reason for doing it like this is so any nonstandard roomflags or other entries will be resaved. It's not a big deal, it's just that I noticed a lot of offline editors seem to save only what they can edit. For example, the editor(s) that will read a mob file with spec_procs, but won't write them back to the file. Sam
This archive was generated by hypermail 2b30 : 12/07/00 PST