sync with upstreaom #2

Open
goatzone wants to merge 581 commits from liza/Questionable:master into master
Showing only changes of commit 16b62316c5 - Show all commits

View File

@ -22,13 +22,16 @@ internal sealed class TextAdvanceIpc : IDisposable
private readonly string _pluginName;
private readonly ExternalTerritoryConfig _externalTerritoryConfig = new();
public TextAdvanceIpc(IDalamudPluginInterface pluginInterface, IFramework framework, QuestController questController, Configuration configuration)
public TextAdvanceIpc(IDalamudPluginInterface pluginInterface, IFramework framework,
QuestController questController, Configuration configuration)
{
_framework = framework;
_questController = questController;
_configuration = configuration;
_isInExternalControl = pluginInterface.GetIpcSubscriber<bool>("TextAdvance.IsInExternalControl");
_enableExternalControl = pluginInterface.GetIpcSubscriber<string, ExternalTerritoryConfig, bool>("TextAdvance.EnableExternalControl");
_enableExternalControl =
pluginInterface.GetIpcSubscriber<string, ExternalTerritoryConfig, bool>(
"TextAdvance.EnableExternalControl");
_disableExternalControl = pluginInterface.GetIpcSubscriber<string, bool>("TextAdvance.DisableExternalControl");
_pluginName = pluginInterface.InternalName;
_framework.Update += OnUpdate;
@ -45,7 +48,9 @@ internal sealed class TextAdvanceIpc : IDisposable
private void OnUpdate(IFramework framework)
{
if(_configuration.General.ConfigureTextAdvance && _questController.IsRunning)
bool hasActiveQuest = _questController.IsRunning ||
_questController.AutomationType != QuestController.EAutomationType.Manual;
if (_configuration.General.ConfigureTextAdvance && hasActiveQuest)
{
if (!_isInExternalControl.InvokeFunc())
{