> For the complete documentation index, see [llms.txt](https://pororoca-works.gitbook.io/pororocaworks-satdoc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pororoca-works.gitbook.io/pororocaworks-satdoc/initial-setup.md).

# Initial Setup

### Setting Up a Turret

Getting started with the **Smart Auto Turrets (S.A.T.)** is fast and intuitive. You can either place a turret directly into your scene or spawn one during gameplay. Once it’s in the world, the turret will begin autonomously scanning for targets based on two simple rules: **interface detection** and **team-based filtering**.

***

#### 1. Placing the Turret

Turrets can be dropped directly into your scene or spawned during runtime. As soon as they're active, they begin evaluating potential targets in their detection radius.

***

#### 2. Target Identification – Combat Interface

Turrets identify valid targets by checking whether an actor implements a specific **Blueprint Interface**. By default, this is `BPI_CombatInterface`, but it can be easily replaced with a different interface if needed.

<figure><img src="https://3847615863-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkaMGgunVIv23Ja5Ycf23%2Fuploads%2FawpazDI1973ocacEBA4X%2FScreenshot%202025-04-11%20173033.png?alt=media&amp;token=1306f73b-77d2-4ecb-b102-6ccd811faac8" alt=""><figcaption></figcaption></figure>

Any actor that implements this interface is considered a **potential target**, pending team filtering.

***

#### 3. Team-Based Filtering

Each turret includes a `TeamName` variable — a simple string used to define its faction. The turret compares this value against **Actor Tags** on all potential targets.

If a target has an Actor Tag that **matches** the turret’s `TeamName`, it will be ignored. All others are considered valid targets and will be engaged.

This setup makes it easy to manage:

* Friendly fire prevention
* Multi-faction systems
* Dynamic targeting priorities

***

#### 4. Changing Teams at Runtime

Turrets are built to be fully adaptable. You can change a turret’s faction at runtime using the  function:

```plaintext
AC_AutoTurretStats → ChangeTeam(NewTeamName)
```

<figure><img src="https://3847615863-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkaMGgunVIv23Ja5Ycf23%2Fuploads%2FolbvfmOdstDJkD1KlVlx%2Fimage.png?alt=media&amp;token=dcc3a085-25fd-4c50-983d-4d0393995ae7" alt=""><figcaption></figcaption></figure>

Just pass in the new team name string, and the turret will **immediately update** its behavior and retarget accordingly — no need to reinitialize or restart anything.

This feature is perfect for:

* Faction-switching gameplay mechanics
* AI-controlled turret hacks
* Dynamic alliances and enemy shifts

### Exposed Variables When Spawning

When spawning a turret into your scene—either manually in the editor or dynamically during runtime—there are **three important variables** you should be aware of. These define how the turret behaves, what stats it loads, and whether it can be controlled by players.

<figure><img src="https://3847615863-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkaMGgunVIv23Ja5Ycf23%2Fuploads%2FKFqWlR9UbwarVmphwnNa%2Fimage.png?alt=media&amp;token=1157b0b8-6dfb-4c5a-8b04-1ffc9fe1caf6" alt=""><figcaption></figcaption></figure>

<figure><img src="https://3847615863-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkaMGgunVIv23Ja5Ycf23%2Fuploads%2Ftv543oPfLmqDZLwldRzo%2Fimage.png?alt=media&amp;token=a9ee6d44-fa04-4eb7-95a1-af1b8c92da5e" alt=""><figcaption></figcaption></figure>

***

#### 1. **Turret Name (Name)**

This is the most important setup variable. `Turret Name` tells the turret which entry to look for in the **DT\_TurretList** (the main DataTable that holds turret stats).

* If the name matches an entry in `DT_TurretList`, the turret will automatically **import all relevant stats**, such as damage, rate of fire, turn speed, range, projectile type, etc.
* If left blank or unmatched, the turret will **retain the manually configured values** on its own blueprint instance. This allows you to create custom turrets without relying on the DataTable if preferred.

***

#### 2. **Is Reversed (Boolean)**

If your turret is **mounted upside-down**—for example, hanging from a ceiling—you should check the `Is Reversed` boolean.

* This flips the pitch rotation logic, ensuring that the turret still **tracks and aims correctly** even when oriented downward.
* It’s a simple but essential flag for correct aiming behavior on non-standard placements.

***

#### 3. **Unpossessable (Boolean)**

This variable is useful for restricting player interaction.

* If `Unpossessable` is **true**, the turret cannot be controlled or possessed by the player.
* Ideal for purely AI-controlled defenses or decorative/emplaced units that should not be player-accessible.

***

These variables give you both flexibility and control when setting up turrets in your game, making it easy to integrate them into a variety of scenarios—from automated defenses to player-controllable artillery.
