Пример #1
0
        internal static Action LocalizeGps(string name, string description)
        {
            MyStringId nameID;
            MyStringId descriptionID;

            string _name        = name;
            string _description = description;

            if (MyStringId.TryGet(name, out nameID))
            {
                _name = VRage.MyTexts.Get(nameID).ToString();
                //                ModLog.Info("Found GPS localization for " + name+ " as:" + _name);
            }
            else
            {
                ModLog.Info("No name found for GPS:" + name);
            }
            if (MyStringId.TryGet(description, out descriptionID))
            {
                _description = VRage.MyTexts.Get(descriptionID).ToString();
                //                ModLog.Info("Found GPS localization for " + description + " as:" + _description);
            }

            return(() => { DuckUtils.RenameGPS(name, _name, _description); });
        }