Edytuj

Udostępnij za pośrednictwem


GKAchievement.ChallengeComposeControllerAsync Method

Definition

Overloads

ChallengeComposeControllerAsync(String, GKPlayer[])

Provides a view controller that can be used to send a challenge, with a message, to other players.

ChallengeComposeControllerAsync(String, GKPlayer[], NSViewController)
ChallengeComposeControllerAsync(String, GKPlayer[], UIViewController)

Asynchronously provides a view controller that can be used to send a challenge, with a message, to other players, returning a task with the response result.

ChallengeComposeControllerAsync(String, GKPlayer[])

Provides a view controller that can be used to send a challenge, with a message, to other players.

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 8, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.WatchOS, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult> ChallengeComposeControllerAsync (string message, GameKit.GKPlayer[] players);
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 10, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult> ChallengeComposeControllerAsync (string message, GameKit.GKPlayer[] players);
abstract member ChallengeComposeControllerAsync : string * GameKit.GKPlayer[] -> System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult>
override this.ChallengeComposeControllerAsync : string * GameKit.GKPlayer[] -> System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult>

Parameters

message
String

An editable message to display to the other players. May be .

players
GKPlayer[]

The players to challenge.

Returns

A task that represents the asynchronous ChallengeComposeController operation. The value of the TResult parameter is of type GameKit.GKChallengeComposeResult. Holds the return values from the asynchronous method .

Attributes

Applies to

ChallengeComposeControllerAsync(String, GKPlayer[], NSViewController)

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 10, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult> ChallengeComposeControllerAsync (string message, GameKit.GKPlayer[] players, out AppKit.NSViewController result);
abstract member ChallengeComposeControllerAsync : string * GameKit.GKPlayer[] *  -> System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult>
override this.ChallengeComposeControllerAsync : string * GameKit.GKPlayer[] *  -> System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult>

Parameters

message
String
players
GKPlayer[]

Returns

Attributes

Applies to

ChallengeComposeControllerAsync(String, GKPlayer[], UIViewController)

Asynchronously provides a view controller that can be used to send a challenge, with a message, to other players, returning a task with the response result.

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 8, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.WatchOS, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult> ChallengeComposeControllerAsync (string message, GameKit.GKPlayer[] players, out UIKit.UIViewController result);
abstract member ChallengeComposeControllerAsync : string * GameKit.GKPlayer[] *  -> System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult>
override this.ChallengeComposeControllerAsync : string * GameKit.GKPlayer[] *  -> System.Threading.Tasks.Task<GameKit.GKChallengeComposeResult>

Parameters

message
String

An editable message to display to the other players. May be null.

players
GKPlayer[]

The players to challenge.

result
UIViewController

The view controller that displays the result of the challenge. May be null.

Returns

Attributes

Remarks

The type of the result out argument is UIViewController on iOS and NSViewController on MacOS.

Applies to