Using set_time_step to pause freezes/crashes the bundled app on iOS, Android and Windows

I’m updating an old app, and get a strange behaviour on iOS, bundling with Defold 1.3.1.

This freezes the app: No updates fire anymore, but the app doesn’t shut down. When force closed an iOS crash popup shows:

msg.post("screens:/gameworld#collectionproxy", "set_time_step", {factor = 0, mode = 0})

This works as intended:

msg.post("screens:/gameworld#collectionproxy", "set_time_step", {factor = 0.1, mode = 0})

Minimal repo project: SetTimeStep.zip (53.7 KB)

2 Likes

Hello @totebo,

I can’t bundle your app for ios, but it stops on Android as well when factor = 0 is used. It never prints the second print statement and just sits there. Factor = 0.1 works.

The app isn’t quite dead yet, as logcat reports input events when I touch the screen, but after just a few of them, I get this error:

2022-04-29 17:52:34.795 11382-11395/com.example.todo E/glfw-android: glfwAndroidHandleInput: max num app input events per frame reached
2022-04-29 17:52:34.795 11382-11395/com.example.todo V/threaded_app: New input event: type=2
2022-04-29 17:52:34.795 11382-11395/com.example.todo E/glfw-android: glfwAndroidHandleInput: max num app input events per frame reached
2022-04-29 17:52:34.795 11382-11382/com.example.todo D/ViewRootImpl: ViewPostImeInputStage processPointer 1
2022-04-29 17:52:51.360 11382-11395/com.example.todo V/threaded_app: New input event: type=2
2022-04-29 17:52:51.360 11382-11395/com.example.todo E/glfw-android: glfwAndroidHandleInput: max num app input events per frame reached
2022-04-29 17:52:51.365 11382-11382/com.example.todo D/ViewRootImpl: ViewPostImeInputStage processPointer 0
2022-04-29 17:52:51.405 11382-11395/com.example.todo V/threaded_app: New input event: type=2

As the second version runs and logcat happily reports input events without complaint, maybe the crash has something to do with input.

1 Like

Thanks for testing this @raetia! It’s somewhat of a game stopper. I think it might have something to do with the recent fixed time step feature.

1 Like

Yes, I think so too. Could you please also create an issue in GitHub?

2 Likes

Certainly!

5 Likes

Thanks

1 Like

Bumping this.

Bug also occurs on Windows bundled builds (though not when run from Defold editor).

Game freezes when setting time step to 0 for pause menu.

5 Likes

This issue persists on Android and Windows (at least)

Game freezes when setting time step to 0 on release builds, though no issues in debug builds.

This issue has been fixed here: https://github.com/defold/defold/issues/6566

The fix is available in the latest beta.

4 Likes