'Under Siege'

Modular Sci-fi Environment
Under Siege (Unity)

Обработка видео...


1. Overview
2. Setup
3. Simple Gameplay (Principled)
4. Response Area
5. Turrets
6. Bullets
7. Enemies
8. Layers
9. Enemy spawner

1. Overview

'Under Siege' is a modular constructor (with gameplay) for creating cyberpunk sci-fi environments: station-like, tech fly islands-like etc.


  • modular sci-fi grounds double sided;
  • sci-fi props variety;
  • 5 types animated turrets (models);
  • 2 types enemies (models);
  • turret gameplay: search target, aim, fire;
  • turrets setup: fire rate, aim time, search radius (via response area);
  • bullet gameplay: target hit;
  • bullet setup: fly speed, damage;
  • explode effect (particle based);
  • enemy gameplay: direct fly from spawner;
  • enemy setup: fly speed, health (armor);
  • realized gameplay: turret fire -> enemy hit -> enemy destroy;
  • red-hot turret barrel effect (long fire time makes red-hot turret barrel; idle - cold barrel);
  • colorful bullets (see video preview);
  • enemy spawner;
  • utilized Unity engine physics;
  • textures 4K;
  • 100-5000 tris;
  • LOD's.

2. Setup

  • Click download package via your Asset Store;
  • Import to any project:

- 3d template (not Hdrp, not Universal) via Unity Hub with postprocessing effects out of the box:
- open demo scene;
- hit play.
- any other template (SRP's):
- select all materials in Materials folder, click Edit > Render Pipeline > Upgrade selected materials to your SRP;
- add default postprocessing module for your SRP;
- open demo scene;
- hit play.

3. Simple Gameplay (Principled)

In order to make gameplay (out of the box) you should:

  • Drag and drop to your own scene prefab Response Area, stored here: \UnderSiege\Prefab\_System
  • Drag and drop any turret (Turret3 for example) from \UnderSiege\Prefab\_Turret
  • Turret must be placed inside Response Area wire sphere
  • Make new empty gameobject (Ctrl+Shift+N)
  • Add component USTraffic on it:

  • Add Enemy prefabs from \UnderSiege\Prefab\_Enemy to vehicle array variety
  • Right click on created gameobject - create empty:

  • Adjust direction for new (child) gameobject. Make sure this gameobject directs to response area wire sphere.
  • Something like this:

  • Principled action ready. Hit play for preview.

4. Response Area

Response Area prefab is a primary service gameobject for turrets and for enemy ships. Details:

  • Any turret must be placed inside ResponseArea wire sphere for correct working;
  • Any enemy ship fly through Response Area becomes a target of a turret (random order for multi targets);
  • Response areas may be overlapped. Response order by internal Unity engine calculations.
  • Params:

  • Enemy Layer - all enemy ships must belong to this layer;
  • Turret Layer - all turrets must belong to this layer;
  • Trigger Sphere Radius - response area trigger radius;
  • Collect Rate - enemy targets detect update rate (in seconds). No need to change this param in most cases.

5. Turrets

There are 5 turrets types (models):

  • Down Turret - tick for bottom turret placement;
  • Aim speed - movement speed for turrets heads (look at current target);
  • Fire Rate - fire speed in seconds (lower values = faster);
  • Bullet - bullet prefab (no need to change by default).

  • Emissive String - replace with '_EmissiveColor' for HDRP usage.

6. Bullets

There are some bullets for turrets types:

  • Abs Life Time - absolute life time for gameogject. After that will be erased from scene;
  • Speed - bullet speed;
  • Damage - bullet power;
  • Interact Layer - layer for target (enemy ship).

7. Enemies

There are 2 types of enemies (models):

  • Health - health (armor) for the ship;
  • Speed - movement speed;
  • Abs Life Time - absolute life time for actor. After that will be erased from scene.

8. Layers

  • set response layer for turret and for enemy ship;
  • see Response Area prefab:

9. Enemy spawner

  • Make new empty gameobject (Ctrl+Shift+N)
  • Add component USTraffic on it
  • Add Enemy prefabs from \UnderSiege\Prefab\_Enemy to vehicle array variety
  • Right click on created gameobject - create empty (child) = spawn point
  • Duplicate child gameobject - adjust position and rotation
  • All children gameobjects = spawn points.

  • maximum vehicle in scene - maximum count of enemy gameobjects;
  • spawn frequency min/max time - enemy spawn freq. in seconds;
  • start position scatter - scatter position for new enemy ship;
  • vehicle variety array - add here enemy prefabs (for your own custom refabs: each prefab must contain: USEnemyShip.cs script, collider, game object layer = Response Area enemy layer);
  • speed variety - enemy speed scatter.