diff --git a/Il2CppInspector.Common/Plugins/Internal/ICorePlugin.cs b/Il2CppInspector.Common/Plugins/Internal/ICorePlugin.cs new file mode 100644 index 0000000..24ec771 --- /dev/null +++ b/Il2CppInspector.Common/Plugins/Internal/ICorePlugin.cs @@ -0,0 +1,14 @@ +/* + Copyright 2021 Katy Coe - http://www.djkaty.com - https://github.com/djkaty + + All rights reserved. +*/ + +namespace Il2CppInspector.PluginAPI.V100 +{ + /// + /// Interface denoting a plugin that is an internal part of Il2CppInspector + /// For internal use only + /// + public interface ICorePlugin : IPlugin { } +} diff --git a/Il2CppInspector.Common/Plugins/Internal/PluginManager.cs b/Il2CppInspector.Common/Plugins/Internal/PluginManager.cs index 484c438..9d99d3f 100644 --- a/Il2CppInspector.Common/Plugins/Internal/PluginManager.cs +++ b/Il2CppInspector.Common/Plugins/Internal/PluginManager.cs @@ -214,7 +214,10 @@ namespace Il2CppInspector if (AsInstance.ManagedPlugins.Any(p => p.Plugin.Id == plugin.Id)) throw new Exception($"Multiple copies of {plugin.Name} were found. Please ensure the plugins folder only contains one copy of each plugin."); - AsInstance.ManagedPlugins.Add(new ManagedPlugin { Plugin = plugin, Available = true, Enabled = false }); + // Enable internal plugins by default + var enabled = typeof(ICorePlugin).IsAssignableFrom(type); + + AsInstance.ManagedPlugins.Add(new ManagedPlugin { Plugin = plugin, Available = true, Enabled = enabled }); } // Add older versions here with adapters