I tried to add RegisterForRemoteNotification to GameMode without plugin, and it still do not works. You can update my project from git, and try again.
I think the engine source code maybe is wrong.
void FIOSPlatformMisc::RegisterForRemoteNotifications()
{
#if !PLATFORM_TVOS
UIApplication* application = [UIApplication sharedApplication];
// if ([application respondsToSelector : @selector(registerUserNotifcationSettings:)])
{
#ifdef __IPHONE_8_0
UIUserNotificationSettings * settings = [UIUserNotificationSettings settingsForTypes : (UIUserNotificationTypeBadge | UIUserNotificationTypeSound | UIUserNotificationTypeAlert) categories:nil];
[application registerUserNotificationSettings : settings];
#endif
}
else
{ // I use iPhone5s, it always come here
#if __IPHONE_OS_VERSION_MIN_REQUIRED < __IPHONE_8_0
UIRemoteNotificationType myTypes = UIRemoteNotificationTypeBadge | UIRemoteNotificationTypeAlert | UIRemoteNotificationTypeSound;
[application registerForRemoteNotificationTypes : myTypes]; // It can't run into here. So, it always don't call registerForRemoteNotificationTypes and trigger FCoreDelegates::ApplicationRegisteredForRemoteNotificationsDelegate.
#endif
}
#endif
}
I tried to call [application registerUserNotificationSettings : settings];, [application registerForRemoteNotifications]; or [application registerForRemoteNotificationTypes : myTypes];, but FCoreDelegates::ApplicationRegisteredForRemoteNotificationsDelegate isn’t triggered.
I think it obviously is a bug. Please try it again and tell me your result. I want to make sure we have same result.