PlayerGetActionAsync Method

Asynchronously gets the action the player wants to take based on the current game context.

Definition

Namespace: ProjectLCore.Players
Assembly: ProjectLCore (in ProjectLCore.dll) Version: 1.0.0+d0f5e2a7a5f4bb0431970f279d2f79d24b15d256
C#
public abstract Task<GameAction> GetActionAsync(
	GameStateGameInfo gameInfo,
	PlayerStatePlayerInfo[] playerInfos,
	TurnInfo turnInfo,
	ActionVerifier verifier,
	CancellationToken cancellationToken = default
)

Parameters

gameInfo  GameStateGameInfo
Information about the shared resources.
playerInfos  PlayerStatePlayerInfo
Information about the resources of the players.
turnInfo  TurnInfo
Information about the current turn.
verifier  ActionVerifier
Verifier for verifying the validity of actions in the current game context.
cancellationToken  CancellationToken  (Optional)
A cancellation token to observe while waiting for the task to complete.

Return Value

TaskGameAction
The action the player wants to take.

See Also