Re: NEWBIE-INTERMEDIATE//To Harvey Gilpin

From: Harvey Gilpin (rv@twylite.demon.co.uk)
Date: 05/16/96


Adam Days <g98s12@oemsunix.onysd.wednet.edu> wrote:

>you know like instead of
>
>100 0 450
>A
>13 19
>
>it wants
>
>100 0 450
>15
>A
>13 19

Well, if you want to use it with the commented out code in Oasis,
you'll need to find the line that Oasis saves it on.

So instead of having:

100 0 45
A

You have:

100 0 45 2000
A

Where 2000 is the new level flag (how many levels!?!)
Check out the oedit_save_to_disk() function to find which line this
is.  Then, crank up yer editor and hack into db.c.  Find where it
loads this line.  It'll look _something_ similar to this:

---8<---
  if (fread_line("%d %d %d", t[0], t[1], t[2]) != 3))
  { // Error handling
  }
  Blah = t[0];
---8<---


Change it to:

---8<---
  t[3] = 0;   // Default value
  if (fread_line("%d %d %d %d", t[0], t[1], t[2], t[3]) < 3))
  { // Error handling (now expecting 3 or more fields)
  }

  Blah = t[0];
  GET_LEVEL(obj) = t[3];
---8<---


That should do the trick.  Sorry this is a little vague, but I'm sure
you can figure out what I mean, and I'm too tired to reboot into Linux
and look up all the details...

Cheers,


Rv.



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