forked from aly/qstbak
229 lines
6.5 KiB
C#
229 lines
6.5 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using Dalamud.Configuration;
|
|
using QuestionableCompanion.Models;
|
|
|
|
namespace QuestionableCompanion;
|
|
|
|
[Serializable]
|
|
public class Configuration : IPluginConfiguration
|
|
{
|
|
public int Version { get; set; } = 1;
|
|
|
|
public bool IsConfigWindowMovable { get; set; } = true;
|
|
|
|
public bool ShowDebugLogs { get; set; }
|
|
|
|
public List<QuestProfile> Profiles { get; set; } = new List<QuestProfile>();
|
|
|
|
public string ActiveProfileName { get; set; } = string.Empty;
|
|
|
|
public AlliedSocietySettings AlliedSociety { get; set; } = new AlliedSocietySettings();
|
|
|
|
public bool AutoStartOnLogin { get; set; }
|
|
|
|
public bool EnableDryRun { get; set; }
|
|
|
|
public int MaxRetryAttempts { get; set; } = 3;
|
|
|
|
public int CharacterSwitchDelay { get; set; } = 5;
|
|
|
|
public int MaxLogEntries { get; set; } = 100;
|
|
|
|
public bool LogToFile { get; set; }
|
|
|
|
public ExecutionState LastExecutionState { get; set; } = new ExecutionState();
|
|
|
|
public bool RestoreStateOnLoad { get; set; }
|
|
|
|
public List<StopPoint> StopPoints { get; set; } = new List<StopPoint>();
|
|
|
|
public RotationState LastRotationState { get; set; } = new RotationState();
|
|
|
|
public List<string> SelectedCharactersForRotation { get; set; } = new List<string>();
|
|
|
|
public List<string> SelectedCharactersForUI { get; set; } = new List<string>();
|
|
|
|
public Dictionary<uint, List<string>> QuestCompletionByCharacter { get; set; } = new Dictionary<uint, List<string>>();
|
|
|
|
public Dictionary<string, List<string>> EventQuestCompletionByCharacter { get; set; } = new Dictionary<string, List<string>>();
|
|
|
|
public string CurrentEventQuestId { get; set; } = string.Empty;
|
|
|
|
public List<string> SelectedCharactersForEventQuest { get; set; } = new List<string>();
|
|
|
|
public bool RunEventQuestsOnARPostProcess { get; set; }
|
|
|
|
public List<string> EventQuestsToRunOnPostProcess { get; set; } = new List<string>();
|
|
|
|
public int EventQuestPostProcessTimeoutMinutes { get; set; } = 30;
|
|
|
|
public bool EnableSubmarineCheck { get; set; }
|
|
|
|
public int SubmarineCheckInterval { get; set; } = 90;
|
|
|
|
public int SubmarineReloginCooldown { get; set; } = 120;
|
|
|
|
public int SubmarineWaitTime { get; set; } = 30;
|
|
|
|
public bool EnableAutoDutyUnsynced { get; set; }
|
|
|
|
public int AutoDutyPartySize { get; set; } = 2;
|
|
|
|
public int AutoDutyMaxWaitForParty { get; set; } = 30;
|
|
|
|
public int AutoDutyReInviteInterval { get; set; } = 10;
|
|
|
|
public bool EnableQSTReloadTracking { get; set; }
|
|
|
|
public int MaxQSTReloadsBeforeSwitch { get; set; } = 5;
|
|
|
|
public bool EnableDCTravel { get; set; }
|
|
|
|
public string DCTravelWorld { get; set; } = "";
|
|
|
|
public bool EnableMovementMonitor { get; set; }
|
|
|
|
public int MovementCheckInterval { get; set; } = 5;
|
|
|
|
public int MovementStuckThreshold { get; set; } = 30;
|
|
|
|
public bool EnableCombatHandling { get; set; }
|
|
|
|
public int CombatHPThreshold { get; set; } = 50;
|
|
|
|
public bool EnableDeathHandling { get; set; }
|
|
|
|
public int DeathRespawnDelay { get; set; } = 5;
|
|
|
|
public bool LogToDalamud { get; set; }
|
|
|
|
public MSQDisplayMode MSQDisplayMode { get; set; } = MSQDisplayMode.Overall;
|
|
|
|
public bool ShowPatchVersion { get; set; }
|
|
|
|
public string DCTravelDataCenter { get; set; } = "";
|
|
|
|
public string DCTravelTargetWorld { get; set; } = "";
|
|
|
|
public bool EnableDCTravelFeature { get; set; }
|
|
|
|
public bool EnableMultiModeAfterRotation { get; set; }
|
|
|
|
public bool ReturnToHomeworldOnStopQuest { get; set; }
|
|
|
|
public bool IsHighLevelHelper { get; set; }
|
|
|
|
public bool IsQuester { get; set; }
|
|
|
|
public List<HighLevelHelperConfig> HighLevelHelpers { get; set; } = new List<HighLevelHelperConfig>();
|
|
|
|
public bool ChauffeurModeEnabled { get; set; }
|
|
|
|
public float ChauffeurDistanceThreshold { get; set; } = 100f;
|
|
|
|
public float ChauffeurStopDistance { get; set; } = 5f;
|
|
|
|
public uint ChauffeurMountId { get; set; }
|
|
|
|
public string PreferredHelper { get; set; } = "";
|
|
|
|
public string AssignedQuester { get; set; } = "";
|
|
|
|
public HelperStatus CurrentHelperStatus { get; set; }
|
|
|
|
public HelperSelectionMode HelperSelection { get; set; }
|
|
|
|
public string ManualHelperName { get; set; } = "";
|
|
|
|
public bool AlwaysAutoAcceptInvites { get; set; }
|
|
|
|
public bool EnableHelperFollowing { get; set; }
|
|
|
|
public float HelperFollowDistance { get; set; } = 100f;
|
|
|
|
public int HelperFollowCheckInterval { get; set; } = 5;
|
|
|
|
public string AssignedQuesterForFollowing { get; set; } = "";
|
|
|
|
public string AssignedHelperForFollowing { get; set; } = "";
|
|
|
|
public bool EnableARRPrimalCheck { get; set; }
|
|
|
|
public bool EnableSafeWaitBeforeCharacterSwitch { get; set; }
|
|
|
|
public bool EnableSafeWaitAfterCharacterSwitch { get; set; }
|
|
|
|
public bool EnableQuestPreCheck { get; set; }
|
|
|
|
public List<uint>? QuestPreCheckRange { get; set; }
|
|
|
|
public string SelectedDatacenter { get; set; } = "NA";
|
|
|
|
public Dictionary<string, List<string>> WorldsByDatacenter { get; set; } = new Dictionary<string, List<string>>
|
|
{
|
|
{
|
|
"NA",
|
|
new List<string>
|
|
{
|
|
"Adamantoise", "Cactuar", "Faerie", "Gilgamesh", "Jenova", "Midgardsormr", "Sargatanas", "Siren", "Behemoth", "Excalibur",
|
|
"Exodus", "Famfrit", "Hyperion", "Lamia", "Leviathan", "Ultros", "Balmung", "Brynhildr", "Coeurl", "Diabolos",
|
|
"Goblin", "Malboro", "Mateus", "Zalera", "Halicarnassus", "Maduin", "Marilith", "Seraph"
|
|
}
|
|
},
|
|
{
|
|
"EU",
|
|
new List<string>
|
|
{
|
|
"Cerberus", "Louisoix", "Moogle", "Omega", "Phantom", "Ragnarok", "Sagittarius", "Spriggan", "Alpha", "Lich",
|
|
"Odin", "Phoenix", "Raiden", "Shiva", "Twintania", "Zodiark"
|
|
}
|
|
},
|
|
{
|
|
"JP",
|
|
new List<string>
|
|
{
|
|
"Aegis", "Atomos", "Carbuncle", "Garuda", "Gungnir", "Kujata", "Tonberry", "Typhon", "Alexander", "Bahamut",
|
|
"Durandal", "Fenrir", "Ifrit", "Ridill", "Tiamat", "Ultima", "Anima", "Asura", "Chocobo", "Hades",
|
|
"Ixion", "Masamune", "Pandaemonium", "Titan", "Gaia", "Belias", "Mandragora", "Ramuh", "Shinryu", "Unicorn",
|
|
"Valefor", "Yojimbo", "Zeromus"
|
|
}
|
|
},
|
|
{
|
|
"OCE",
|
|
new List<string> { "Bismarck", "Ravana", "Sephirot", "Sophia", "Zurvan" }
|
|
}
|
|
};
|
|
|
|
public bool EnableLANHelpers { get; set; }
|
|
|
|
public int LANServerPort { get; set; } = 47788;
|
|
|
|
public List<string> LANHelperIPs { get; set; } = new List<string>();
|
|
|
|
public bool StartLANServer { get; set; }
|
|
|
|
public void Save()
|
|
{
|
|
Plugin.PluginInterface.SavePluginConfig(this);
|
|
}
|
|
|
|
public QuestProfile? GetActiveProfile()
|
|
{
|
|
return Profiles.Find((QuestProfile p) => p.Name == ActiveProfileName);
|
|
}
|
|
|
|
public void EnsureDefaultProfile()
|
|
{
|
|
if (Profiles.Count == 0)
|
|
{
|
|
QuestProfile defaultProfile = new QuestProfile
|
|
{
|
|
Name = "Default Profile",
|
|
IsActive = true
|
|
};
|
|
Profiles.Add(defaultProfile);
|
|
ActiveProfileName = defaultProfile.Name;
|
|
}
|
|
}
|
|
}
|