private void Awake() { if (instance == null) { instance = this; InitMacros(); } else { Destroy(gameObject); } }
void Awake() { if (main == null) { main = this; } macro_map = new Dictionary <string, MacroSubDel> { { "name", macroNameSub }, { "NAME", macroNameSub }, { "pronoun", macroPronoun }, { "info", macroInfo }, { "i", macroInfo }, { "last-cast", macroLastCast }, { "last-cast-enemy", macroLastCastEnemy }, { "time", macroTime }, { "c", macroColor }, { "t", macroSetTalkSfx }, { "h", macroHighlightCharacter }, { "hc", macroHighlightCodec }, { "speak", macroSpeaker }, { "tl", macroTranslate }, { "translate", macroTranslate }, { "languageTL", macroTranslatedLanguage }, { "rc", macroRemoveCharacter } }; color_map = new Dictionary <string, string> { { "spell", "#ff6eff" }, { "ui-terms", "#05abff" }, { "evil-eye", "#ff0042" }, { "enemy-talk", "#974dfe" }, { "enemy-name", "#16e00c" }, { "tips", "#ffdb16" }, { "whisper", "#c8c8c8" }, { "highlight", "#ff840c" }, { "mc", "#d043e2" }, { "illyia", "#c70126" }, { "dahlia", "#8097e0" }, { "doppel", "#E0015A" } }; character_map = new Dictionary <string, Pair <string, string> > { { "dahlia", new Pair <string, string>("dahlia", "vo_dahlia") }, { "illyia", new Pair <string, string>("illyia", "vo_illyia") }, { "mackey", new Pair <string, string>("mackey", "vo_mackey") }, { "mc", new Pair <string, string>("_mc_", "vo_mc") }, { "doppelganger", new Pair <string, string>("doppelganger", "vo_doppelganger") }, { "clarke", new Pair <string, string>("clarke", "vo_clarke") }, { "iris", new Pair <string, string>("iris", "vo_iris") }, { "cat", new Pair <string, string>("cat", "vo_cat") }, { "cat_person", new Pair <string, string>("cat_person", "vo_cat_person") }, { "evil_eye", new Pair <string, string>("evil_eye", "vo_evil_eye") }, { "marcel", new Pair <string, string>("marcel", "vo_marcel") } }; translate_map = new Dictionary <char, char> { { 'a', 'e' }, { 'b', 'd' }, { 'c', 'k' }, { 'd', 'b' }, { 'e', 'i' }, { 'f', 'h' }, { 'g', 'h' }, { 'h', 'f' }, { 'i', 'a' }, { 'j', 'z' }, { 'k', 'x' }, { 'l', 't' }, { 'm', 'l' }, { 'n', 'v' }, { 'o', 'u' }, { 'p', 'g' }, { 'q', 'n' }, { 'r', 'w' }, { 's', 'y' }, { 't', 'm' }, { 'u', 'o' }, { 'v', 'r' }, { 'w', 'p' }, { 'x', 'c' }, { 'y', 's' }, { 'z', 'j' }, { '.', ',' }, { ',', '.' } }; }