remove chunk size - it's always 10% of wave size

This commit is contained in:
Ian Woods 2026-06-23 21:42:01 -07:00
parent f301d7ade9
commit 54f11d91ff
2 changed files with 2 additions and 7 deletions

View file

@ -17,12 +17,7 @@ namespace TD.Gameplay
[Tooltip("How many enemies of this type to spawn.")]
public int Count;
[Tooltip("How many enemies spawn per burst. 1 (default) = original one-at-a-time " +
"behaviour. Values > 1 spawn that many simultaneously before waiting SpawnInterval.")]
public int ChunkSize;
[Tooltip("Seconds between each burst. With ChunkSize > 1 this is the pause between " +
"groups rather than between individual enemies.")]
[Tooltip("Seconds between each burst. Enemies spawn in bursts of 10% of Count at a time.")]
public float SpawnInterval;
}

View file

@ -336,7 +336,7 @@ namespace TD.Gameplay
{
if (entry.EnemyType == null || entry.Count <= 0) continue;
int chunkSize = Mathf.Max(1, entry.ChunkSize);
int chunkSize = Mathf.Max(1, Mathf.RoundToInt(entry.Count * 0.1f));
for (int i = 0; i < entry.Count; i += chunkSize)
{
int burst = Mathf.Min(chunkSize, entry.Count - i);