Esempio n. 1
0
        public static bool RegisterCommand(string name, IGunGameCommand command)
        {
            if (!commands.ContainsKey(name))
            {
                commands.Add(name, command);
                return(true);
            }

            return(false);
        }
Esempio n. 2
0
 public static bool HasGGPermissionFor(this IRocketPlayer player, IGunGameCommand command)
 {
     return((byte)command.PermissionLevel <= (byte)((UnturnedPlayer)player).GunGamePlayer().pLevel);
 }
Esempio n. 3
0
 public static bool TryGetCommand(string key, out IGunGameCommand cmd)
 {
     return(commands.TryGetValue(key.ToLowerInvariant(), out cmd));
 }