Re: [NEWBIE] load room

From: Jonathan Blackhawke (hawke@excalibur.net)
Date: 10/05/96


Well, we're doing better.  We're not ending up at the void any longer, but
it puts us back to default load locations.  Here is a little snip from
where the characters get loaded and it seems that the real_room(load_room)
function is failing as it appears to go to the r_(i)mortal_start_room. 
What can I pinpoint down to get this to properly load?  Any ideas?  Many
and most humble thanks.

      if ((load_room = GET_LOADROOM(d->character)) != NOWHERE)
	load_room = real_room(load_room);

      /* If char was saved with NOWHERE, or real_room above failed... */
      if (load_room == NOWHERE) {
	if (GET_LEVEL(d->character) >= LVL_IMMORT) {
	  load_room = r_immort_start_room;
	} else {
	  load_room = r_mortal_start_room;
	}
      }


----------
> > 
> > Change all of the save_char(ch, NOWHERE) calls to:
> >   save_char(ch, ch->in_room);
> > That should be it.
> > 
> 
> And then you got a major bug in your system :)
> 
> ch->in_room is the real number of the room, not the virtual number.
> So as soon you change your world, it will point on the wrong room..
> 
>   Change ch->in_room to world[ch->in_room].number  .. 
> 
> Can't say this would work totally [Haven't checked into this in loong
time
> :) ] But if someone save and quit, and then at once from the menu, go
back
> to the game, then I believe they could end up at default.. 
> 
> ---
> Erik Niese-Petersen
> Aka Quint The typo God
> Realms of Darkness IMP
> 
> 
> 
+-----------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
|   http://cspo.queensu.ca/~fletcher/Circle/list_faq.html   |
+-----------------------------------------------------------+



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