# Turrets

### Creating A Gun Turret

To create a gun turret:

1. Create a new game object and call it 'Gun Turret'.
2. Add a **Gun Turret** component, this will add **Gun Weapon** and **Gimbal Controller** components.
3. Add your turret rig or create one with horizontal and vertically rotating parts
4. Set the *Horizontal Pivot* and *Vertical Pivot* in the inspector of the **Gimbal Controller**
5. Add a [gun weapon unit](https://vsxgames.gitbook.io/universal-vehicle-combat/weapons/broken-reference) and add it to the *Weapon Units* list in the inspector of the **Gun Weapon** component
6. If you wish the turret to acquire targets on its own, add **Tracker** and **Tracker Target Selector** components to the turret, and drag the target selector into the *Target Selector* field in the inspector of the **Gun Turret** component.

### Creating A Missile Turret

To create a missile turret:

* Create a new game object and call it 'Missile Turret'.
* Add a **Missile Turret** component, this will add **Missile Weapon**, **Gimbal Controller** and **Target Locker** components.
* Add your turret rig or create one with horizontal and vertically rotating parts
* Drag the vertical pivot of your turret into the *Locking Reference Transform* field in the inspector of the **Target Locker** component
* Set the *Horizontal Pivot* and *Vertical Pivot* in the inspector of the **Gimbal Controller**
* Add a [missile weapon unit](https://vsxgames.gitbook.io/universal-vehicle-combat/weapons/broken-reference) and add it to the *Weapon Units* list in the inspector of the **Missile Weapon** component
* If you wish the turret to acquire targets on its own, add **Tracker** and **Tracker Target Selector** components to the turret, and drag the target selector into the *Target Selector* field in the inspector of the **Missile Turret** component.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://vsxgames.gitbook.io/universal-vehicle-combat/weapons/turrets.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
