Player Setup

Learn how to create a player or AI and enable them to control vehicles in your game.

Player Setup

If you're using the Space Combat Kit, you can set up the player by dragging the provided Player_SCK prefab into the scene.

If you're using the Mech Combat Kit, you can set up the player by dragging the provided Player_MCK prefab into the scene.

To create a new Player:

  1. Create a new game object and add a Game Agent component.

  2. Go to the inspector of the Game Agent component and check the Is Player checkbox

To check if a specific game agent is the player in code, use the following:

// Check if the game agent is a player
if (someGameAgent.IsPlayer)
{
    // Run code
}

Player Input

To set up the player input, check out the Input section.

Game Agents

Learn about everything you can do with Game Agents (the component that is used for both Player and AI) in this section.

Last updated