Beispiel #1
0
        private void RelocateAddon()
        {
            Console.WriteLine("Relocating addon...");
            AddonLocator.ReCalculateAddonPosition();
            var addonLocation = AddonLocator.GetAddonLocation();

            if (addonLocation.Width == 1 || addonLocation.Height == 1)
            {
                Logger.Log("Addon could not be located. Make sure it's loaded and visible.", ConsoleColor.Red);
            }
            else
            {
                Logger.Log($"Addon successfully located: {addonLocation.ToString()}", ConsoleColor.Green);
            }

            AddonFolderHandler.LocateAddonFolderPath();
            var addonFolderPath = AddonFolderHandler.GetAddonFolderPath();

            if (!string.IsNullOrEmpty(addonFolderPath))
            {
                Logger.Log($"Successfully found Wow Addon folder at {addonFolderPath}", ConsoleColor.Green);
            }
            else
            {
                Logger.Log("Addon folder could not be found!", ConsoleColor.Red);
                Logger.Log("Make sure the game is running when the app tries to locate the Addon PATH. Run 'addon reload' when the game is running to retry.", ConsoleColor.Red);
            }
        }
Beispiel #2
0
 static ApplicationSettings GetApplicationSettings(AppSettings settings)
 {
     return(new ApplicationSettings
     {
         ServerUrl = settings.ServerAddress,
         WowAddonPath = $"{AddonFolderHandler.GetAddonFolderPath()}",
         Bot = BotRunner
     });
 }