public sealed class SpawnerOne camp: what is alive, and what is due back.
Remarks
⚠ It says what to spawn and never where. Placing something needs the scene and a navigation mesh, and a spawner that owned those would be a second one — the boundary every library in this framework sits on.
⚠ A respawn timer starts when something dies, not on the tick that notices. A server that fell behind would otherwise repopulate faster than one that did not, which is a difference players feel and nobody can explain.
⚠ The cap counts what is alive, not what has been spawned. Counting spawns makes a camp that has been cleared twice permanently empty.
Fields and properties (4)
public SpawnTable TableWhat lives here.
public int AliveHow many are alive.
public int FreeHow many could still be.
public bool IsFullWhether it is full.
Methods (5)
public Spawner(SpawnTable table, ulong seed)Makes one, empty and due immediately.
public int Tick(float now, ICollection<SpawnOrder> into)Puts back whatever is due, and says what to make.
public bool Died(int slot, float now)Says something died.
public void Reset(float now)Clears everything and makes it all due at once. What a reset does.
public float DueAt(int slot)When a slot is due back.
Used by (2)
- WorldSpawnsMmo.Realm
- SpawnTestsVixen.Gameplay.Ai.Tests