'Under Siege 2'
Modular Sci-fi Environment
Under Siege 2
Обработка видео...
Contents:
1. Overview
2. Setup
3. Simple Gameplay (Principled)
4. Turret Fire
5. Ground
6. Drill
7. Dropper
8. Dropper's spawner, drills limit
1. Overview
'Under Siege 2' is a modular constructor (with gameplay) for creating cyberpunk sci-fi environments: station-like, tech fly islands-like etc.
Includes:
● modular sci-fi grounds;
● drill model;
● dropper (ship) model;
● 1 type animated turret (models);
● dropper gameplay: fly, search target (ground), drop paratroopers (drills);
● drill (robot) gameplay: fly, search target (ground), ground 'drilling';
● turret gameplay: search target, aim, fire;
● turret setup: fire rate, aim time, search radius (via response area);
● bullet gameplay: target hit;
● bullet setup: fly speed, damage;
● explode effect (particle based);
● drill spark effect (Unity default particle based);
● dropper, drill setup: fly speed, health (armor), damage power;
● realized gameplay a: turret fire -> enemy hit -> enemy destroy;
● realized gameplay b: find ground -> drop drills -> drilling ground;
● enemy spawner;
● utilized Unity engine physics;
● textures 4K;
● 100-5000 tris.
2. Setup
- 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 ground tile 1 and ground pillar 1, stored here: \UnderSiege2\Prefab\Ground (we use these prefabs for test)
- Put ground pillar 1 on ground tile 1, something like this:
- Make new empty gameobject (Ctrl+Shift+N)
- Add component USBTraffic on it:
- Add drill spawner ship (Dropper) prefabs from \UnderSiege2\Prefab\Vehicles to vehicle array variety
- Right click on created gameobject - create empty:
- Adjust direction for new (child) gameobject. Make sure this gameobject directs to tile and pillar prefabs.
- Something like this:
- Principled action ready. Hit play for preview.
4. Turret Fire
Turrets system is a part of 'Under Siege 1' package - included in 'Under Siege 2':
- 'Under Siege 2' contains only 1 turret;
- See chapters 3, 4, 5 of 'Under Siege 1' documentation to setup:
5. Ground
Ground system uses Unity engine physics
- Note: RigidBody for ground entity created automatically on play mode;
- Note: For your own ground entity you should add collider and USBGround.cs script on your model;
- Note: layer of any ground prefab must be = 'Ground Layer' field of 'drill' prefab (see next chapter);
- Ground Health - health / armor for current ground;
- Ground Mass - mass param for ground; this param used by physics engine via rigidbody;
- Damage Radius - param for 'drill'. When 'drill' becomes inside this radius it will start damage current ground. Use VisualizeDamgaeRadius checkbox to visulaize radius for setup (USDamageRadiusVisual.cs script attached to ground);
- Habitat Radius - something like 'life radius' for ground. Any ground prefab will be erased from scene after exceed this radius (for performance). By default It happens after eating by 'drill';
- Affect Gravity - uncheck this flag for all grounds used for 'stand, base, holders' on start play mode; check this flag for any 'free-falling' ground entity;
6. Drill
Drill system uses Unity engine physics
- Note: for your own model as 'drill' you should add collider, rigidbody (without gravity), USEnemyShip.cs and USBDrill.cs scripts
- Ground Layer - layer for target (ground entity);
- Speed - drill speed (speed param on USEnemyShip.cs is not affected);
- Damage - drill's eating power;
- Detect Radius Def - small radius for current drill (near ground targets);
- Detect Radius Big - big radius for current drill (first target search, long-range ground search)
- Note: Drill layer must be = turret bullet layer for interaction (also see bullet prefab);
- For more information about bullet see 'Under Siege 1' documentation
7. Dropper
Dropper ship is a drill's container or landing ship; It works once per its life: drops drills to ground
- Ground Layer - layer for target (ground entity);
- Detect Radius - search radius (ground entity);
- Detect Ground Rate - search radius (ground entity) refresh rate;
- Exclude Zero Child - tick this flag for your own models in case your mesh is child0 gameobject (means child0 not a drill spawn point)
- Note: for your own models make any count of children gameobjects for your Dropper; each child gameobject = spawn point for drill landing; count of children gameobjects = count of drills for current Dropper
8. Dropper's spawner, drills limit
- Max Droppers Count - max count of Droppers in current scene;
- Max Drills Count - max count of drills in current scene;
- Max Drills Prtcls - max count of sparks effects for drills in scene;
- Min/Max Spawn Interval - in seconds; for Droppers only