예제 #1
0
        /// <summary>
        /// Проверяет доступность тиммейта
        /// </summary>
        public static bool IsAvailable(TeammateType type)
        {
            var teammate = PlayerManager.Data.Team.TeammatesArray
                           .First(e => e.Type == type);

            return(teammate.IsEmpty == false && teammate.HasPayment);
        }
예제 #2
0
        /// <summary>
        /// Устанавливает время отдыха указанному тиммейте
        /// </summary>
        public static void SetTeammateCooldown(TeammateType type, int cooldown)
        {
            var teammate = Data.Team.TeammatesArray.First(e => e.Type == type);

            teammate.Cooldown = cooldown;
        }
예제 #3
0
파일: Teammate.cs 프로젝트: Mispon/rap-way
 public static Teammate New(TeammateType type) => new Teammate
 {
     Type = type
 };
예제 #4
0
 /// <summary>
 /// Возвращает информацию о тиммейте
 /// </summary>
 private TeammateInfo GetInfo(TeammateType type)
 {
     return(teammateInfos.First(e => e.Type == type));
 }