45 lines
891 B
C#
45 lines
891 B
C#
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
[CreateAssetMenu(fileName = "Setting", menuName = "Settings/Setting"), System.Serializable]
|
|
public class Setting : ScriptableObject
|
|
{
|
|
//general
|
|
[Header("General")]
|
|
public SettingType Type;
|
|
public string Id;
|
|
public string Alias;
|
|
[TextArea] public string Description;
|
|
|
|
//type: Bool
|
|
public bool BoolValue;
|
|
|
|
//type: Int
|
|
public int IntValue;
|
|
public int IntMin;
|
|
public int IntMax;
|
|
public int IntStep;
|
|
|
|
//type: Float
|
|
public float FloatValue;
|
|
public float FloatMin;
|
|
public float FloatMax;
|
|
public float FloatStep;
|
|
|
|
//type: String
|
|
public string StringValue;
|
|
public List<string> AllowedValues;
|
|
|
|
//type: Signal
|
|
public string SignalValue;
|
|
|
|
public enum SettingType
|
|
{
|
|
Int,
|
|
Float,
|
|
String,
|
|
Bool,
|
|
Signal
|
|
}
|
|
}
|