void Load(JObject jObject) { foreach (var child in jObject.Properties()) { var element = LocalizedPhrase.Load(child); Dictionary.Add(child.Name, element); } }
public virtual void Init() { Phrase = Localization.Phrases.Find(ID); if (Phrase == null) { Debug.LogWarning("No localization found for " + ID + ", please add"); } }
public static LocalizedPhrase Load(JProperty property) { var dictionary = new Dictionary <string, string>(StringComparer.OrdinalIgnoreCase); foreach (var child in property.Value.Children <JProperty>()) { dictionary.Add(child.Name, child.Value.ToObject <string>()); } var phrase = new LocalizedPhrase(dictionary); return(phrase); }
protected override void Start() { Phrase = Localization.Phrases.Find(ID); base.Start(); }