void Update() { if (generateUMA) { umaCrowdSize = Vector2.one; int randomResult = Random.Range(0, 2); GenerateOneUMA(randomResult); generateUMA = false; generateLotsUMA = false; } if (generateLotsUMA) { if (generator.IsIdle()) { int randomResult = Random.Range(0, 2); GenerateOneUMA(randomResult); } } if (stressTest && generator.IsIdle() && !generateLotsUMA && !generateUMA) { RandomizeAll(); } }
void Update() { if (generateLotsUMA) { if (generator.IsIdle()) { GenerateOneUMA(); umaData.OnCharacterUpdated += new System.Action <UMAData>(umaData_OnUpdated); X = X + 1; if (X >= umaCrowdSize.x) { X = 0; Y = Y + 1; } if (Y >= umaCrowdSize.y) { generateLotsUMA = false; X = 0; Y = 0; } } } if (generateUMA) { GenerateOneUMA(); generateUMA = false; } }
void Update() { if (generateUMA) { umaCrowdSize = Vector2.one; int randomResult = Random.Range(0, 2); GenerateOneUMA(randomResult); generateUMA = false; generateLotsUMA = false; } if (generateLotsUMA) { if (generator.IsIdle()) { if (allAtOnce) { for (int i = 0; i < umaCrowdSize.x * umaCrowdSize.y; i++) { int randomResult = Random.Range(0, 2); GenerateOneUMA(randomResult); generateUMA = false; generateLotsUMA = false; } } else { int randomResult = Random.Range(0, 2); GenerateOneUMA(randomResult); } } } if (stressTest && generator.IsIdle() && !generateLotsUMA && !generateUMA) { RandomizeAll(); } }
void Update() { if (generator.IsIdle()) { if (generating) { GenerateOneCharacter(); } else if (stressTest) { RandomizeAll(); } } }