Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

How to Detect the closing of application...

Discussion in 'Scripting' started by Dinesh Balu, Apr 7, 2011.

  1. Dinesh Balu

    Dinesh Balu

    Joined:
    Mar 10, 2011
    Posts:
    255
    Hi...
    I want to execute some code when the player exits the game.So how can I detect the closing of the application...
     
  2. Frank Oz

    Frank Oz

    Joined:
    Oct 13, 2010
    Posts:
    1,560
  3. Dinesh Balu

    Dinesh Balu

    Joined:
    Mar 10, 2011
    Posts:
    255
  4. Frank Oz

    Frank Oz

    Joined:
    Oct 13, 2010
    Posts:
    1,560
    SL0WD0WN likes this.
  5. Dinesh Balu

    Dinesh Balu

    Joined:
    Mar 10, 2011
    Posts:
    255
    does the function OnApplicationQuit() work on Iphone applications?
     
    petermrparreira likes this.
  6. Dinesh Balu

    Dinesh Balu

    Joined:
    Mar 10, 2011
    Posts:
    255
    Not for you Frank..:) but for beginners like me.... There is an example code