implement android game::exit

This commit is contained in:
altalk23 2023-10-01 19:18:40 +03:00
parent 8f34244023
commit 238d1b7de9
2 changed files with 6 additions and 2 deletions

View file

@ -4501,6 +4501,7 @@ class MenuLayer : cocos2d::CCLayer, FLAlertLayerProtocol, GooglePlayDelegate {
void onFacebook(cocos2d::CCObject*) = win 0x191960;
void onTwitter(cocos2d::CCObject*) = win 0x191980;
void onYouTube(cocos2d::CCObject*) = win 0x1919A0;
void endGame();
static cocos2d::CCScene* scene(bool) = mac 0x1d12d0, win 0x190720, ios 0x19e57c;
cocos2d::CCSprite* m_googlePlaySprite;

View file

@ -50,8 +50,11 @@ void geode::utils::game::launchLoaderUninstaller(bool deleteSaveData) {
}
void geode::utils::game::exit() {
// Not implemented
log::error("Exiting the game is not implemented on android");
CCDirector::get()->getActionManager()->addAction(CCSequence::create(
CCDelayTime::create(0.5f),
CCCallFunc::create(nullptr, callfunc_selector(MenuLayer::endGame)),
nullptr
), CCDirector::get()->getRunningScene(), false);;
}
void geode::utils::game::restart() {