mirror of
https://github.com/D1GQ/BetterAmongUs.git
synced 2026-10-20 01:46:19 +00:00
rename to options
This commit is contained in:
1 parent
1ca4f6c621
commit
656da48505
3 files changed
+13
-13
No files matched your search
+1
-1
@@ -150,7 +150,7 @@ internal class BAUPlugin : BasePlugin
|
||||
Translator.Initialize();
|
||||
Harmony.PatchAll();
|
||||
GameSettingsPatch.SetupSettings(true);
|
||||
BAUModdedSupportEvents.InvokeAll_OnBAUSettingsLoaded([.. OptionItem.AllOptions.Cast<object>()]);
|
||||
BAUModdedSupportEvents.InvokeAll_OnBAUOptionsLoaded([.. OptionItem.AllOptions.Cast<object>()]);
|
||||
InstanceAttribute.RegisterAll();
|
||||
OutfitData.Initialize();
|
||||
|
||||
|
||||
@@ -27,14 +27,14 @@ internal class ModdedSupportBAUEventExample
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Called when BetterAmongUs settings have been loaded.
|
||||
/// Allows plugins to read or modify BAU settings.
|
||||
/// Called when BetterAmongUs game options have been loaded.
|
||||
/// Allows plugins to read or modify BAU game options.
|
||||
/// </summary>
|
||||
/// <param name="settings">
|
||||
/// Array of setting objects from BetterAmongUs.
|
||||
/// <param name="options">
|
||||
/// Array of game options objects from BetterAmongUs.
|
||||
/// The exact type of these objects depends on BAU's internal implementation.
|
||||
/// </param>
|
||||
public void OnBAUSettingsLoaded(object[] settings)
|
||||
public void OnBAUOptionsLoaded(object[] options)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -26,10 +26,10 @@ public class BAUModdedSupportEvents
|
||||
public bool OnBAULoad(BasePlugin bauPlugin) => true;
|
||||
|
||||
/// <summary>
|
||||
/// Default implementation of the OnBAUSettingsLoaded event handler.
|
||||
/// Default implementation of the OnBAUOptionsLoaded event handler.
|
||||
/// </summary>
|
||||
/// <param name="settings">The loaded settings from BetterAmongUs.</param>
|
||||
public void OnBAUSettingsLoaded(object[] settings) { }
|
||||
/// <param name="options">The loaded game options from BetterAmongUs.</param>
|
||||
public void OnBAUOptionsLoaded(object[] options) { }
|
||||
|
||||
/// <summary>
|
||||
/// Default implementation of the OnBAUConfigEntriesLoaded event handler.
|
||||
@@ -64,15 +64,15 @@ public class BAUModdedSupportEvents
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Invokes the OnBAUSettingsLoaded event handler for all loaded plugins.
|
||||
/// Invokes the OnBAUOptionsLoaded event handler for all loaded plugins.
|
||||
/// </summary>
|
||||
/// <param name="settings">The loaded settings from BetterAmongUs.</param>
|
||||
internal static void InvokeAll_OnBAUSettingsLoaded(object[] settings)
|
||||
/// <param name="options">The loaded game options from BetterAmongUs.</param>
|
||||
internal static void InvokeAll_OnBAUOptionsLoaded(object[] options)
|
||||
{
|
||||
foreach (var pluginInfo in IL2CPPChainloader.Instance.Plugins.Values)
|
||||
{
|
||||
var plugin = (BasePlugin)pluginInfo.Instance;
|
||||
InvokePluginMethod<object>(plugin, nameof(OnBAUSettingsLoaded), parameters: settings);
|
||||
InvokePluginMethod<object>(plugin, nameof(OnBAUOptionsLoaded), parameters: options);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user