RTS Starter Kit

Real-time strategy foundation with camera, click-to-move navigation, unit selection, minimap, and wave spawning.

6 scripts intermediate Starter kit Complete RTS prototype foundation

The full files for this kit are not published yet, so there is no download. 4 of its 6 scripts are in the library and linked below. The preview shows how the main pieces fit.

What is inside

What it does

  • Top-down camera with WASD pan, edge scroll, and zoom
  • Click-to-move navigation using NavMesh agents
  • Box selection and click selection for units
  • Render texture minimap with unit blips and zoom
  • Wave-based enemy spawning system
  • Move, attack, and patrol command queuing

Setup, in order

  1. Import all scripts and bake NavMesh on your terrain
  2. Set up camera rig with TopDownCamera at a top-down angle
  3. Create unit prefabs with NavMeshAgent and NavMeshClickToMove
  4. Add SelectionManager to a manager object for unit selection
  5. Create minimap camera (orthographic, top-down) rendering to RenderTexture
  6. Display RenderTexture in a UI RawImage with MinimapSystem
  7. Set up spawn points and configure WaveSpawner for enemies

If something does not work

Units do not move when clicked
NavMeshClickToMove needs a baked NavMesh: add a NavMeshSurface (AI Navigation package) to the terrain and press Bake. Also check that the ground layer mask includes your terrain.

Preview

An excerpt of the kit's main types, and the Inspector fields they expose.

InspectorExcerpt

Fields from the kit's preview excerpt; the full kit has more.

Pan Speed 20
Enable Edge Scroll
Min Zoom 5
Max Zoom 30
Excerpt
C#
// TopDownCamera.cs - RTS camera controller
public class TopDownCamera : MonoBehaviour
{
    [SerializeField] private float panSpeed = 20f;
    [SerializeField] private bool enableEdgeScroll = true;
    [SerializeField] private float minZoom = 5f;
    [SerializeField] private float maxZoom = 30f;
    // WASD pan, edge scroll, scroll zoom
}

// SelectionManager.cs - Unit selection (included in kit)
public class SelectionManager : MonoBehaviour
{
    // Box selection + click selection
    // Highlight selected units
    // Issue commands to selection group
}