s/PenumbraCmd/PatMe2Mqtt/g (scrapped plogon that previously lived here)

This commit is contained in:
Jade Macho 2023-05-26 16:21:41 +02:00
parent 92e9893a35
commit 9200d0048f
Signed by: 0x0ade
GPG Key ID: 21C91DB3ADE0B6D5

View File

@ -23,14 +23,14 @@ namespace PatMe2Mqtt
{ {
if (typeof(PluginServiceAttribute).Assembly.GetType("Dalamud.Service`1") is not { } serviceContainerContainer) if (typeof(PluginServiceAttribute).Assembly.GetType("Dalamud.Service`1") is not { } serviceContainerContainer)
{ {
PluginLog.LogInformation("PenumbraCmd couldn't find the service container types."); PluginLog.LogInformation("PatMe2Mqtt couldn't find the service container types.");
return; return;
} }
if (typeof(PluginServiceAttribute).Assembly.GetType("Dalamud.Plugin.Internal.PluginManager") is not { } pluginManagerType) if (typeof(PluginServiceAttribute).Assembly.GetType("Dalamud.Plugin.Internal.PluginManager") is not { } pluginManagerType)
{ {
PluginLog.LogInformation("PenumbraCmd couldn't find the plugin manager type."); PluginLog.LogInformation("PatMe2Mqtt couldn't find the plugin manager type.");
return; return;
} }
@ -38,7 +38,7 @@ namespace PatMe2Mqtt
if (typeof(PluginServiceAttribute).Assembly.GetType("Dalamud.Plugin.Internal.Types.LocalPlugin") is not { } localPluginType || if (typeof(PluginServiceAttribute).Assembly.GetType("Dalamud.Plugin.Internal.Types.LocalPlugin") is not { } localPluginType ||
localPluginType.GetField("instance", BindingFlags.NonPublic | BindingFlags.Instance) is not { } localPluginInstanceField) localPluginType.GetField("instance", BindingFlags.NonPublic | BindingFlags.Instance) is not { } localPluginInstanceField)
{ {
PluginLog.LogInformation("PenumbraCmd couldn't find the local plugin type or important members."); PluginLog.LogInformation("PatMe2Mqtt couldn't find the local plugin type or important members.");
return; return;
} }
@ -47,14 +47,14 @@ namespace PatMe2Mqtt
if (serviceContainerContainer.GetMethod("Get")?.Invoke(null, Array.Empty<object>()) is not object manager) if (serviceContainerContainer.GetMethod("Get")?.Invoke(null, Array.Empty<object>()) is not object manager)
{ {
PluginLog.LogInformation("PenumbraCmd couldn't obtain the plugin manager."); PluginLog.LogInformation("PatMe2Mqtt couldn't obtain the plugin manager.");
return; return;
} }
if (pluginManagerType.GetProperty("InstalledPlugins") is not { } installedPluginsProperty) if (pluginManagerType.GetProperty("InstalledPlugins") is not { } installedPluginsProperty)
{ {
PluginLog.LogInformation("PenumbraCmd couldn't obtain the plugin list property."); PluginLog.LogInformation("PatMe2Mqtt couldn't obtain the plugin list property.");
return; return;
} }
@ -63,7 +63,7 @@ namespace PatMe2Mqtt
{ {
if (installedPluginsProperty?.GetValue(manager) is not IList installedPlugins) if (installedPluginsProperty?.GetValue(manager) is not IList installedPlugins)
{ {
PluginLog.LogInformation("PenumbraCmd couldn't obtain the plugin list."); PluginLog.LogInformation("PatMe2Mqtt couldn't obtain the plugin list.");
return null; return null;
} }
@ -81,7 +81,7 @@ namespace PatMe2Mqtt
} }
catch (Exception e) catch (Exception e)
{ {
PluginLog.LogInformation($"PenumbraCmd couldn't obtain the plugin manager service: {e}"); PluginLog.LogInformation($"PatMe2Mqtt couldn't obtain the plugin manager service: {e}");
} }
} }