Exemple #1
0
 public static void LoadSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     Herb = pIniManager.GetBoolean("Flying", "Herb", true);
     Mine = pIniManager.GetBoolean("Flying", "Mine", true);
     ApproachModifier = (float) Convert.ToDouble(pIniManager.GetString("Flying", "ApproachModifier", "0"));
     MaxUnits = pIniManager.GetString("Flying", "MaxUnits", "2");
     StopOnDeath = pIniManager.GetBoolean("Flying", "StopOnDeath", false);
     StopHarvestWithPlayerAround = pIniManager.GetBoolean("Flying", "StopHarvest", true);
     AvoidPlayers = pIniManager.GetBoolean("Flying", "AvoidPlayers", true);
     AutoBlacklist = pIniManager.GetBoolean("Flying", "AutoBlacklist", false);
     StopOnFullBags = pIniManager.GetBoolean("Flying", "StopOnFullBags", false);
     AvoidElites = pIniManager.GetBoolean("Flying", "AvoidElites", true);
     FindCorpse = pIniManager.GetBoolean("Flying", "FindCorpse", true);
     WaitForLoot = pIniManager.GetBoolean("Flying", "WaitForLoot", true);
     WaitForRessSick = pIniManager.GetBoolean("Flying", "WaitForRessSick", false);
     FlyingMountBar = pIniManager.GetString("Flying", "FlyingMountBar", "2");
     FlyingMountKey = pIniManager.GetString("Flying", "FlyingMountKey", "2");
     Profile = pIniManager.GetString("Flying", "Profile", string.Empty);
     DruidAvoidCombat = pIniManager.GetBoolean("Flying", "DruidAvoidCombat", true);
     Fish = pIniManager.GetBoolean("Flying", "Fish", false);
     Lure = pIniManager.GetBoolean("Flying", "Lure", false);
     SendKeyOnStartCombat = pIniManager.GetBoolean("Flying", "SendKeyOnStartCombat", false);
     MaxTimeAtSchool = Convert.ToDouble(pIniManager.GetString("Flying", "MaxTimeAtSchool", "4"));
     FishApproach = Convert.ToDouble(pIniManager.GetString("Flying", "FishApproach", "30"));
     LureBar = pIniManager.GetString("Flying", "LureBar", "1");
     LureKey = pIniManager.GetString("Flying", "LureKey", "1");
     WaterwalkBar = pIniManager.GetString("Flying", "WaterwalkBar", "1");
     WaterwalkKey = pIniManager.GetString("Flying", "WaterwalkKey", "1");
     ExtraBar = pIniManager.GetString("Flying", "ExtraBar", "1");
     ExtraKey = pIniManager.GetString("Flying", "ExtraKey", "1");
 }
Exemple #2
0
 public static void SaveSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     string ourDirectory = executableDirectoryName;
     var pIniManager = new IniManager(ourDirectory + SettingsName);
     pIniManager.IniWriteValue("Config", "LoadedRotationManager", LoadedRotationManager);
 }
Exemple #3
0
 public RadarForm()
 {
     InitializeComponent();
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     pIniManager = new IniManager(OurDirectory + SettingsName);
 }
Exemple #4
0
 public static void LoadSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     string ourDirectory = executableDirectoryName;
     var pIniManager = new IniManager(ourDirectory + SettingsName);
     LoadedRotationManager = pIniManager.GetString("Config", "LoadedRotationManager", String.Empty);
     LoadKeys();
 }
Exemple #5
0
 public static void LoadSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     LureBar = pIniManager.GetString("Fishing", "LureBar", "1");
     LureKey = pIniManager.GetString("Fishing", "LureKey", "1");
     UseLure = pIniManager.GetBoolean("Fishing", "UseLure", false);
 }
Exemple #6
0
 public static void SaveSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     pIniManager.IniWriteValue("Fishing", "LureBar", LureBar);
     pIniManager.IniWriteValue("Fishing", "LureKey", LureKey);
     pIniManager.IniWriteValue("Fishing", "UseLure", UseLure.ToString());
 }
Exemple #7
0
 public static void Save()
 {
      var pIniManager = new IniManager(OurDirectory + SettingsName);
      pIniManager.IniWriteValue("Geometry", "MainGeometry", MainGeometry);
      pIniManager.IniWriteValue("Geometry", "RotatorStatus", RotatorStatus);
      pIniManager.IniWriteValue("Geometry", "RotationForm", RotationForm);
      pIniManager.IniWriteValue("Geometry", "ProcessSelector", ProcessSelector);
      pIniManager.IniWriteValue("Geometry", "RotatorForm", RotatorForm);
      pIniManager.IniWriteValue("Geometry", "RuleEditor", RuleEditor);
      pIniManager.IniWriteValue("Geometry", "ScriptEditor", ScriptEditor);
 }
 public static void LoadSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     string ourDirectory = executableDirectoryName;
     var pIniManager = new IniManager(ourDirectory + SettingsName);
     LoadedBeharvior = pIniManager.GetString("Config", "LoadedBeharvior", String.Empty);
     AvoidAddsCombat = pIniManager.GetBoolean("Config", "AvoidAddsCombat", false);
     SkipAddsDis = pIniManager.GetInt("Config", "SkipAddsDis", 0);
     AllowScripts = pIniManager.GetBoolean("Config", "AllowScripts", false);
 }
 public static void SaveSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     string ourDirectory = executableDirectoryName;
     var pIniManager = new IniManager(ourDirectory + SettingsName);
     pIniManager.IniWriteValue("Config", "LoadedBeharvior", LoadedBeharvior);
     pIniManager.IniWriteValue("Config", "AvoidAddsCombat", AvoidAddsCombat.ToString());
     pIniManager.IniWriteValue("Config", "SkipAddsDis", SkipAddsDis.ToString());
     pIniManager.IniWriteValue("Config", "AllowScripts", AllowScripts);
 }
Exemple #10
0
 public static void LoadSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     MainGeometry = pIniManager.GetString("Geometry", "MainGeometry", string.Empty);
     RotatorStatus = pIniManager.GetString("Geometry", "RotatorStatus", string.Empty);
     RotationForm = pIniManager.GetString("Geometry", "RotationForm", string.Empty);
     ProcessSelector = pIniManager.GetString("Geometry", "ProcessSelector", string.Empty);
     RotatorForm = pIniManager.GetString("Geometry", "RotatorForm", string.Empty);
     RuleEditor = pIniManager.GetString("Geometry", "RuleEditor", string.Empty);
     ScriptEditor = pIniManager.GetString("Geometry", "ScriptEditor", string.Empty);
 }
Exemple #11
0
        public static void SaveSettings()
        {
            var executableFileInfo = new FileInfo(Application.ExecutablePath);
            string executableDirectoryName = executableFileInfo.DirectoryName;
            OurDirectory = executableDirectoryName;
            var pIniManager = new IniManager(OurDirectory + SettingsName);

            pIniManager.IniWriteValue("Relog", "AccoutnName", Encryptor.Encrypt(AccountName));
            pIniManager.IniWriteValue("Relog", "AccoutnPW", Encryptor.Encrypt(AccountPw));
            pIniManager.IniWriteValue("Relog", "EnableRelogging", ReloggingEnabled.ToString());
            pIniManager.IniWriteValue("Relog", "EnablePeriodicRelogging", PeriodicReloggingEnabled.ToString());
            pIniManager.IniWriteValue("Relog", "PeriodicLogOut", PeriodicLogOut.ToString());
            pIniManager.IniWriteValue("Relog", "PeriodicLogIn", PeriodicLogIn.ToString());
            pIniManager.IniWriteValue("Relog", "AccountAccount", AccountAccount.ToString());
            pIniManager.IniWriteValue("Relog", "CharacterName", CharacterName);
        }
Exemple #12
0
 public static void LoadSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     try
     {
         if (!string.IsNullOrEmpty(pIniManager.GetString("Relog", "AccoutnName", string.Empty)))
         {
             AccountName = Encryptor.Decrypt(pIniManager.GetString("Relog", "AccoutnName", string.Empty));
         }
         else
         {
             AccountName = string.Empty;
         }
         if (!string.IsNullOrEmpty(pIniManager.GetString("Relog", "AccoutnPW", string.Empty)))
         {
             AccountPw = Encryptor.Decrypt(pIniManager.GetString("Relog", "AccoutnPW", string.Empty));
         }
         else
         {
             AccountPw = string.Empty;
         }
         ReloggingEnabled = pIniManager.GetBoolean("Relog", "EnableRelogging", false);
         PeriodicReloggingEnabled = pIniManager.GetBoolean("Relog", "EnablePeriodicRelogging", false);
         PeriodicLogOut = pIniManager.GetInt("Relog", "PeriodicLogOut", 60);
         PeriodicLogIn = pIniManager.GetInt("Relog", "PeriodicLogIn", 30);
         AccountAccount = pIniManager.GetInt("Relog", "AccountAccount", 1);
         CharacterName = pIniManager.GetString("Relog", "CharacterName", string.Empty);
     }
     catch (Exception)
     {
         Logging.Debug("Could not load relogger settings. All relogger values have been reset.");
         AccountName = "";
         AccountPw = "";
         ReloggingEnabled = false;
         PeriodicReloggingEnabled = false;
         PeriodicLogIn = 30;
         PeriodicLogOut = 60;
         AccountAccount = 1;
     }
 }
Exemple #13
0
 public static void SaveSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     pIniManager.IniWriteValue("Grinding", "Profile", Profile);
     pIniManager.IniWriteValue("Grinding", "Skin", Skin.ToString());
     pIniManager.IniWriteValue("Grinding", "WaitForLoot", WaitForLoot.ToString());
     pIniManager.IniWriteValue("Grinding", "StopLootOnFull", StopLootOnFull.ToString());
     pIniManager.IniWriteValue("Grinding", "Loot", Loot.ToString());
     pIniManager.IniWriteValue("Grinding", "Mount", Mount.ToString());
     pIniManager.IniWriteValue("Grinding", "Jump", Jump.ToString());
     pIniManager.IniWriteValue("Grinding", "ApproachRange", ApproachRange.ToString());
     pIniManager.IniWriteValue("Grinding", "SkipMobsWithAdds", SkipMobsWithAdds.ToString());
     pIniManager.IniWriteValue("Grinding", "SkipAddsDistance", SkipAddsDistance.ToString());
     pIniManager.IniWriteValue("Grinding", "SkipAddsCount", SkipAddsCount.ToString());
     pIniManager.IniWriteValue("Grinding", "ShouldTrain", ShouldTrain.ToString());
 }
Exemple #14
0
 public static void LoadSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     Skin = pIniManager.GetBoolean("Grinding", "Skin", false);
     WaitForLoot = pIniManager.GetBoolean("Grinding", "WaitForLoot", false);
     StopLootOnFull = pIniManager.GetBoolean("Grinding", "StopLootOnFull", false);
     Loot = pIniManager.GetBoolean("Grinding", "Loot", true);
     Mount = pIniManager.GetBoolean("Grinding", "Mount", true);
     ApproachRange = pIniManager.GetInt("Grinding", "ApproachRange", 40);
     Profile = pIniManager.GetString("Grinding", "Profile", string.Empty);
     Jump = pIniManager.GetBoolean("Grinding", "Jump", false);
     SkipMobsWithAdds = pIniManager.GetBoolean("Grinding", "SkipMobsWithAdds", false);
     //ShouldTrain = pIniManager.GetBoolean("Grinding", "ShouldTrain", false);
     ShouldTrain = false;
     SkipAddsDistance = pIniManager.GetInt("Grinding", "SkipAddsDistance", 20);
     SkipAddsCount = pIniManager.GetInt("Grinding", "SkipAddsCount", 2);
 }
Exemple #15
0
        // 从数据库读取文件,写入相关位置
        public static bool initme()
        {
            RUNNING = false;

            if (!ObjectManager.Initialized) ObjectManager.Initialize(SpyLogin.WOW_P.Id);
            Thread.Sleep(1000);

            // 获取当前执行路径
            var executableFileInfo = new FileInfo(Application.ExecutablePath);
            string executableDirectoryName = executableFileInfo.DirectoryName;

            // 根据角色职业和地图获取角色的战斗文件和地图文件
            string stringClass = "";
            switch (ObjectManager.MyPlayer.UnitClassId)
            {
                case (uint)Constants.UnitClass.UnitClass_Warrior:
                    stringClass = "战士";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Paladin:
                    stringClass = "骑士";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Hunter:
                    stringClass = "猎人";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Rogue:
                    stringClass = "盗贼";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Priest:
                    stringClass = "牧师";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Shaman:
                    stringClass = "萨满";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Mage:
                    stringClass = "法师";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Warlock:
                    stringClass = "术士";
                    break;
                case (uint)Constants.UnitClass.UnitClass_Druid:
                    stringClass = "德鲁伊";
                    break;
                case (uint)Constants.UnitClass.UnitClass_DeathKnight:
                    stringClass = "死骑";
                    break;
                default:
                    stringClass = "未知";
                    break;
            }
            if (!OraData.GetFileFromDB(2, stringClass, executableDirectoryName + "\\Behaviors"))
            {
                Logging.Write("SpyCJ:initme 错误:角色文件写入失败");
                return false;
            }
            //调用Behavior
            var pIniManager = new IniManager(executableDirectoryName + PveBehaviorSettings.SettingsName);
            pIniManager.IniWriteValue("Config", "LoadedBeharvior", stringClass);

            //下载地图文件
            string map = ObjectManager.MyPlayer.ZoneText;
            if (!OraData.GetFileFromDB(1, map, executableDirectoryName + "\\FlyingProfiles"))
            {
                Logging.Write("SpyCJ:initme 错误:下载地图文件失败");
                return false;
            }
            //调用Profile
            FlyingProfile hh = new FlyingProfile();
            hh.LoadFile(executableDirectoryName + "\\FlyingProfiles\\" + map + ".xml");
            FlyingEngine.CurrentProfile = hh;
            FlyingSettings.Herb = true;
            FlyingSettings.Mine = true;
            FlyingSettings.SaveSettings();

            //获得采集物品列表
            List<string> rtv = SpyDB.GetMapCollect(map);
            if (rtv == null) return false;

            string[] toCollect;
            toCollect = rtv[0].Split('$');
            Mine.Clear();
            for (int iloop = 0; iloop < toCollect.Length; iloop++)
            {
                if (string.IsNullOrWhiteSpace(toCollect[iloop])) continue;
                Mine.AddMine(toCollect[iloop]);
            }
            Mine.HasLoaded = true;

            toCollect = rtv[1].Split('$');
            Herb.Clear();
            for (int iloop = 0; iloop < toCollect.Length; iloop++)
            {
                if (string.IsNullOrWhiteSpace(toCollect[iloop])) continue;
                Herb.AddHerb(toCollect[iloop]);
            }
            Herb.HasLoaded = true;

            // 设置飞行状态和战斗状态
            LazySettings.SelectedEngine = "Flying Engine";
            LazySettings.SelectedCombat = "Behavior Engine";
            LazySettings.SaveSettings();


            return true;
        }
Exemple #16
0
        public static void SaveSettings()
        {
            var executableFileInfo = new FileInfo(Application.ExecutablePath);
            string executableDirectoryName = executableFileInfo.DirectoryName;
            OurDirectory = executableDirectoryName;
            var pIniManager = new IniManager(OurDirectory + SettingsName);
            pIniManager.IniWriteValue("Engine", "Selected", SelectedEngine);
            pIniManager.IniWriteValue("Combat", "Selected", SelectedCombat);
            pIniManager.IniWriteValue("Config", "FirstRun", FirstRun);
            pIniManager.IniWriteValue("Config", "UserName", Password);
            pIniManager.IniWriteValue("Config", "Password", UserName);
            pIniManager.IniWriteValue("Config", "BackgroundMode", BackgroundMode);
            pIniManager.IniWriteValue("Config", "HookMouse", HookMouse);
            pIniManager.IniWriteValue("Config", "UseHotkeys", SetupUseHotkeys);
            pIniManager.IniWriteValue("Config", "StopAfter", StopAfterBool);
            pIniManager.IniWriteValue("Config", "StopAfterTime", StopAfter);
            pIniManager.IniWriteValue("Config", "FollowSound", SoundFollow);
            pIniManager.IniWriteValue("Config", "WhisperSound", SoundWhisper);
            pIniManager.IniWriteValue("Config", "SoundStop", SoundStop);
            pIniManager.IniWriteValue("Config", "ShutdownComputer", Shutdown);
            pIniManager.IniWriteValue("Config", "LogoutOnFollow", LogoutOnFollow);
            pIniManager.IniWriteValue("Config", "LogoutOnFollowTime", LogOutOnFollowTime);
            pIniManager.IniWriteValue("Config", "UseCtm", UseCtm);
            pIniManager.IniWriteValue("Config", "DebugLog", DebugLog);
            pIniManager.IniWriteValue("Config", "Latency", Latency);
            pIniManager.IniWriteValue("Config", "Language", Convert.ToInt32(Language));
            //Other
            pIniManager.IniWriteValue("Combat", "CBEat", CombatBoolEat);
            pIniManager.IniWriteValue("Combat", "CBDrink", CombatBoolDrink);
            pIniManager.IniWriteValue("Combat", "COEat", CombatEatAt);
            pIniManager.IniWriteValue("Combat", "CODrink", CombatDrinkAt);

            pIniManager.IniWriteValue("Keys", "GroundMountBar", KeysGroundMountBar);
            pIniManager.IniWriteValue("Keys", "GroundMountKey", KeysGroundMountKey);
            pIniManager.IniWriteValue("Keys", "Attack1Bar", KeysAttack1Bar);
            pIniManager.IniWriteValue("Keys", "Attack1Key", KeysAttack1Key);
            pIniManager.IniWriteValue("Keys", "EatBar", KeysEatBar);
            pIniManager.IniWriteValue("Keys", "EatKey", KeysEatKey);
            pIniManager.IniWriteValue("Keys", "DrinkBar", KeysDrinkBar);
            pIniManager.IniWriteValue("Keys", "DrinkKey", KeysDrinkKey);
            pIniManager.IniWriteValue("Keys", "MoteBar", KeysMoteExtractorBar);
            pIniManager.IniWriteValue("Keys", "MoteKey", KeysMoteExtractorKey);
            pIniManager.IniWriteValue("Keys", "InteractText", KeysInteractKeyText);
            pIniManager.IniWriteValue("Keys", "InteractTargetText", KeysInteractTargetText);
            pIniManager.IniWriteValue("Keys", "StafeLeftKeyText", KeysStafeLeftKeyText);
            pIniManager.IniWriteValue("Keys", "StafeRightKeyText", KeysStafeRightKeyText);
            pIniManager.IniWriteValue("Keys", "KeysTargetLastTargetText", KeysTargetLastTargetText);

            //Mail
            pIniManager.IniWriteValue("Mail", "ShouldMail", ShouldMail);
            pIniManager.IniWriteValue("Mail", "MailTo", MailTo);
            pIniManager.IniWriteValue("Mail", "MacroForMail", MacroForMail);
            pIniManager.IniWriteValue("Mail", "KeysMailMacroBar", KeysMailMacroBar);
            pIniManager.IniWriteValue("Mail", "KeysMailMacroKey", KeysMailMacroKey);

            //Vendor
            pIniManager.IniWriteValue("Vendor", "ShouldVendor", ShouldVendor);
            pIniManager.IniWriteValue("Vendor", "ShouldRepair", ShouldRepair);
            pIniManager.IniWriteValue("Vendor", "SellCommon", SellCommon);
            pIniManager.IniWriteValue("Vendor", "SellUncommon", SellUncommon);
            pIniManager.IniWriteValue("Vendor", "SellPoor", SellPoor);
            pIniManager.IniWriteValue("Vendor", "FreeBackspace", FreeBackspace);
            
            //Add by Spyman
            pIniManager.IniWriteValue("Config", "WOWPath", WOWPath);
            pIniManager.IniWriteValue("Config", "WOWAccName", WOWAccName);
            pIniManager.IniWriteValue("Config", "WOWAccPath", WOWAccPass);
            pIniManager.IniWriteValue("Config", "WOWCharList", WOWCharList);
            pIniManager.IniWriteValue("Config", "WOWCharIdx", WOWCharIdx);
            pIniManager.IniWriteValue("Config", "WOWServer", WOWServer);
            pIniManager.IniWriteValue("Config", "StartHour", StartHour);
            pIniManager.IniWriteValue("Config", "StartMin", StartMin);
            pIniManager.IniWriteValue("Config", "StopHour", StopHour);
            pIniManager.IniWriteValue("Config", "StopMin", StopMin);
            pIniManager.IniWriteValue("Config", "FightFile", FightFile);
            pIniManager.IniWriteValue("Config", "MapFile", MapFile);
            pIniManager.IniWriteValue("Config", "DBIP", DBIP);
            pIniManager.IniWriteValue("Config", "DBSid", DBSid);
            pIniManager.IniWriteValue("Config", "MachineID", MachineID);
            pIniManager.IniWriteValue("Config", "AHer", AHer);
            pIniManager.IniWriteValue("Config", "WriteLazyLog", WriteLazyLog);
        }
Exemple #17
0
        public static void LoadSettings()
        {
            var executableFileInfo = new FileInfo(Application.ExecutablePath);
            string executableDirectoryName = executableFileInfo.DirectoryName;
            OurDirectory = executableDirectoryName;
            var pIniManager = new IniManager(OurDirectory + SettingsName);
            SelectedEngine = pIniManager.GetString("Engine", "Selected", string.Empty);
            SelectedCombat = pIniManager.GetString("Combat", "Selected", string.Empty);
            FirstRun = pIniManager.GetBoolean("Config", "FirstRun", true);
            DebugMode = pIniManager.GetBoolean("Config", "DebugMode", false);
            Password = pIniManager.GetString("Config", "UserName", String.Empty);
            UserName = pIniManager.GetString("Config", "Password", String.Empty);
            BackgroundMode = pIniManager.GetBoolean("Config", "BackgroundMode", false);
            HookMouse = pIniManager.GetBoolean("Config", "HookMouse", false);
            SetupUseHotkeys = pIniManager.GetBoolean("Config", "UseHotkeys", false);
            StopAfterBool = pIniManager.GetBoolean("Config", "StopAfter", false);
            StopAfter = pIniManager.GetString("Config", "StopAfterTime", "120");
            LogOutOnFollowTime = pIniManager.GetString("Config", "LogoutOnFollowTime", "2");
            SoundFollow = pIniManager.GetBoolean("Config", "FollowSound", true);
            SoundWhisper = pIniManager.GetBoolean("Config", "WhisperSound", true);
            SoundStop = pIniManager.GetBoolean("Config", "SoundStop", true);
            Shutdown = pIniManager.GetBoolean("Config", "ShutdownComputer", false);
            LogoutOnFollow = pIniManager.GetBoolean("Config", "LogoutOnFollow", false);
            UseCtm = pIniManager.GetBoolean("Config", "UseCtm", false);
            DebugLog = pIniManager.GetBoolean("Config", "DebugLog", false);
            Latency = pIniManager.GetInt("Config", "Latency", 0);
            Language = (LazyLanguage)pIniManager.GetInt("Config", "Language", 0);
            //
            CombatBoolEat = pIniManager.GetBoolean("Combat", "CBEat", true);
            CombatBoolDrink = pIniManager.GetBoolean("Combat", "CBDrink", true);
            CombatEatAt = pIniManager.GetString("Combat", "COEat", "0");
            CombatDrinkAt = pIniManager.GetString("Combat", "CODrink", "0");

            KeysGroundMountBar = pIniManager.GetString("Keys", "GroundMountBar", "1");
            KeysGroundMountKey = pIniManager.GetString("Keys", "GroundMountKey", "1");
            KeysAttack1Bar = pIniManager.GetString("Keys", "Attack1Bar", "1");
            KeysAttack1Key = pIniManager.GetString("Keys", "Attack1Key", "1");
            KeysEatBar = pIniManager.GetString("Keys", "EatBar", "1");
            KeysEatKey = pIniManager.GetString("Keys", "EatKey", "1");
            KeysDrinkBar = pIniManager.GetString("Keys", "DrinkBar", "1");
            KeysDrinkKey = pIniManager.GetString("Keys", "DrinkKey", "1");
            KeysMoteExtractorBar = pIniManager.GetString("Keys", "MoteBar", "1");
            KeysMoteExtractorKey = pIniManager.GetString("Keys", "MoteKey", "1");
            KeysStafeLeftKeyText = pIniManager.GetString("Keys", "StafeLeftKeyText", "Q");
            KeysStafeRightKeyText = pIniManager.GetString("Keys", "StafeRightKeyText", "E");
            KeysInteractKeyText = pIniManager.GetString("Keys", "InteractText", "U");
            KeysInteractTargetText = pIniManager.GetString("Keys", "InteractTargetText", "P");
            KeysTargetLastTargetText = pIniManager.GetString("Keys", "KeysTargetLastTargetText", "G");

            //Mail
            ShouldMail = pIniManager.GetBoolean("Mail", "ShouldMail", false);
            MailTo = pIniManager.GetString("Mail", "MailTo", string.Empty);
            //MacroForMail = pIniManager.GetBoolean("Mail", "MacroForMail", false);
            MacroForMail = false;
            KeysMailMacroBar = pIniManager.GetString("Mail", "KeysMailMacroBar", "1");
            KeysMailMacroKey = pIniManager.GetString("Mail", "KeysMailMacroKey", "1");

            //Vendor
            ShouldVendor = pIniManager.GetBoolean("Vendor", "ShouldVendor", false);
            ShouldRepair = pIniManager.GetBoolean("Vendor", "ShouldRepair", false);
            SellCommon = pIniManager.GetBoolean("Vendor", "SellCommon", false);
            SellUncommon = pIniManager.GetBoolean("Vendor", "SellUncommon", false);
            SellPoor = pIniManager.GetBoolean("Vendor", "SellPoor", false);
            FreeBackspace = pIniManager.GetString("Vendor", "FreeBackspace", "2"); 

            //Add by Spyman
            WOWPath = pIniManager.GetString("Config", "WOWPath", "");
            WOWAccName = pIniManager.GetString("Config", "WOWAccName", "");
            WOWAccPass = pIniManager.GetString("Config", "WOWAccPath", "");
            WOWCharList = pIniManager.GetString("Config", "WOWCharList", "");
            WOWCharIdx = pIniManager.GetString("Config", "WOWCharIdx", "");
            WOWServer = pIniManager.GetString("Config", "WOWServer", "");
            StartHour = pIniManager.GetString("Config", "StartHour", "");
            StartMin = pIniManager.GetString("Config", "StartMin", "");
            StopHour = pIniManager.GetString("Config", "StopHour", "");
            StopMin = pIniManager.GetString("Config", "StopMin", "");
            FightFile = pIniManager.GetString("Config", "FightFile", "");
            MapFile = pIniManager.GetString("Config", "MapFile", "");
            DBIP = pIniManager.GetString("Config", "DBIP", "");
            DBSid = pIniManager.GetString("Config", "DBSid", "");
            MachineID = pIniManager.GetString("Config", "MachineID", "");
            AHer = pIniManager.GetString("Config", "AHer", "");
            WriteLazyLog = pIniManager.GetBoolean("Config", "WriteLazyLog", false);
        }
Exemple #18
0
 public static void SaveSettings()
 {
     var executableFileInfo = new FileInfo(Application.ExecutablePath);
     string executableDirectoryName = executableFileInfo.DirectoryName;
     OurDirectory = executableDirectoryName;
     var pIniManager = new IniManager(OurDirectory + SettingsName);
     pIniManager.IniWriteValue("Flying", "Herb", Herb.ToString());
     pIniManager.IniWriteValue("Flying", "Mine", Mine.ToString());
     pIniManager.IniWriteValue("Flying", "ApproachModifier", ApproachModifier.ToString());
     pIniManager.IniWriteValue("Flying", "MaxUnits", MaxUnits);
     pIniManager.IniWriteValue("Flying", "StopOnDeath", StopOnDeath.ToString());
     pIniManager.IniWriteValue("Flying", "StopHarvest", StopHarvestWithPlayerAround.ToString());
     pIniManager.IniWriteValue("Flying", "StopOnFullBags", StopOnFullBags.ToString());
     pIniManager.IniWriteValue("Flying", "AvoidPlayers", AvoidPlayers.ToString());
     pIniManager.IniWriteValue("Flying", "AutoBlacklist", AutoBlacklist.ToString());
     pIniManager.IniWriteValue("Flying", "AvoidElites", AvoidElites.ToString());
     pIniManager.IniWriteValue("Flying", "FindCorpse", FindCorpse.ToString());
     pIniManager.IniWriteValue("Flying", "WaitForLoot", WaitForLoot.ToString());
     pIniManager.IniWriteValue("Flying", "WaitForRessSick", WaitForRessSick.ToString());
     pIniManager.IniWriteValue("Flying", "FlyingMountBar", FlyingMountBar);
     pIniManager.IniWriteValue("Flying", "FlyingMountKey", FlyingMountKey);
     pIniManager.IniWriteValue("Flying", "Profile", Profile);
     pIniManager.IniWriteValue("Flying", "DruidAvoidCombat", DruidAvoidCombat);
     pIniManager.IniWriteValue("Flying", "Fish", Fish);
     pIniManager.IniWriteValue("Flying", "Lure", Lure);
     pIniManager.IniWriteValue("Flying", "MaxTimeAtSchool", MaxTimeAtSchool);
     pIniManager.IniWriteValue("Flying", "FishApproach", FishApproach);
     pIniManager.IniWriteValue("Flying", "LureBar", LureBar);
     pIniManager.IniWriteValue("Flying", "LureKey", LureKey);
     pIniManager.IniWriteValue("Flying", "WaterwalkBar", WaterwalkBar);
     pIniManager.IniWriteValue("Flying", "WaterwalkKey", WaterwalkKey);
     pIniManager.IniWriteValue("Flying", "ExtraBar", ExtraBar);
     pIniManager.IniWriteValue("Flying", "ExtraKey", ExtraKey);
     pIniManager.IniWriteValue("Flying", "SendKeyOnStartCombat", SendKeyOnStartCombat);
 }
Exemple #19
0
 private static void WritePluginSettings(string name, bool enabled)
 {
     try
     {
         var pIniManager = new IniManager(LazyForms.OurDirectory + "\\Settings\\lazy_plugins.ini");
         pIniManager.IniWriteValue("Plugins", name, enabled.ToString());
     }
     catch
     {
     }
 }
Exemple #20
0
 private static bool LoadPluginSettings(string name)
 {
     try
     {
         var pIniManager = new IniManager(LazyForms.OurDirectory + "\\Settings\\lazy_plugins.ini");
         return pIniManager.GetBoolean("Plugins", name, false);
     }
     catch
     {
     }
     return false;
 }