Пример #1
0
 internal static EmoteDefinition GetEmoteFromCharacter(char characterCode)
 {
     if (characterCodesToDefinitions.ContainsKey(characterCode))
     {
         EmoteDefinition emoteDefinition = characterCodesToDefinitions[characterCode];
     }
     return(characterCodesToDefinitions[characterCode]);
 }
Пример #2
0
        public static string GetToken(char emoteChar)
        {
            EmoteDefinition emoteDefinition = GetEmoteDefinition(emoteChar);

            if (emoteDefinition != null)
            {
                return(emoteDefinition.Token);
            }
            return(null);
        }
Пример #3
0
        public static EmoteDefinition[] GetEmoteDefinitionsFromMessage(string message)
        {
            List <EmoteDefinition> list = new List <EmoteDefinition>();

            foreach (char c in message)
            {
                if (IsEmoteCharacter(c))
                {
                    EmoteDefinition emoteDefinition = GetEmoteDefinition(c);
                    if (emoteDefinition != null)
                    {
                        list.Add(emoteDefinition);
                    }
                }
            }
            return(list.ToArray());
        }
Пример #4
0
 public static char GetEmoteChar(EmoteDefinition emoteDefinition)
 {
     return(Convert.ToChar(emoteDefinition.CharacterCode));
 }
Пример #5
0
 public static string GetEmoteString(EmoteDefinition emoteDefinition)
 {
     return(GetEmoteChar(emoteDefinition).ToString());
 }