Esempio n. 1
0
        private static string TryGetString(string fqn, GomObjectData textRetriever)
        {
            string locBucket  = textRetriever.ValueOrDefault <string>("strLocalizedTextRetrieverBucket", null);
            long   strId      = textRetriever.ValueOrDefault <long>("strLocalizedTextRetrieverStringID", -1);
            string defaultStr = textRetriever.ValueOrDefault <string>("strLocalizedTextRetrieverDesignModeText", String.Empty);

            if ((locBucket == null) || (strId == -1))
            {
                return(defaultStr);
            }

            StringTable strTable = null;

            try
            {
                strTable = StringTable.Find(locBucket);
            }
            catch
            {
                strTable = null;
            }

            if (strTable == null)
            {
                return(defaultStr);
            }

            string result = strTable.GetText(strId, fqn);

            return(result ?? defaultStr);
        }
Esempio n. 2
0
 static AreaLoader()
 {
     strTable = StringTable.Find("str.sys.worldmap");
 }
Esempio n. 3
0
 static CrewSkill()
 {
     fqnMap    = new Dictionary <Profession, CrewSkill>();
     nameTable = StringTable.Find("str.prf.professions");
 }
Esempio n. 4
0
 static SchematicLoader()
 {
     missionStrTable = StringTable.Find("str.prf.missions");
 }
Esempio n. 5
0
 static ClassSpecLoader()
 {
     classNames = StringTable.Find("str.gui.classnames");
     idMap      = new Dictionary <ulong, Models.ClassSpec>();
     nameMap    = new Dictionary <string, Models.ClassSpec>();
 }
Esempio n. 6
0
 static PackageAbilityLoader()
 {
     strTable = StringTable.Find("str.abl.player.skill_trees");
 }
Esempio n. 7
0
 static MapNoteLoader()
 {
     taxiTerminals = StringTable.Find("str.tax.terminals");
 }
Esempio n. 8
0
 static ItemSetLoader()
 {
     strTable = StringTable.Find("str.itm.setbonuses");
 }
Esempio n. 9
0
 static AdvancedClassLoader()
 {
     classNames = StringTable.Find("str.gui.classnames");
 }
Esempio n. 10
0
        public static string GetName(long id)
        {
            StringTable st = StringTable.Find("str.itm.modifiers");

            return(st.GetText(nameOffset + id, "whatever"));
        }
Esempio n. 11
0
 static CompanionLoader()
 {
     strTable = StringTable.Find("str.sys.worldmap");
 }