<!--
{
  "availability" : [
    "iOS: 5.0.0 - 7.0.0",
    "iPadOS: 5.0.0 - 7.0.0",
    "macOS: 10.8.0 - 10.10.0",
    "visionOS: 1.0.0 - 1.0.0",
    "watchOS: 3.0.0 - 3.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "GameKit",
  "identifier" : "/documentation/GameKit/GKTurnBasedEventHandler",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "GameKit"
    ],
    "preciseIdentifier" : "c:objc(cs)GKTurnBasedEventHandler"
  },
  "title" : "GKTurnBasedEventHandler"
}
-->

# GKTurnBasedEventHandler

The [`GKTurnBasedEventHandler`](/documentation/GameKit/GKTurnBasedEventHandler) class is used to respond to important messages related to turn-based matches. To use it, call the [`shared()`](/documentation/GameKit/GKTurnBasedEventHandler/shared()) class method to get the singleton instance and assign an object that implements the [`GKTurnBasedEventHandlerDelegate`](/documentation/GameKit/GKTurnBasedEventHandlerDelegate) protocol to its [`delegate`](/documentation/GameKit/GKTurnBasedEventHandler/delegate) property. All methods are called on the main thread.

```
class GKTurnBasedEventHandler
```

## Overview> Important:
> Your game must initialize a local player before you can use any Game Center classes. If there is no initialized player, your game receives a ``doc://com.apple.gamekit/documentation/GameKit/GKError/Code/notAuthenticated`` error. For more information, see <doc://com.apple.gamekit/documentation/GameKit/authenticating-a-player>.

This framework has been deprecated in iOS 7. Use [`GKTurnBasedEventListener`](/documentation/GameKit/GKTurnBasedEventListener).

### Subclassing Notes

This class may not be subclassed.

## Topics

### Retrieving the Shared Instance

[`+  sharedTurnBasedEventHandler`](/documentation/GameKit/GKTurnBasedEventHandler/shared())

Returns the shared instance of the event handler.

### Getting and Setting the Delegate

[`delegate`](/documentation/GameKit/GKTurnBasedEventHandler/delegate)

The delegate for the event handler.

## Relationships

### Conforms To

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

[`Hashable`](/documentation/Swift/Hashable)

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

[`Equatable`](/documentation/Swift/Equatable)

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

[`CVarArg`](/documentation/Swift/CVarArg)

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)