Re: [CODE] Files

From: George (greerga@CIRCLEMUD.ORG)
Date: 12/04/97


On Thu, 4 Dec 1997, Drago's wrote:

>Ok, I was wondering how this file reading stuff works here!  I have greped
>around and can't find any occurance of *.wld in my game.  Where does this

fgrep wld *.[ch]
db.h:#define WLD_PREFIX "world/wld"     /* room definitions             */

fgrep -Cn WLD_PREFIX *.[ch]
db.c-446-  switch (mode) {
db.c-447-  case DB_BOOT_WLD:
db.c:448:    prefix = WLD_PREFIX;
db.c-449-    break;
db.c-450-  case DB_BOOT_MOB:

And you go from there....

>get asigned?  I found world[room_nr].description = fread_string(fl, buf2).
>I think this has something to do with it, but I'll be damned if I know what.

It reads the description.

>If someone could give me help with this whole file reading thing, I'd be

What do you think the parse_xxx functions do?

>much obliged.  My ulitimate goal is to set a file up called alt.des which is
>read much like a .wld file.  It would have to have formated input like

It would be easier to add a string field to the existing wld files.

--
George Greer  -  Me@Null.net   | Genius may have its limitations, but stupidity
http://www.van.ml.org/~greerga | is not thus handicapped. -- Elbert Hubbard


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST