AI Agents

  • A game scene that an AI agent can control.

    In the game scene, the player can provide a move budget and strategy to solve the puzzle. A default random move strategist with a budget of ten moves is provided when these options aren’t available.

    Important

    Scenes that subclass the AI game scene must be running macOS 10.15 Catalina or higher.
    See more

    Declaration

    Swift

    @available(macOS 10.15, *)
    class AIGameScene : ChallengeGameScene
  • An abstract class that represents a game player.

    See more

    Declaration

    Swift

    class AIAbstractGamePlayer : NSObject, GKGameModelPlayer
  • An abstract class that represents a game state/model.

    See more

    Declaration

    Swift

    class AIAbstractGameState : NSObject, GKGameModel
  • An class that represents an agent in the game.

    See more

    Declaration

    Swift

    class AIGameStrategist
  • A strategist that will pick random moves.

    See more

    Declaration

    Swift

    public class AIRandomMoveStrategist : NSObject, GKStrategist
  • A explorative strategist that uses Random Network Distillation to determine the most optimal move.

    Random Network Distillation (RND) is a reinforcement learning-based strategy that places emphasis on unexplored states, encouraging the strategist to explore the game with rewards for encountering new states. RND scores states by measuring how difficult it is to predict the output based on previous experience.

    For more information, consult the OpenAI article titled Reinforcement Learning with Prediction-Based Rewards.

    See more

    Declaration

    Swift

    class AIRandomNetworkStrategist : NSObject, GKStrategist
  • An abstract data structure that represents an input device.

    See more

    Declaration

    Swift

    struct AIAbstractGameSignalSender
  • An abstract data structure that represents a signal receiver.

    See more

    Declaration

    Swift

    struct AIAbstractGameSignalReceivable
  • An abstract class that represents a decision an agent can make.

    See more

    Declaration

    Swift

    class AIGameDecision : NSObject, GKGameModelUpdate
  • An enumeration that represents the moves an agent can make.

    See more

    Declaration

    Swift

    public enum AIGamePlayerAction : CaseIterable