From b259fc34f4fc160c01947ade65f0964f473ce466 Mon Sep 17 00:00:00 2001 From: antja0 <47383357+antja0@users.noreply.github.com> Date: Tue, 18 Aug 2026 17:20:18 +0300 Subject: [PATCH] Add GameKit GKLocalPlayer_RegisterLocalPlayerListener native export Fix error Undefined symbol: _GKLocalPlayer_RegisterLocalPlayerListener when running the game on iPhoneSimulator, using IL2CPP in Unity 6000.3.15f1, Xcode 27 / iOS 27 SDK. --- .../Native/GameKitWrapper/GKLocalPlayer.swift | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/plug-ins/Apple.GameKit/Native/GameKitWrapper/GKLocalPlayer.swift b/plug-ins/Apple.GameKit/Native/GameKitWrapper/GKLocalPlayer.swift index 5b08aa19..35ab129f 100644 --- a/plug-ins/Apple.GameKit/Native/GameKitWrapper/GKLocalPlayer.swift +++ b/plug-ins/Apple.GameKit/Native/GameKitWrapper/GKLocalPlayer.swift @@ -99,6 +99,15 @@ public func GKLocalPlayer_SetAuthenticateHandler } } +@_cdecl("GKLocalPlayer_RegisterLocalPlayerListener") +public func GKLocalPlayer_RegisterLocalPlayerListener +( +) +{ + GKLocalPlayer.local.unregisterAllListeners(); + GKLocalPlayer.local.register(_localPlayerListener); +} + @_cdecl("GKLocalPlayer_GetLocal") public func GKLocalPlayer_GetLocal (