示例#1
0
        public static bool RegisterCommand(string str, ILooneCommand cmd)
        {
            if (commands.ContainsKey(str))
            {
                return(false);
            }

            commands.Add(str, cmd);
            return(true);
        }
示例#2
0
 public static bool TryGetCommand(string str, out ILooneCommand cmd)
 {
     return(commands.TryGetValue(str, out cmd));
 }