Skip to content
Snippets Groups Projects
Commit 2be9b753 authored by Mees's avatar Mees
Browse files

Progress Script

parent 8abe851a
No related branches found
No related tags found
No related merge requests found
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
public class Progress : MonoBehaviour {
Slider slider;
int i;
void Start()
{
slider = GameObject.Find("ProgressBar").GetComponent<Slider>();
i = 0;
}
public void ChangeValue(int change)
{
slider.value += change;
}
void Update()
{
if (i == 100)
{
i = 0;
ChangeValue(-1);
}
else
i++;
}
}
fileFormatVersion: 2
guid: 4dd3c6af294b0934e9d7e782b33664ae
timeCreated: 1456835672
licenseType: Free
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment