Updating HUD, Gold Config, and finishing off Play flow for 9player map.

This commit is contained in:
Matt F 2026-05-22 12:18:23 -07:00
parent a7be12fa9b
commit 3dcc0e7edd
28 changed files with 2272 additions and 9601 deletions

View file

@ -109,6 +109,22 @@ namespace TD.Gameplay
return playerCount <= map.PlayerCount;
}
/// <summary>
/// True if any registered map's <see cref="LevelData.SceneName"/> matches the given
/// scene name. Used by components on the persistent Player Prefab
/// (e.g. <c>PlayerBuilderSpawner</c>) to recognize "we just entered a match scene"
/// without hardcoding individual scene names. Empty/null inputs return false.
/// </summary>
public bool ContainsScene(string sceneName)
{
if (string.IsNullOrEmpty(sceneName)) return false;
for (int i = 0; i < validatedMaps.Count; i++)
{
if (validatedMaps[i].SceneName == sceneName) return true;
}
return false;
}
// ----- Lifecycle --------------------------------------------------
// Validated subset of the inspector array; built once in Awake and never mutated.