How do you exit an application in CocosSharp?

不想你离开。 提交于 2019-12-25 20:04:46

问题


I am trying to add "Exit Game" functionality in my CocosSharp game (for Windows phone) but I am unable to find any sample code/ guidance online. Any pointers would be welcome.

User should be able to quit the game by pressing a button image on the screen.


回答1:


Mobile apps are not closed.

They run forever unless they crash, are forced closed by the user, or are shut down by the OS to free up resources.

It's not to say you cannot invoke a system call to exit your program but it is simply not the implementation that is done in modern mobile development.




回答2:


Well, simply by looking at intellisense i found ExitGame() method on CCApplication instance.



来源:https://stackoverflow.com/questions/35808358/how-do-you-exit-an-application-in-cocossharp

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!