TryGetValue(string poolName, out SpawnPool spawnPool) returns: bool Description Returns true if PoolManager.Pools contains a SpawnPool with the given name and also sets the out value as a reference to the SpawnPool. SpawnPool spawnPool; if (!PoolManager.Pools.TryGetValue("Foos", out spawnPool)) { Debug.log("A 'Foos' pool does NOT exist!"); return; } Debug.log("A 'Foos' pool was found: " + spawnPool.group.name); |