using UnityEngine; namespace UnityAtoms.Extensions { public static class ArrayExtensions { public static T GetRandom(this T[] array) { if (array == null || array.Length <= 0) { return default(T); } return array[Random.Range(0, array.Length)]; } } }