Game is crashing during test

Started by Sayhello-hello, Sat 20/03/2010 20:28:45

Previous topic - Next topic

Sayhello-hello

Hi,

it seems like my game is crashing when I try to run a test, although I'm not sure it's an actual crash because there's no error message, the game screen just goes black and there isn't anything I can do. Has anyone else had this problem and know how to solve this?

barefoot

#1
It might be waiting for something to happen before it loads, possibly an event... but is unable to do so. Maybe you have 'when room first loads' event instead of 'after room fades in' event???

If you post your code here someone maybe able to help further.

barefoot
I May Not Be Perfect but I Have A Big Heart ..

Sayhello-hello

I have used the "enters room before fade-in" event.

 function room_Load()
{
  if (cEgo.PreviousRoom == 26) {
    gIconbar.Visible = false;
cEgo.Say("Honey, I'm home!");
  cEgo.Walk(590, 223, eBlock);
  cEgo.Say("Honey?");
  cEgo.Walk(263, 438, eBlock);
  cEgo.Say("Hello?");
  cEgo.ChangeRoom(22);
  }
  else if (cEgo.PreviousRoom == 22) {
      gIconbar.Visible = true;
     }
}


So the first if-sentence is sort of a cutscene and leads to room 22, which is another kind of cutscene that then leads back to the room triggering the else/if sentence when the player is allowed to play.

monkey0506

Unless I'm mistaken, isn't the room_Load function the "before fade-in" event?

Crimson Wizard

Quote from: monkey_05_06 on Sat 20/03/2010 21:12:33
Unless I'm mistaken, isn't the room_Load function the "before fade-in" event?
What monkey means, everything in that function happen while screen is black (faded out) :)
You should change to function "after fade-in".

monkey0506

Actually yes, if I had properly read your post you explicitly said you were using the "before fade-in" event. If you think this through for just a moment here, you should be able to see the problem.. ::)

You're calling all these blocking Says and Walks before the screen fades in to show the new room. Change it to the "after fade-in" event and it should stop hanging up like that.

Sayhello-hello

Okay, I changed it and it worked! Thanks alot for the help. :)

SMF spam blocked by CleanTalk