LootHelper
A static class in Root.Township, Alta.Loot.
Static helper that fills a set of pickup docks with random loot for a biome and prosperity. Server side; used by GeneratedLoot and LootModule.
- Listed in World generation
Methods
| Member | What it is |
|---|---|
static bool Spawn(SpawnData spawnData, IEnumerable<PickupDock> targets, float incrementingFailChance) | Empties the docks, then picks random empty docks and spawns loot from the biome's loot tables until all are filled or a growing fail chance stops it. Returns true if anything spawned. |
2 private and internal methods
| Member | What it is |
|---|---|
private static void HandleFail(Pickup pickup, PickupDock dock) | Moves a pickup that failed to dock to the dock's position and destroys it. |
private static bool Spawn(Item item, PickupDock dock, INetworkScene scene, SpawnData spawnData, int count) | Empties the docks, then picks random empty docks and spawns loot from the biome's loot tables until all are filled or a growing fail chance stops it. Returns true if anything spawned. |