Simulator quiting unexpectedly and showing no errors

The simulator has been “logging out” (i.e. closing itself for no apparent reason and giving no errors) lately and the terminal just says:
logout
(Process completed)

I know when it happens. I’m removing a display group that has a variable I couldn’t remove on its own (was giving me the old referencing a nil global variable error) though I don’t think it was. Basically I’m trying to remove a button object in its onPress function. It works fine most of the time, but sometimes it just exits and I can’t pinpoint why. It works fine on device.

Even if I’m doing something wrong the terminal should point it out, so I think this is a bug. [import]uid: 10835 topic_id: 4100 reply_id: 304100[/import]

The simulator shouldn’t exit on it’s own like that. Can you post some code that demonstrates the problem?

Thanks,
-Tom [import]uid: 7559 topic_id: 4100 reply_id: 13083[/import]

I suspect the problem might be a little more complicated than just a few lines of code. It happens after I pause the game and press another button to exit to the menu. The exit button is the culprit. Pausing and resuming works fine. In the earlier versions of my code it happened pretty much every time. Since then I’ve moved the object.remoSelf() to another function and it doesn’t crash that often.

I could provide the earlier version of my code, so you guys in the office can get together and have a good laugh at the sheer stupidity of some of the implementations in there and see where it’s killing the simulator :). [import]uid: 10835 topic_id: 4100 reply_id: 13112[/import]

Ok I’ve been told by my beta testers than the game does crash if you repeteadly pause, play, pause and exit, etc, on the device. It works fine under normal conditions, but when specifically trying to break it, well it breaks. Unfortunately I can’t replicate it on my iphone 4 (I get no crashes), so I don’t know what it could be. I’m pretty sure it’s not a memory leak, since memory usage doesn’t increase.

My offer to send over the code still stands if you’re interested. I’d love to get this fixed. [import]uid: 10835 topic_id: 4100 reply_id: 13190[/import]

In the past we’ve seen simulator and app crashes when when you try to remove objects (removeSelf) that already have been removed or trying to remove a nil object. Your code should set any removed object to nil and test for nil before removing any object. This may help to pin-point the problem. There were lots of simulator/app crash problems a while back but I haven’t hear of any problems in this area with our current released code.

I would be happy to take a quick look at your code to help us understand if we have a problem. You can send it to tom at anscamobile.com. Please let me know what build of the simulator you’re using.

Thanks,
-Tom [import]uid: 7559 topic_id: 4100 reply_id: 13219[/import]

I had a similar problem and tracked it down to trying to remove an object that had already been removed what I did to fix it was just checked to see if the object had already been removed and if so just skipped the remove code [import]uid: 7911 topic_id: 4100 reply_id: 13229[/import]

The weird thing is that I know for a fact the object exits, since it’s a button that’s removed when pressed (so if it doesn’t exist you can’t tap it). And it’s only that button that’s the problem. I do the same everywhere else in my code with no problem (I don’t do the check, because I know they exist). I’ll send the code soon. [import]uid: 10835 topic_id: 4100 reply_id: 13231[/import]

Are you also removing the event listener
What I would do instead of removing the button just make it’s alpha 0 or is Visible = false and remove the listener [import]uid: 7911 topic_id: 4100 reply_id: 13236[/import]

Just a quick FYI the new version still does this. [import]uid: 10835 topic_id: 4100 reply_id: 13285[/import]

Are you invoking the physics engine API in any of these button interactions? I’ve had it crash the simulator if I provided invalid data to certain functions. Also, does it crash on the device or XCode simulator, or only in the Corona sim?

Tim [import]uid: 8196 topic_id: 4100 reply_id: 13389[/import]

The new Corona release doesn’t have any fixes for simulator crashes since we didn’t have any open issues pending.

Did you send your project code? I haven’t seen anything in my mailbox.

Thanks,
-Tom [import]uid: 7559 topic_id: 4100 reply_id: 13390[/import]

No physics APIs. I’m using ui.lua for the button code. In crashes on the simulator real quickly. If I do it 2 or 3 times. On the device my beta testers got it to crash, but it took a lot more tries. I can’t get it to crash on my iphone 4.

I just sent you the code now, sorry for the delay. [import]uid: 10835 topic_id: 4100 reply_id: 13394[/import]

Hello everyone,

I am new in Lua,

And I want to exit from the application when i touch my Quit button(listener). I have tried with applicationexit phase but not getting anythings.

Please do need full…

Thankx
Krunal. [import]uid: 33757 topic_id: 4100 reply_id: 22649[/import]

You can exit an application by using:

os.exit()  

http://developer.anscamobile.com/reference/index/osexit [import]uid: 7559 topic_id: 4100 reply_id: 22728[/import]

Hi,

Thankx for your reply…
local function btnQuit(event)
if event.phase == “end” then
os.exit()
end
end

I have used this on my Quit Listener but using this things, My Simulator is closed.
but when i m write in this if condition os.exit() is not wroking instead when i wrote this without if condition its work and close my simulator.

is it right way to exit from the application, or any other way that my simulator is open but only my application is exit…
Thankx,
Krunal [import]uid: 33757 topic_id: 4100 reply_id: 22878[/import]

The os.exit() API has changed in the latest daily build (#295) and it no longer closes the Simulator (just the app).

If you are paid Corona SDK subscriber you can download the latest daily build. http://developer.anscamobile.com/downloads/daily-builds

-Tom [import]uid: 7559 topic_id: 4100 reply_id: 23022[/import]

Hi Tom,

Thankx for share this info with me.
[import]uid: 33757 topic_id: 4100 reply_id: 23384[/import]

I am using Windows Corona, when will updates like this get into the Windows version?

When do Windows updates occur?

Thanks. [import]uid: 36439 topic_id: 4100 reply_id: 26334[/import]

People have different assessment tool meaning of self reverence and the assessment set that are available tend to reflect the different meaning however in Insights.
[import]uid: 147623 topic_id: 4100 reply_id: 105276[/import]