Tower Defense Starter Kit Tutorial: How to Create New Towers (v3.0)

This tutorial is based on the v3.0 edition of Tower Defense Starter Kit. For the v2.x workflow, refer to the previous tutorial here: https://unrealpossibilities.blogspot.com/2023/07/this-tutorial-is-based-on-v2.html

1. Start by creating a new child blueprint based on BP_Tower_Base.

2. Open the new tower blueprint and set a custom static mesh for the tower body. 

If the tower has a separate turret, attach the turret static mesh to the TurretAimControl component. Add an Arrow component and attach it to the turret static mesh, positioning it at the location the tower fires from.

Once the arrow component is in place, extend the RetrieveMuzzleComponents interface function on the tower blueprint and return it as an array, as shown in the screenshot below.

3. The next step is to create a tower core component for the new tower. Create a new blueprint component and derive it from one of the five distinct functional tower core types. The type to derive from depends on the behavior of the tower.

  • C_TowerCore_SingleTargetLock is the right choice for towers that lock on to and engage one target at a time.
  • C_TowerCore_MultiTargetLock works the same way but tracks and engages multiple targets simultaneously up to a configured maximum.
  • C_TowerCore_AoEPulse does not track individual targets at all, instead hitting everything within range with each periodic pulse.
  • C_TowerCore_ProximityTrigger is suited for towers that apply a persistent effect to anything within range and revert it when that target leaves, making it the go to type for support and utility towers.
  • C_TowerCore_NonTargeting is for towers that operate entirely independently of the targeting system, running on their own schedule regardless of what is or isn't in range.

For more details on the tower core architecture, refer to this post: https://unrealpossibilities.blogspot.com/2026/04/tower-defense-starter-kit-v30-dev-log-2.html

4. With the tower core created, override the PerformAction function and implement the firing logic here. This is where the actual behavior of the tower lives, whether that is a line trace, a projectile spawn, an area damage application, or anything else.

For ProximityTrigger cores specifically, override ApplyActionToTarget and RevertActionOnTarget instead, since those are called when a target enters and leaves range respectively.

5. Set the FiringTrajectory variable on the tower core to the appropriate trajectory type for the tower's attack. The system uses this to check that a valid path to the target exists before firing.

6. Open ETowerModels and add a new entry for the new tower.

7. Open DT_TowerData, add a new row for the tower and fill in the following parameters:

Basic Info:

  • SpawnClass: The tower blueprint class to spawn when this tower is placed
  • TowerModel: The enum entry for this tower in ETowerModels
  • SetupCost: The currency cost to build this tower
  • SellingPrice: The amount refunded when the tower is sold
  • Name: The display name of the tower
  • ShortDescription: A brief description of the tower shown in the in game info panel
  • LongDescription: A detailed description of the tower shown in the tower loadout selection menu
  • UIImage: The thumbnail image used in the UI
  • UpgradesTo: The ETowerModels enum entry for the tower this upgrades into
  • bCanLevelUp: Enable if the tower can gain XP and level up

Tower Core:

  • TowerCoreClass: The blueprint component class that defines the behavior of this tower's core
  • TowerCoreStats: A map of Gameplay Tag and Float value pairs that define the stats for this tower core, such as damage, range, cooldown, and any other stats relevant to the tower core type being used
  • TowerCoreFX: VFX and SFX assets mapped to the muzzle, fire, and impact slots
  • CorePayload: Set the TowerCorePayload class, which can hold a projectile class, battle unit data table row reference, or deployable class depending on what the tower core requires

HP Stats:

  • HPStats: A map of Gameplay Tag and Float value pairs defining the tower's health stats

Info Display:

  • StatsDisplayInfo: An array of Struct_StatDisplayEntry that defines which stats are shown in the UI, how they are labeled, and the order in which they appear

8. Finally, select BP_TowerManager in the level and add the new tower enum entry to its DefaultTowerLoadout array from the Details panel.


 

That covers everything needed to get a new tower up and running in v3.0. The UI, stats display, and targeting behavior are all handled automatically based on the data table configuration and the tower core type used. As shown in the screenshots below, the new tower should now be available in the loadout menu and fully operational in game.

 

Comments