Search Unity

Quit Unity Game from native iOS

Discussion in 'Addressables' started by common_unity429, Jun 27, 2019.

  1. common_unity429

    common_unity429

    Joined:
    Jun 21, 2019
    Posts:
    1
    Hi,

    We are trying to integrate unity project inside the native iOS project by following the tutorial from this article, https://www.kodbiro.com/blog/a-great-way-to-integrate-unity-into-the-native-ios-app.

    The problem we are facing now is that we cannot quit the game properly in iOS native project.

    We tried to close the unity app with "Application.Quit()" but it close the game as well as native app entirely.

    Second way is we add "Application.Unload()". It just close the game as normal but cannot launch it back.

    And the last way we've tried is, we call the native method from unity to close the game. But from the native side, we cannot release the instance completely from the memory. And when we tried to create a new instance of the unity game it cause the conflict issues (ref to the error log).

    Can you advise us how we can quit the unity app redirect back to the native app in a proper way.

    Thank you in advance.
     
  2. PavelLU

    PavelLU

    Unity Technologies

    Joined:
    Feb 23, 2017
    Posts:
    107