using UnityEngine;
using System.Collections;
public class slideTest : MonoBehaviour
{
// Use this for initialization
float horValue;
float verValue;
void Start ()
{
}
// Update is called once per frame
void Update ()
{
}
void OnGUI()
{
horValue = GUI.HorizontalSlider (new Rect (10, 10, 100, 20), horValue, 0, 100);
verValue = GUI.VerticalSlider (new Rect (10, 40, 20, 100), verValue, 0, 100);
GUI.Label (new Rect (10, 160, Screen.width, 30), "横向进度条值" + horValue);
GUI.Label (new Rect (10, 190, Screen.width, 30), "纵向进度条值" + verValue);
}
}
using System.Collections;
public class slideTest : MonoBehaviour
{
// Use this for initialization
float horValue;
float verValue;
void Start ()
{
}
// Update is called once per frame
void Update ()
{
}
void OnGUI()
{
horValue = GUI.HorizontalSlider (new Rect (10, 10, 100, 20), horValue, 0, 100);
verValue = GUI.VerticalSlider (new Rect (10, 40, 20, 100), verValue, 0, 100);
GUI.Label (new Rect (10, 160, Screen.width, 30), "横向进度条值" + horValue);
GUI.Label (new Rect (10, 190, Screen.width, 30), "纵向进度条值" + verValue);
}
}