mirror of
https://github.com/All-Of-Us-Mods/MiraAPI.git
synced 2026-10-19 15:51:48 +00:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
ffca13e6e6
9 files changed
+14
-13
No files matched your search
@@ -20,7 +20,7 @@ public class LocalEnumSettingAttribute(
|
||||
private readonly string? _description = description;
|
||||
|
||||
/// <inheritdoc/>
|
||||
internal override LocalEnumSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
public override LocalEnumSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
{
|
||||
return new LocalEnumSetting(tab, configEntryBase, configEntryBase.SettingType, _name, _description, names);
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@ public class LocalNumberSettingAttribute(
|
||||
private readonly string? _description = description;
|
||||
|
||||
/// <inheritdoc/>
|
||||
internal override LocalNumberSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
public override LocalNumberSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
{
|
||||
return new LocalNumberSetting(tab, configEntryBase, _name, _description, new FloatRange(min, max), increment, suffixType, formatString);
|
||||
}
|
||||
|
||||
@@ -20,5 +20,5 @@ public abstract class LocalSettingAttribute(
|
||||
/// <param name="tab">Gets the tab where the setting is located.</param>
|
||||
/// <param name="configEntryBase">Gets the config entry the setting is attached to.</param>
|
||||
/// <returns>The created class.</returns>
|
||||
internal abstract ILocalSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase);
|
||||
public abstract ILocalSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase);
|
||||
}
|
||||
@@ -29,7 +29,7 @@ public class LocalSliderSettingAttribute(
|
||||
private readonly string? _description = description;
|
||||
|
||||
/// <inheritdoc/>
|
||||
internal override LocalSliderSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
public override LocalSliderSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
{
|
||||
return new LocalSliderSetting(tab, configEntryBase, _name, _description, new FloatRange(min, max), displayValue, suffixType, formatString, roundValue);
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ public class LocalToggleSettingAttribute(
|
||||
private readonly string? _description = description;
|
||||
|
||||
/// <inheritdoc/>
|
||||
internal override LocalToggleSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
public override LocalToggleSetting CreateSetting(Type tab, ConfigEntryBase configEntryBase)
|
||||
{
|
||||
return new LocalToggleSetting(tab, configEntryBase, _name, _description);
|
||||
}
|
||||
|
||||
@@ -20,7 +20,10 @@ public abstract class LocalSettingBase<T> : ILocalSetting
|
||||
/// <inheritdoc />
|
||||
public ConfigEntryBase ConfigEntry { get; }
|
||||
|
||||
internal LocalSettingsTab? Tab => LocalSettingsManager.Tabs.FirstOrDefault(x => x.Settings.Contains(this));
|
||||
/// <summary>
|
||||
/// Gets the tab of the local setting.
|
||||
/// </summary>
|
||||
public LocalSettingsTab? Tab => LocalSettingsManager.Tabs.FirstOrDefault(x => x.Settings.Contains(this));
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="LocalSettingBase{T}"/> class.
|
||||
|
||||
@@ -182,12 +182,10 @@ public static class HudManagerPatches
|
||||
entry.Invoke();
|
||||
}
|
||||
}
|
||||
foreach (var entry in KeybindManager.VanillaKeybinds.Values)
|
||||
|
||||
foreach (var entry in KeybindManager.VanillaKeybinds.Values.Where(x => player.GetButtonDown(x.Id)))
|
||||
{
|
||||
if (player.GetButtonDown(entry.Id))
|
||||
{
|
||||
entry.Invoke();
|
||||
}
|
||||
entry.Invoke();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,7 @@ public static class ToggleBehaviourPatch
|
||||
{
|
||||
/// <summary>
|
||||
/// ResetText was inlined ofc.
|
||||
/// Skill issue
|
||||
/// Skill issue.
|
||||
/// </summary>
|
||||
[HarmonyPrefix]
|
||||
[HarmonyPatch(nameof(ToggleButtonBehaviour.UpdateText))]
|
||||
|
||||
@@ -46,4 +46,4 @@ internal static class HowToPlayPatch
|
||||
__instance.roleSelectionScene.SetActive(true);
|
||||
ControllerManager.Instance.SetDefaultSelection(__instance.defaultButtonSelected, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user