MacOS 版游戏无法过审

Cocos Creator 版本:3.8.6
目标平台:MacOS Sequoia 15.4.1

游戏提交苹果商店后被拒,理由如下:
Specifically, upon review we have found the application binary will not Quit when clicking the “Quit” tab from MacOS Status bar. Additionally, we are unable to quit the application when using the Command + Q shortcut. Please see the screenshot attached.

我试了一下,确实点系统菜单里的Quit项没有任何反应,Command + Q也没有任何响应。

这种简单点,在oc代码里面,响应那个按钮就好了.

具体怎么响应,可以直接问一下AI.

谢谢回复,我试试。

解决了,感谢老年UI仔指导。在AppDelegate.mm里自己写个菜单替换一下,响应退出按钮:

@implementation AppDelegate

- (void)applicationDidFinishLaunching:(NSNotification*)aNotification {
    _platform = dynamic_cast<cc::MacPlatform*>(cc::BasePlatform::getPlatform());
    // 改成定制菜单,支持退出按钮
    [self createAppMenu];
}


- (void) createAppMenu {
     NSMenu *menubar = [[NSMenu alloc]init];
     NSMenuItem *menuBarItem = [[NSMenuItem alloc] init];
     [menubar addItem:menuBarItem];
     [NSApp setMainMenu:menubar];
     NSMenu *myMenu = [[NSMenu alloc] init];
    // Add menu items
    NSMenuItem *menuItem1 = [[NSMenuItem alloc] initWithTitle:@"About" action:@selector(menuItemAction:) keyEquivalent:@""];
    [menuItem1 setTarget:self];
    [myMenu addItem:menuItem1];

    NSString* quitTitle = @"Quit";
    NSMenuItem* quitMenuItem = [[NSMenuItem alloc] initWithTitle:quitTitle
        action:@selector(menuItemAction:) keyEquivalent:@"q"];
    [quitMenuItem setTarget:self];
    [myMenu addItem:quitMenuItem];
    
    [menuBarItem setSubmenu:myMenu];
 }

// Action method for menu item clicks
- (void) menuItemAction:(id)sender {
    NSMenuItem *item = (NSMenuItem *)sender;
    NSString *title = [item title];
    NSLog(@"Menu item clicked: %@", title);
    // Handle menu item actions
    if ([title isEqualToString:@"Quit"]) {
        // Do something for item 1
        NSLog(@"Quit app");
        _platform->exit();
    } else if ([title containsString:@"About"]) {
        // Do something for item 2
        [[NSApplication sharedApplication] orderFrontStandardAboutPanel:sender];
    }
}
1赞