Documentation Archive Developer
Search

GameController Changes for Objective-C

GameController

GCController.h

Declaration
From
@property(readonly, getter=isAttachedToDevice) BOOL attachedToDevice
To
@property(nonatomic, readonly, getter=isAttachedToDevice) BOOL attachedToDevice

Declaration
From
@property(copy) void (^controllerPausedHandler)(GCController *controller)
To
@property(nonatomic, copy, nullable) void (^controllerPausedHandler)(GCController * _Nonnull controller)

Declaration
From
+ (NSArray *)controllers
To
+ (NSArray<GCController *> * _Nonnull)controllers

Declaration
From
@property(retain, readonly) GCExtendedGamepad *extendedGamepad
To
@property(nonatomic, retain, readonly, nullable) GCExtendedGamepad *extendedGamepad

Declaration
From
@property(retain, readonly) GCGamepad *gamepad
To
@property(nonatomic, retain, readonly, nullable) GCGamepad *gamepad

Declaration
From
@property(retain, readonly) GCMotion *motion
To
@property(nonatomic, retain, readonly, nullable) GCMotion *motion

Declaration
From
@property(nonatomic) NSInteger playerIndex
To
@property(nonatomic) GCControllerPlayerIndex playerIndex

Declaration
From
@property(readonly, copy) NSString *vendorName
To
@property(nonatomic, readonly, copy, nullable) NSString *vendorName

GCControllerAxisInput.h

Declaration
From
@property(readonly) float value
To
@property(nonatomic, readonly) float value

Declaration
From
@property(copy) GCControllerAxisValueChangedHandler valueChangedHandler
To
@property(nonatomic, copy, nullable) GCControllerAxisValueChangedHandler valueChangedHandler

GCControllerButtonInput.h

Declaration
From
@property(readonly, getter=isPressed) BOOL pressed
To
@property(nonatomic, readonly, getter=isPressed) BOOL pressed

Declaration
From
@property(copy) GCControllerButtonValueChangedHandler pressedChangedHandler
To
@property(nonatomic, copy, nullable) GCControllerButtonValueChangedHandler pressedChangedHandler

Declaration
From
@property(readonly) float value
To
@property(nonatomic, readonly) float value

Declaration
From
@property(copy) GCControllerButtonValueChangedHandler valueChangedHandler
To
@property(nonatomic, copy, nullable) GCControllerButtonValueChangedHandler valueChangedHandler

GCControllerDirectionPad.h

Declaration
From
@property(readonly) GCControllerButtonInput *down
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *down

Declaration
From
@property(readonly) GCControllerButtonInput *left
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *left

Declaration
From
@property(readonly) GCControllerButtonInput *right
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *right

Declaration
From
@property(readonly) GCControllerButtonInput *up
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *up

Declaration
From
@property(copy) GCControllerDirectionPadValueChangedHandler valueChangedHandler
To
@property(nonatomic, copy, nullable) GCControllerDirectionPadValueChangedHandler valueChangedHandler

Declaration
From
@property(readonly) GCControllerAxisInput *xAxis
To
@property(nonatomic, readonly, nonnull) GCControllerAxisInput *xAxis

Declaration
From
@property(readonly) GCControllerAxisInput *yAxis
To
@property(nonatomic, readonly, nonnull) GCControllerAxisInput *yAxis

GCControllerElement.h

Declaration
From
@property(readonly, getter=isAnalog) BOOL analog
To
@property(nonatomic, readonly, getter=isAnalog) BOOL analog

Declaration
From
@property(assign, readonly) GCControllerElement *collection
To
@property(nonatomic, assign, readonly, nonnull) GCControllerElement *collection

GCExtendedGamepad.h

Declaration
From
@property(readonly) GCControllerButtonInput *buttonA
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonA

Declaration
From
@property(readonly) GCControllerButtonInput *buttonB
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonB

Declaration
From
@property(readonly) GCControllerButtonInput *buttonX
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonX

Declaration
From
@property(readonly) GCControllerButtonInput *buttonY
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonY

Declaration
From
@property(readonly, assign) GCController *controller
To
@property(nonatomic, readonly, assign, nonnull) GCController *controller

Declaration
From
@property(readonly) GCControllerDirectionPad *dpad
To
@property(nonatomic, readonly, nonnull) GCControllerDirectionPad *dpad

Declaration
From
@property(readonly) GCControllerButtonInput *leftShoulder
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *leftShoulder

Declaration
From
@property(readonly) GCControllerDirectionPad *leftThumbstick
To
@property(nonatomic, readonly, nonnull) GCControllerDirectionPad *leftThumbstick

Declaration
From
@property(readonly) GCControllerButtonInput *leftTrigger
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *leftTrigger

Declaration
From
@property(readonly) GCControllerButtonInput *rightShoulder
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *rightShoulder

Declaration
From
@property(readonly) GCControllerDirectionPad *rightThumbstick
To
@property(nonatomic, readonly, nonnull) GCControllerDirectionPad *rightThumbstick

Declaration
From
@property(readonly) GCControllerButtonInput *rightTrigger
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *rightTrigger

Declaration
From
@property(copy) GCExtendedGamepadValueChangedHandler valueChangedHandler
To
@property(nonatomic, copy, nullable) GCExtendedGamepadValueChangedHandler valueChangedHandler

GCExtendedGamepadSnapshot.h

Declaration
From
@property(copy) NSData *snapshotData
To
@property(atomic, copy, nonnull) NSData *snapshotData

GCGamepad.h

Declaration
From
@property(readonly) GCControllerButtonInput *buttonA
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonA

Declaration
From
@property(readonly) GCControllerButtonInput *buttonB
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonB

Declaration
From
@property(readonly) GCControllerButtonInput *buttonX
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonX

Declaration
From
@property(readonly) GCControllerButtonInput *buttonY
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *buttonY

Declaration
From
@property(readonly, assign) GCController *controller
To
@property(nonatomic, readonly, assign, nonnull) GCController *controller

Declaration
From
@property(readonly) GCControllerDirectionPad *dpad
To
@property(nonatomic, readonly, nonnull) GCControllerDirectionPad *dpad

Declaration
From
@property(readonly) GCControllerButtonInput *leftShoulder
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *leftShoulder

Declaration
From
@property(readonly) GCControllerButtonInput *rightShoulder
To
@property(nonatomic, readonly, nonnull) GCControllerButtonInput *rightShoulder

Declaration
From
@property(copy) GCGamepadValueChangedHandler valueChangedHandler
To
@property(nonatomic, copy, nullable) GCGamepadValueChangedHandler valueChangedHandler

GCGamepadSnapshot.h

Declaration
From
@property(copy) NSData *snapshotData
To
@property(atomic, copy, nonnull) NSData *snapshotData

GCMotion.h

Declaration
From
@property(assign, readonly) GCQuaternion attitude
To
@property(nonatomic, assign, readonly) GCQuaternion attitude

Declaration
From
@property(readonly, assign) GCController *controller
To
@property(nonatomic, readonly, assign, nonnull) GCController *controller

Declaration
From
@property(assign, readonly) GCAcceleration gravity
To
@property(nonatomic, assign, readonly) GCAcceleration gravity

Declaration
From
@property(assign, readonly) GCRotationRate rotationRate
To
@property(nonatomic, assign, readonly) GCRotationRate rotationRate

Declaration
From
@property(assign, readonly) GCAcceleration userAcceleration
To
@property(nonatomic, assign, readonly) GCAcceleration userAcceleration

Declaration
From
@property(copy) GCMotionValueChangedHandler valueChangedHandler
To
@property(nonatomic, copy, nullable) GCMotionValueChangedHandler valueChangedHandler