re: online editor

On Mon, 24 Jul 1995, Ron Poulton wrote:
> I grabbed that editor (assuming it was circ-old.tar.gz that you sent) and
> installed it without any [apparent ;] bugs. I decided to edit room #3059
> since it was relatively sparse. The editor definitely has potential;
> something I would be interested in installing would be a 'maximum
> specification', such that "max" would use the topmost room/object/etc,
> "new" would create a new room/object/etc, and so forth.
On the subject of bugs, I found two rather major glitches in the
olc stuff (one of them 5 minutes after I ftp'ed the code - sigh).
The first one, is that string_add in modify.c adds \r's at the end of each
line. After a couple of reboots the world/obj files start to have ^M's all
over the place.. I changed the lines in string_add to:
} else {
/* the \r screws up OLC */
if (STATE(d) == CON_IEDIT || STATE(d) == CON_REDIT)
strcat(*d->str, "\n");
else
strcat(*d->str, "\r\n");
}
}
The second one occurs when you try to redit a room with vnum > than
everything else (say room 99999).. it doesn't ever save to memory.
Here is a patch to fix that:
*** /std/people/fong/test/redit.c Sun Jul 23 14:05:57 1995
--- redit.c Tue Jul 25 10:40:42 1995
***************
*** 444,449 ****
--- 444,458 ----
new_world[counter + 1] = world[counter];
}
}
+ /* we need this here because if room was > than all the other rooms,
+ need to insert at end */
+ if (!found) {
+ new_world[top_of_world + 1] = *(d->edit_room);
+ new_world[top_of_world + 1].number = d->edit_number;
+ new_world[top_of_world + 1].func = NULL;
+ found = 1;
+ }
+
top_of_world++;
/* copy world table over */
free(world);
As for the maximum specification, I'm not too sure what you mean. If you want
to be able to just do "redit max" and get the unfinished room which is 1
higher than the max finished room in the zone, that could be easily added
to olc.c.. as for "redit new", the existing redit will create a new room
if you specify a vnum that doesn't already exist.
Regards,
Levork