You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
CrowdControl/Assets/Plugins/NaughtyAttributes/Scripts/Test/ProgressBarTest.cs

36 lines
742 B
C#

using UnityEngine;
namespace NaughtyAttributes.Test
{
public class ProgressBarTest : MonoBehaviour
{
[Header("Constant ProgressBar")]
[ProgressBar("Health", 100, EColor.Red)]
public float health = 50.0f;
[Header("Nested ProgressBar")]
public ProgressBarNest1 nest1;
[Header("Dynamic ProgressBar")]
[ProgressBar("Elixir", "maxElixir", color: EColor.Violet)]
public int elixir = 50;
public int maxElixir = 100;
}
[System.Serializable]
public class ProgressBarNest1
{
[ProgressBar("Mana", 100, EColor.Blue)]
public float mana = 25.0f;
public ProgressBarNest2 nest2;
}
[System.Serializable]
public class ProgressBarNest2
{
[ProgressBar("Stamina", 100, EColor.Green)]
public float stamina = 75.0f;
}
}