Game crashes on device

Hiyas.

My game works perfectly fine (minus a few jitters here and there) on the Gamesalad creator's Viewer. However it skips parts of the intro and doesn't open the main menu when using both the gamesalad viewer on my device and an ad hoc build. Please help I'm not sure what to do to fix this.

Comments

  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    sounds like you have a bad rule in there somewhere. did you remove any attributes? that usually causes it.

    every time I've seen the viewer work but break on a device it's the result of a bad rule or missing attribute.
  • MattcusMattcus Member Posts: 85
    edited September 2013
    Would it be more likely to be somewhere in the menu, because that's when it crashes the most.

    Edit: I've looked through some of the rules, and cleaned a little bit up, but from what I see everything looks fine, but it still doesn't work properly.
  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    One thing to check for is mixup with say typing false in a change attribute when it's not a Boolean or putting a number when it's a Boolean. I would check the intro as if it's skipping things there and such the error might not time out until the next scene so I would check the intro first.
  • MattcusMattcus Member Posts: 85
    I had a brief look at the intro, and still don't know what happens, but when I say it "skips" things, I mean more that it lags and it stutters through things.

    Also I tried testing other parts of the game, by testing the game with the menu as the first scene. And most scene changes crash, and the main scene of the game itself is very laggy.
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited September 2013

    @Mattcus

    Hi, as the other guys said; sometimes, as well, Timers might be the problem (getting "tangled" as it were)... if not that, perhaps it's a RAM problem... (you don't mention what sort of intro it is but if it involves lots of animation frames, it could well be what's happening)... so just set your intro to preload graphics only, uncheck the rest, see if that does the trick...

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • MattcusMattcus Member Posts: 85
    edited September 2013
    There are no animations in the intro, and there are no timers, I used the self.time attribute instead. And the intro itself is just actors moving across the screen.
  • SlickZeroSlickZero Houston, TexasMember, Sous Chef Posts: 2,870
    Have you tried restarting the device? Just another thing to try if you are sure your rules and logic are correct.
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited September 2013
    There are no animations in the intro, and there are no timers, I used the self.time attribute instead. And the intro itself is just actors moving across the screen.
    OK, what method are you using to move the actors across the screen? And can you interrupt the movements before they are finished, to go to the menu screen?

    --bump--
    Have you tried restarting the device? Just another thing to try if you are sure your rules and logic are correct.

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • MattcusMattcus Member Posts: 85
    @Gyroscope

    I'm using the interpolate behaviour for the movement. And the intro cannot be skipped, once it is finished a play button appears, and when you click that it's supposed to take you to the menu, but that is where it crashes.

    @SlickZero

    I tried restarting the device, but it didn't change anything.
    Also, I'm not certain that my rules and logic are correct, I just can't clearly see any problems.
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited September 2013

    @Mattcus

    Curiouser and curiouser... OK, I'm sure you've checked the Timer After number of seconds is adequate to allow the Interpolate to finish, and that the Timer behaviour is placed after the Interpolate behaviour...if not, they'd be worth changing.

    Maybe try adding something like .3 of a second to the Timer After amount of seconds already there, and make sure to check Run to Completion in the Timer behaviour if its not already. (Actually, this checking of Run to Completion is worth trying first...)

    Your Change Scene behaviour in the Timer: is it set to go to a scene with a particular name, or to next scene? Whichever it is, try the opposite, and see if that improves the situation. (More info: if you deleted a scene then remade it with the same name, that can sometimes cause problems too, so to fix that, replace the Change Scene behaviour and set it up again as fresh.) Hope something there helps now.

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • MattcusMattcus Member Posts: 85
    I've pretty much fixed up the intro, however it still crashes after I press play.
  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    My bet is the problem is something in the menu. Try putting a different scene in as the menu to test if the transition works. Also try putting the menu before the intro to see if it loads.

  • MattcusMattcus Member Posts: 85
    I've tried putting the menu as the first scene, and it worked, I even went to the intro from the menu, then back to the menu and that worked.

    On the menu there is a help button and a play game button, the play game button works, the help button crashes.

    During the game you're can access a shop, but it crashes with that as well. It also crashes when trying to get back to the menu from the game.

    Putting the main game scene, directly after the intro, works, however not properly, some animations aren't working, and some text isn't being displayed.
  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    youre gonna have to hook your phone up to Instruments (which you got with xcode) and watch the memory usage of your app as you play it. post the results back here.
  • MattcusMattcus Member Posts: 85
    edited September 2013
    Edit: Nevermind I found it
  • MattcusMattcus Member Posts: 85
    How do I use instruments?
  • MattcusMattcus Member Posts: 85
    edited September 2013
    Ok I managed to work it out (I think)

    When using instruments at the same time as running the game, it crashed before the play button appeared.

    I'm not sure if this would be useful at all but I took this screenshot:

    image
  • MattcusMattcus Member Posts: 85
    Does anyone know how I can fix this, this is the only thing I need to fix before I can publish my game! Please help!
  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    You have bad code somewhere and you need to find it. You have to start turning off stuff until you find it. That sheet tells us nothing. Trouble shooting a problem isn't easy. You have to narrow it down to a scene and start turning things off until you find it.
  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    and you're using instruments on the gamesalad viewer, which wont give you anything useful, you need to do it on a real adhoc build.
  • MattcusMattcus Member Posts: 85
    edited September 2013
    Ok, Sorry If my inexperience is bugging any of you :)
    I think I've narrowed it down to the intro scene itself, because the other scenes work fine when put on their own, it's only when the intro transitions to another scene does it crash.
    Actually it also crashes when changing scenes in other parts of the game as well.
    I haven't started to look into them yet, because I'm still working on the intro crash.

    Do you have any other tips on troubleshooting that might be helpful?
  • MattcusMattcus Member Posts: 85
    edited September 2013
    I fixed It! The images i had for the menu were way to big, over 1000 pixels bigger than I needed them to be, so I put in smaller ones, and the game goes past the intro now.

    However now that I can get to the other scenes I've noticed some other problems:

    Edit: I fixed the sliding scenes
    Some text from tables aren't being displayed but they do on the computer.
    The animations don't work all the time. (Sometimes when I run the game they work, other time they don't.)
    Sometimes it crashes randomly, usually when you lose the game.

    If these are common problems and someone knows how to fix them, it would be greatly appreciated if you could help me with this. In the mean time I will continue to fix it myself.
    Thanks for everyone's help so far
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited September 2013
    I fixed It! The images i had for the menu were way to big, over 1000 pixels bigger than I needed them to be, so I put in smaller ones, and the game goes past the intro now.

    ...perhaps it's a RAM problem...
    Ooh, do I get a lollypop? :D ;-)

    ---bump---

    ..However now that I can get to the other scenes I've noticed some other problems:

    Edit: I fixed the sliding scenes
    Some text from tables aren't being displayed but they do on the computer.
    The animations don't work all the time. (Sometimes when I run the game they work, other time they don't.)
    Sometimes it crashes randomly, usually when you lose the game.

    If these are common problems and someone knows how to fix them, it would be greatly appreciated if you could help me with this. In the mean time I will continue to fix it myself.
    Thanks for everyone's help so far

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

Sign In or Register to comment.