private void ManageBirds(ref float time, ref float deltaTime) { bool motherIsMoving = mother.IsMoving; for (int i = 0; i < babies.Length; i++) { Baby baby = babies[i]; if (baby.IsFrightened) { baby.FrightendRoutine(ref deltaTime); } else { if (motherIsMoving) { //The split is weird, also weird method names baby.CheckForKinDistance(ref deltaTime); baby.GoTowardsKin(ref deltaTime); } else { baby.IdleRoutine(ref time, ref deltaTime); } } } }