0.9.1 is easy to break with the pause behavior.

PhoticsPhotics Member Posts: 4,172
edited November -1 in Working with GS (Mac)
Pause isn't exactly a pause behavior. It's more like a scene overlay. I think this method is a bit dangerous.

Why?

It's because it's so easy to break with a pause loop.

Scene #1 loads Scene #2
Scene #2 loads Scene #1

If you keep stacking scenes, the game... and even the Game Salad editor... becomes very unstable. I just stacked transparent boxes on each other. Heh... boom. GameSalad just crumbled.

I think there should be a limit on the behavior... only one scene at a time.

Comments

  • TwistedMechTwistedMech Member Posts: 408
    or have an event log so we can see what GS is doing and can spot looping.
  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    well if you get stuck in an infinite loop, isn't that bad programming :)
  • PhoticsPhotics Member Posts: 4,172
    jonmulcahy said:
    well if you get stuck in an infinite loop, isn't that bad programming :)

    Heh, it's very bad programming. That's not the point. The point is that this software is geared towards novice users. I'm thinking that there should be limits in place, to prevent the software from killing itself.

    I think the big problem with the pause behavior is that memory is already limited. By running two scenes at once — wow — the memory usage alone could crash a game. It probably shouldn't permit running three or more scenes at once if it's so likely to crash.
  • StormyStudioStormyStudio United KingdomMember Posts: 3,989
    "I deal in a very special kind security. A pause within a pause with in a pause...."

    "But what happens if you go to deep"

    "You might never get out"

    "BBBBWWWWWAAAAAAAAAAAARRRRRRRR"....

    http://inception.davepedu.com/
  • NesesitaGamesNesesitaGames Member Posts: 160
    I don't quite understand- how would you have two scenes running with this new Pause function? And- perhaps more importantly- how would you prevent it?
  • DreamLabDreamLab Member Posts: 2,127
    stormystudio said:
    "I deal in a very special kind security. A pause within a pause with in a pause...."

    "But what happens if you go to deep"

    "You might never get out"

    "BBBBWWWWWAAAAAAAAAAAARRRRRRRR"....

    http://inception.davepedu.com/

    That button was epic
    dL
  • scitunesscitunes Member, Sous Chef Posts: 4,047
    NesesitaGames said:
    I don't quite understand- how would you have two scenes running with this new Pause function? And- perhaps more importantly- how would you prevent it?

    You can use the new pause feature to pause a scene and go to a pause scene that runs on top of the first scene. The pause scene could be a simple "game is paused" static scene or it could be its own playable mini game. But what if you want to pause the mini game? You could add another pause for that, and so on. this would eat a lot of memory if you keep doing this.
  • StormyStudioStormyStudio United KingdomMember Posts: 3,989
    I think its still nice to have the option to pause a mini game, and at some point it has to fall into the hands of the game designer amateur or pro, to learn a few things. E.g. don't push the game engine to breaking point by pausing with in a pause....

    Perhaps a warning could pop up if you apply a pause behaviour advising not to do too many (or possibly any) paused scenes with in a pause scene, with in a pause scene and perhaps you get a warning noise if you do put too many pauses in... BWWWAAAHHHHHRRRR...

    http://inception.davepedu.com/

    :O)
  • DizkoDizko Member Posts: 498
    Why are we complaining about a good feature that is only broken with bad design?

    This doesn't make sense. This is like asking to limit the amount of actors in a scene because, if you add like 10000 actors, the game will crash. Well no crap it will crash. Don't ask for limitation, that's just silly. Just plan ahead and do testing to figure out the performance impact of certain tasks. GameSalad does enough hand-holding as it is, don't complain about a issue that can be avoided very easily.
  • BarkBarkCoBarkBarkCo Member Posts: 1,400
    +1 Dizko
  • PhoticsPhotics Member Posts: 4,172
    Dizko said:
    Why are we complaining about a good feature that is only broken with bad design?

    Actually, I'm finding Pause to be highly unstable. I'm working on BOT and pause would be useful. Yet, it's hard to restart the frozen scene.

    Also, I don't think it's too unusual of an issue... is Pause designed to handle multiple frozen scenes? I don't think so. GameSalad only plays one music track at a time, so I don't think it's outrageous to suggest that pause should be limited to a single scene.

    Unless the behavior is more stable, there should be limited to prevent bad coding. Not only can pause crash a game, it seems to wreak the editor too. I had a lot crashes today and it started when I was using pause.
  • QbAnYtOQbAnYtO Member Posts: 523
    my games are to awesome too pause :)
  • DizkoDizko Member Posts: 498
    Well the issue as you describe in the first post doesn't make sense from a design perspective, essentially you're creating an infinite loop. You don't want to do that, in any instance.
  • forkliftforklift Member Posts: 386
    I too am experiencing crashes when for instance, unpausing and starting a music track.
  • dmcdowelldmcdowell Member Posts: 128
    Photics and Forklift, if either of you are able to reproduce a crash (with pause or otherwise), can you send me your file and/or exact steps to reproduce? I am a big fan of getting rid of all crashes. Thanks -- dani at gendaigames dot com.
  • dmcdowelldmcdowell Member Posts: 128
    Bump for visibility.
  • forkliftforklift Member Posts: 386
    The exact steps to reproduce a crash for me:

    game boolean called musicON

    when true, play music file (defaults as true when game starts)

    When on pause screen, user has option to change game.musicON to false

    hit unpause button, resume play and return to pause screen

    while in pause screen, change game.musicON to true (from false/off)

    hit the unpause button, loading wheel and crash
  • sparkzillasparkzilla Member Posts: 152
    I am using the pause functionality as a way to avoid having lots of different Game Over/Replay screens. It seemed to me that because of the limitation of the "go to next/previous scene" functions I would need to create a Game Over scene for each level. Each new Game Over scene would then need a Change Scene command back to the specific scene to replay the scene.

    Using the pause I can simply make an overlay with a menu on it and use the "Replay scene" function to play over, and a "Levels" button to go back to the choose level screen.

    Anyways, there probably a more obvious solutions (teach me!), but it works perfectly for me!
  • dmcdowelldmcdowell Member Posts: 128
    Hi Forklift,
    Following your steps in a game made from scratch, we were unable to reproduce the crash. Is it still happening for you in 0.9.2 and if so, can you send in your game file? Maybe it's something specific to your file. Thanks!
Sign In or Register to comment.