mirror of
https://github.com/All-Of-Us-Mods/MiraAPI.git
synced 2026-10-20 11:39:45 +00:00
33 lines
855 B
C#
33 lines
855 B
C#
using MiraAPI.GameOptions;
|
|
using MiraAPI.GameOptions.Attributes;
|
|
using UnityEngine;
|
|
|
|
namespace MiraAPI.Example.Options;
|
|
|
|
public class ExampleOptions : AbstractOptionGroup
|
|
{
|
|
public override string GroupName => "Example Options 1";
|
|
public override Color GroupColor => Color.green;
|
|
|
|
[ModdedToggleOption("Toggle Opt 1")]
|
|
public bool ToggleOpt { get; set; } = false;
|
|
|
|
[ModdedToggleOption("Toggle Opt 2")]
|
|
public bool ToggleOpt2 { get; set; } = true;
|
|
|
|
[ModdedNumberOption("Number Opt", min: 0, max: 10)]
|
|
public float NumberOpt { get; set; } = 4f;
|
|
|
|
[ModdedStringOption("String Opt", ["Hello", "Hey", "Bye"])]
|
|
public int StringOpt { get; set; } = 2;
|
|
|
|
[ModdedEnumOption("Enum Opt", typeof(TestEnum))]
|
|
public TestEnum EnumOpt { get; set; } = TestEnum.Mira;
|
|
}
|
|
|
|
public enum TestEnum
|
|
{
|
|
Welcome,
|
|
To,
|
|
Mira
|
|
} |