Please login or register.

Login with username, password and session length
Advanced search  

News:

Forum rules - please read before posting, it can save you a lot of time.

Pages: [1] 2  All

Author Topic: The game crashes when changing to the specific scene  (Read 4839 times)

0 Members and 1 Guest are viewing this topic.

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
The game crashes when changing to the specific scene
« on: August 30, 2010, 02:14:55 PM »

Hi,
I have a weird problem.
The game crashes when I want the game to be changed to the scene B.
However, it occurs only if the game is changed to the specific scene B. If the game is changed to another scene, it works well.


The script that changes to the scene B is:
Code: [Select]
#include "scripts\base.inc"


on "LeftClick"{
actor.GoToObject(this);
if(Game.IsItemTaken("flaming torch")){
Game.ChangeScene("scenes\Obzorye_Island-Svitava_Complex-Underground_corridor\Obzorye_Island-Svitava_Complex-Underground_corridor.scene");
}
else{
actor.Talk("inventory-08-special-04");
}
}

The scene-init script of the scene B is:
Code: [Select]
#include "scripts\base.inc"

Game.Interactive = false;

if(Game.PrevScene == "Obzorye_Island-Svitava_Complex-Main_hall"){
actor.SkipTo(458, 762);
actor.Direction = DI_UP;
actor.Active = true;
actor.Talk("inventory-08-special-02");
}
else if(Game.DebugMode){
actor.SkipTo(516, 723);
actor.Direction = DI_DOWN;
actor.Active = true;
actor.Talk("The scene has been chosen as the startup scene in the debug mode...");
}


Game.Interactive = true;


Moreover, when I set the scene B as the debug startup scene, it works well too.


I'm really confused. I'll be very glad if anyone give me advice :)
Logged

maze

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 59
  • Good news
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #1 on: September 01, 2010, 09:17:59 AM »

Hi,

I can't see anything wrong. Have you looked up the "wme.log" file in your game directory? Maybe the information there helps you to track down the failure.

Cheers, maze
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 39
  • Offline Offline
  • Gender: Male
  • Posts: 5667
    • View Profile
    • Dead:Code Site
Re: The game crashes when changing to the specific scene
« Reply #2 on: September 01, 2010, 09:58:39 AM »

Can you isolate the crash in some minimal project so that I can test it?
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #3 on: September 01, 2010, 11:45:45 AM »

maze: The log is empty:-/ Nothing strange is written there respectively.

Mnemonic: When I go through the game in the normal (non-debug) mode, it works well. However, when I set the scene A as the debug startup scene and then I try to go to the scene B, it crashes. ???
Logged

odnorf

  • w00t?
  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 7
  • Offline Offline
  • Gender: Male
  • Posts: 1454
  • Lamp dog!
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #4 on: September 01, 2010, 12:16:58 PM »

Please do as Mnemonic said. Send him a minimal project that exhibits this behavior otherwise he can't test or reproduce it.
Logged
fl*p

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #5 on: September 01, 2010, 03:25:54 PM »

Well, I'll ask my teammates whether it'll mind them if I provide you a part of the game.
I don't know any reason why it should mind them but to be sure I'll ask them.
Then, if they don't mind, I'll provide you a test project :)
Logged

Prote1n

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 45
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #6 on: September 01, 2010, 03:57:03 PM »

I found a almost systematic crash on Game.changeScene on my side. Perhaps it is similar

In my first scene, I have a very simple Window that I use to display the text on the top of the screen. There is only one control : a static

When I quit this Scene for another Scene. I unload the window ( either manually with Game.UnLoad before Game.Change Scene, either on Scene.ShutDown).

The result is that works perfectly under Windows XP. But under Windows 7 64 bits, sometimes the Game.ChangeScene crashed but not systematically. After several tests I've discovered that I can remove the crash foreever just while adding a comment before Game.LoadWindow .....

 
Logged

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #7 on: September 02, 2010, 02:43:08 PM »

Well, I've asked my teammates and they've agreed. I could upload you the entire project but it'd be too uncomfortable for you to go through it.
So, I'll isolate the problem in a new project that will be as small as possible. Unfortunately, I'm quite busy today and tomorrow so, I should do it at the weekend :)
Logged

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #8 on: September 04, 2010, 09:09:40 AM »

I've sent Mnemonic a PM with a link to download the project. So, we'll see :)
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 39
  • Offline Offline
  • Gender: Male
  • Posts: 5667
    • View Profile
    • Dead:Code Site
Re: The game crashes when changing to the specific scene
« Reply #9 on: September 04, 2010, 09:21:42 AM »

Oh that's a rather silly bug. It's caused by the debug display ("Scene: xxx (prev: yyy)"). This debug line is limited to 100 characters and your scene names are too long...
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #10 on: September 04, 2010, 10:32:08 AM »

Oh :)
I thought it could be the reason of the problem but then I refused it because when I set the scene B as the debug startup scene, it was working...However, now I see why. Beucase the previous scene is an empty string then :)
« Last Edit: September 04, 2010, 01:03:34 PM by Mihulik »
Logged

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #11 on: November 23, 2010, 11:39:01 AM »

I'm sorry for awaking this old topic but I'm wondering whether there is a way around the problem.
For example recompiling the engine with longer debug line...I could rename my scenes but I really do not want to.:-)
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 39
  • Offline Offline
  • Gender: Male
  • Posts: 5667
    • View Profile
    • Dead:Code Site
Re: The game crashes when changing to the specific scene
« Reply #12 on: November 24, 2010, 07:57:14 AM »

Yes, it needs to be recompiled. Can't think of any workaround other than renaming the scenes.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

Mihulik

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 71
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #13 on: November 24, 2010, 11:02:53 AM »

So, if I ask you for the sources because of changing that, will it by possible?:)
Logged

odnorf

  • w00t?
  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 7
  • Offline Offline
  • Gender: Male
  • Posts: 1454
  • Lamp dog!
    • View Profile
Re: The game crashes when changing to the specific scene
« Reply #14 on: November 24, 2010, 11:35:01 AM »

Sources are available to all under LGPL3. Please read the license before you redistribute your own compile.
Logged
fl*p
Pages: [1] 2  All
 

Page created in 0.248 seconds with 17 queries.