![]() |
Runtime Spawner 1.3.0
Generic Runtime spawn and instance pooling system for spawning random AI agents around a map. Works with ANY AI system easily.
|
Global configuration for the Spawn Hints system. More...
Public Attributes | |
bool | hintOnly = false |
If true, spawns will ONLY use EnemySpawnHintPoint. If no suitable hint is found, the placement is skipped (no sampler fallback). | |
bool | ignoreGlobalMinDistance = true |
When true, the locator ignores the spawner’s global “Min Spawn Range” for hint evaluation. Useful when your hints are intentionally closer than the global minimum. | |
float | cellSize = 16f |
Bucket size (meters) for the registry’s spatial hash grid. Larger cells = fewer buckets, smaller cells = tighter queries. | |
float | waveSearchPadding = 4f |
Extra meters added around a Wave’s range when searching nearby hints. | |
float | regionSearchPadding = 4f |
Extra meters added around a Region’s bounds when searching nearby hints. | |
float | globalSearchFraction = 0.75f |
Fraction of the spawner’s Cull Distance used to form the global hint search radius. | |
float | navSampleMaxDist = 35f |
Maximum search distance for NavMesh.SamplePosition(Vector3, out NavMeshHit, float, int) when snapping a hint to the NavMesh. | |
LayerMask | losBlockMask = ~0 |
Physics layers that block line of sight between player and candidate. Used when a hint has “deny line of sight” enabled. | |
float | reservationSeconds = 1.0f |
Soft cooldown per hint so consecutive spawns don’t all land on the same point. | |
bool | preferScopedFirst = true |
If true, prefer hints that are inside a “local scope” (Wave/Region) before searching globally. | |
int | maxHintAttempts = 16 |
Upper bound on how many hint candidates are evaluated per query before giving up (or falling back). | |
bool | debugLogs = false |
If enabled, prints detailed logs about hint acceptance/rejection and fallback behavior. | |
Global configuration for the Spawn Hints system.
Assigned on the RuntimeSpawner (Inspector or via RuntimeSpawner.Locator/ISpawnLocator.ConfigureHints) to control how EnemySpawnHintPoint are searched, validated, and temporarily reserved during placement.
The settings are consumed by SpawnHintRegistry and the locator’s hint query path. Typical workflow:
float MegaCrush.Spawner.SpawnHintSettings.cellSize = 16f |
Bucket size (meters) for the registry’s spatial hash grid. Larger cells = fewer buckets, smaller cells = tighter queries.
bool MegaCrush.Spawner.SpawnHintSettings.debugLogs = false |
If enabled, prints detailed logs about hint acceptance/rejection and fallback behavior.
float MegaCrush.Spawner.SpawnHintSettings.globalSearchFraction = 0.75f |
Fraction of the spawner’s Cull Distance used to form the global hint search radius.
bool MegaCrush.Spawner.SpawnHintSettings.hintOnly = false |
If true, spawns will ONLY use EnemySpawnHintPoint. If no suitable hint is found, the placement is skipped (no sampler fallback).
bool MegaCrush.Spawner.SpawnHintSettings.ignoreGlobalMinDistance = true |
When true, the locator ignores the spawner’s global “Min Spawn Range” for hint evaluation. Useful when your hints are intentionally closer than the global minimum.
LayerMask MegaCrush.Spawner.SpawnHintSettings.losBlockMask = ~0 |
Physics layers that block line of sight between player and candidate. Used when a hint has “deny line of sight” enabled.
int MegaCrush.Spawner.SpawnHintSettings.maxHintAttempts = 16 |
Upper bound on how many hint candidates are evaluated per query before giving up (or falling back).
float MegaCrush.Spawner.SpawnHintSettings.navSampleMaxDist = 35f |
Maximum search distance for NavMesh.SamplePosition(Vector3, out NavMeshHit, float, int) when snapping a hint to the NavMesh.
bool MegaCrush.Spawner.SpawnHintSettings.preferScopedFirst = true |
If true, prefer hints that are inside a “local scope” (Wave/Region) before searching globally.
float MegaCrush.Spawner.SpawnHintSettings.regionSearchPadding = 4f |
Extra meters added around a Region’s bounds when searching nearby hints.
float MegaCrush.Spawner.SpawnHintSettings.reservationSeconds = 1.0f |
Soft cooldown per hint so consecutive spawns don’t all land on the same point.
float MegaCrush.Spawner.SpawnHintSettings.waveSearchPadding = 4f |
Extra meters added around a Wave’s range when searching nearby hints.