Gunner
What it is
A close-range hitscan enemy from the city set. Tagged mechanical. Drives toward the player in a soldier-march cadence (alternating short move/pause segments), gets within engagement range, then charges a telegraphed shot and fires a short burst of instant-damage hitscan beams. Hitscan deals no projectile entity — damage applies the moment the burst fires. Damage is boosted against shields and reduced against raw hull HP.
The gunner is one of the two staple enemies for the city set (paired with the racer) and appears most heavily on city-themed planets.
Stats (per rarity tier)
Base stats are multiplied by the rarity multipliers shared across all enemies. Damage shown is the per-hit weapon damage before shield/HP modifier.
| Rarity | HP | Speed | Radius | XP | Per-hit damage |
|---|---|---|---|---|---|
| Common | 8.1 | 88.2 | 3.75 | 45 | 9 |
| Uncommon | 14.85 | 92.61 | 4.3125 | 90 | 13.5 |
| Rare | 20.79 | 98.91 | 4.875 | 180 | 19.8 |
| Epic | 29.7 | 105.84 | 5.25 | 270 | 25.2 |
| Legendary | 35.64 | 114.66 | 5.625 | 360 | 31.5 |
Base values before rarity scaling: HP 3, Speed 63, Radius 3.75, XP 15, Weapon damage 3.
Behavior
Movement. When not aggroed, drifts with idle friction. Once aggroed, alternates between a move phase and a pause phase like a soldier marching forward:
| Phase | Duration |
|---|---|
| Move | 0.6 s |
| Pause | 0.25 s |
During the move phase, if the gunner is outside hitscan range it steers toward the player like a car (turn-rate 0.7); if already in range, it coasts forward with soft friction rather than over-committing. The pause phase always coasts with soft friction and no steering. While firing or charging, the gunner holds position with hard friction; while firing specifically, it also applies a small recoil pushback (40 units/sec² of acceleration away from the player) for the duration of the burst.
Combat loop. Range, burst count, and burst cooldown come from the entity definition; values below are the base gunner’s. Engagement range (where the gunner decides to attack) is separate from hitscan range (the per-hit reach).
| Parameter | Value |
|---|---|
| Hitscan range | 65 |
| Engagement range | 100 |
| Charge-up duration | 1.2 s |
| Burst count | 3 shots |
| Interval between shots in burst | 0.15 s |
| Burst cooldown (after full burst) | 2.5 s |
| Burst cooldown (cancelled on dodge) | 0.75 s (0.3× of 2.5) |
| Burst cooldown (early-game skip) | 1.25 s (0.5× of 2.5) |
| Cooldown tick rate when out of range | 0.5× normal |
Sequence:
- Approach the player using the march cadence.
- When inside engagement range, start charging. A red circle forecast spawns at the gunner’s position, radius equal to 30% of engagement range, lasting the full 1.2 s charge.
- If the player leaves 1.1× engagement range during charge, cancel and enter the dodge cooldown (0.75 s). Forecast is removed.
- Once charge completes, fire the burst: one shot per 0.15 s. Each shot applies damage instantly and spawns a short-lived hitscan line VFX (0.08 s) from the gunner to a small random scatter around the player position.
- If the player leaves 1.2× engagement range mid-burst, fizzle and enter dodge cooldown.
- After a full burst, enter the full burst cooldown (divided by the player’s attack-speed multiplier, if any).
Damage modifier. Each hit’s base weapon damage (3 per shot, before rarity damage scaling) is multiplied by 1.5 when applied to the player. The framing is +50% damage to shield, -70% damage to HP — the gunner exists to chew through shields quickly and stall out against raw hull.
Early-game softener. During the first 60 seconds of a mission, the gunner only attempts to attack on 20% of cooldown checks; the other 80%, it sets a half cooldown and skips. After 60 s, every cooldown completion triggers an attack attempt.
State flags. Stunnable and knockbackable. Uses shared separation, but not the shared attack FSM or shared aggro system. Smart-range (for FSM-style decisions in other systems) is 200.
On death. Cancels any in-flight firing/charging state and clears all owned forecasts and hitscan lines.
Tier scaling
Rarity tier applies multiplicatively to the base stats on top:
| Rarity | HP × | XP × | Speed × | Radius × | Damage × |
|---|---|---|---|---|---|
| Common | 2.7 | 3.0 | 1.40 | 1.0 | 3.0 |
| Uncommon | 4.95 | 6.0 | 1.47 | 1.15 | 4.5 |
| Rare | 6.93 | 12.0 | 1.57 | 1.3 | 6.6 |
| Epic | 9.9 | 18.0 | 1.68 | 1.4 | 8.4 |
| Legendary | 11.88 | 24.0 | 1.82 | 1.5 | 10.5 |
These multipliers are shared across every enemy archetype, not gunner-specific. Burst count, burst cooldown, charge duration, engagement range, and shield/HP modifiers do not scale with rarity — only HP, speed, radius, XP, and per-hit damage do.
The rarity also drives the polygon stroke color: grey (common), green (uncommon), blue (rare), purple (epic), orange (legendary).