GameSalad

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

My game freeze on 1.25

Hi Everyone

I am quite new to the gamesalad community.
I just purchased gamesalad, and testing my old game project from 6 month ago.
The game was working perfectly on device with the last version 1.24.

with 1.25 the game freeze on device (ipad and android) when I change certain scenes. The scene load, with sounds and particles, grafics, but no animations or game mechanic...
For exemple I open level 1 it work, go to level 2 it work
I open level 1 it work, go to the level selection menu it work, go to level 2 it FREEZE
Sometime when I win the level the win menu appear and it freeze as well...
I never had those problems with 1.24.
Also On my PC the game work without any problems...

The project is quite complexe, and without debug log or eror message (is there a way to get those?)
I really don't know how to to fix this...

Does anyone have the same problem? Any idea how to fix this?

Thank you

Francois

Comments

  • MentalDonkeyGamesMentalDonkeyGames Posts: 1,276Member

    1.25 handles code more efficiently, and is more picky on code order and layer order. It´s most likely some little thing you have in your code that freezes the game. Before 1.25 you could get by with some little mistakes and it would not matter, but you need to be more careful now.

    Mental Donkey Games
    Website - Facebook - Twitter

  • SocksSocks London, UK.Posts: 12,822Member

    @mooble said:

    The project is quite complexe, and without debug log or eror message (is there a way to get those?)

    Cmd+D

    @mooble said
    I really don't know how to to fix this...

    Remove all the sounds, remove all the images, delete actors, delete rules . . . keep simplifying your project until you have found the cause of the issue.

  • mooblemooble Posts: 4Member, PRO
    edited May 2016

    Thank you for the responses
    I dont get what is code and layer order... How do you know your code order is wrong and what is a layer order that could cause a bug.
    Beside the scene work only transition from scènes freeze. So the scene itself seems ok.
    I don't know what actor, scene parameter... To look for, if there is something specific about scene loading?

  • SocksSocks London, UK.Posts: 12,822Member

    @mooble said:
    Thank you for the responses
    I dont get what is code and layer order... How do you know your code order is wrong and what is a layer order that could cause a bug.

    An actor's code is scanned from top to bottom.
    Layers are scanned bottom to top.

    @mooble said:
    I don't know what actor, scene parameter... To look for,

    Take the project apart . . . keep simplifying the project until you have found the cause of the issue.

  • mooblemooble Posts: 4Member, PRO

    Thank you Socks
    Finally I found the culprit that was resetting the scène on startup. Still strange that this was happening on the device viewer only and not on the creator...
    Now just have to learn to create clean logic that wont mess too much
    Btw i don't get how to use the debugger. On Other engine it display a bunch of information during the game of what is going on behind the scene so you know what to debug. But the debugger in gamesalad display nothing. How do you guys use it efficiently?

  • SocksSocks London, UK.Posts: 12,822Member

    @mooble said:
    Thank you Socks
    Finally I found the culprit that was resetting the scène on startup. Still strange that this was happening on the device viewer only and not on the creator...

    You will very occasionally find something that behaves differently on the device viewer than it does in Creator, just the other day I ended up with a calculation (X-(abs(x)/x)) that produced 0 in Creator and 'nan' (not a number) on the device . . . but these discrepancies are fairly rare, but that's why we test on the actual device, to check for these issues.

    @mooble said:
    Btw i don't get how to use the debugger.

    Place a Log Debugging Statement action into your code (wherever you want/need) and using the Debug window (Cmd+D) you can see whether the Log Debugging Statement was triggered or not.

    So for example, if you want to know why your every 1 second timer keeps stopping, you could place a Log Debugging Statement into the timer, watch the Debug window, and you'll see the Log Debugging Statement pop up every 1 second . . . . and then you might notice that - for example - when your player collides with an enemy the Log Debugging Statements stop appearing . . . so you know the issue probably has something to do with what happens when the player and enemy collide. (terrible example ! but hopefully you get the idea).

  • mooblemooble Posts: 4Member, PRO

    Thank you for the explaination. very welcome!
    I start to understand how it can be usefull now.
    Have a nice day!

  • FrantoFranto Posts: 779Member

    I've been lucky or just clever with how I've been finding all the "bugs" related to the new code order.

    For example, the levels with bosses would end as soon as they start, but pre-1.25 they worked.

    I simply only checked the "conditions" surrounding why the game ended then. Went to the win condition for that specific level type, which checks if the boss is dead, then game end. Knowing about the new layer order, I simply put a 2 second self.time limit before activating the condition to check the boss.

    It worked and the game played normally. This was because since the boss spawned after that actor with the condition, that caused the game to be over before the boss could spawn and prevent the end of the game. Give some conditions ample time to activate so that their actor will spawn into the level, and everything should work.

    The other solution would have been to put the boss below the condition actor, but it wasn't possible in my game due to layer seperation{active actors are at top, essential, mechanics related actors at the bottom}.

Sign In or Register to comment.