1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
  | using System.Collections.Generic; 
 |  using UnityEngine; 
 |  using LitJson; 
 |    
 |  public partial class RichTextMsgReplaceConfig : ConfigBase<int, RichTextMsgReplaceConfig> 
 |  { 
 |      private static Dictionary<string, RichTextMsgReplaceConfig> m_ReplaceCfgs = new Dictionary<string, RichTextMsgReplaceConfig>(); 
 |    
 |      protected override void OnConfigParseCompleted() 
 |      { 
 |          m_ReplaceCfgs.Add(StringUtility.Contact(Identification, Number).ToString(), this); 
 |      } 
 |    
 |      public static string GetRichReplace(string identify, int number) 
 |      { 
 |          RichTextMsgReplaceConfig replace = null; 
 |          m_ReplaceCfgs.TryGetValue(StringUtility.Contact(identify, number).ToString(), out replace); 
 |          if (replace != null) 
 |          { 
 |              return replace.Content; 
 |          } 
 |          return string.Empty; 
 |      } 
 |  } 
 |  
  |