-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRestart.cs
More file actions
executable file
·44 lines (36 loc) · 975 Bytes
/
Copy pathRestart.cs
File metadata and controls
executable file
·44 lines (36 loc) · 975 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
using UnityEngine;
using System.Collections;
public class Restart : MonoBehaviour {
//public GUIStyle ResetStyle;
public GameObject ImageTarget;
//public bool ShowResetBtn;
//public bool tempShowResetBtn;
public GameObject AnimatedBuilding;
// Use this for initialization
void Start () {
//ShowResetBtn = false;
}
void OnClick()
{
//ImageTarget.GetComponent<LogicControl>().StartAnimation = true;
//ShowResetBtn = false;
AnimatedBuilding.GetComponent<AnimationStatus>().AnimationStart();
audio.Play();
}
/*void OnGUI () {
float btn = (Screen.height/8.0f); //Unit of Buttons
float sw = Screen.width;
float sh = Screen.height;
float sc_x = Screen.width/2f;
float sc_y = Screen.height/2f;
if(ShowResetBtn)
{
if(GUI.Button(new Rect(0.5f*btn, (sh-2f*btn), (3f*btn), (1.5f*btn)), "Reset", ResetStyle))
{
ImageTarget.GetComponent<LogicControl>().TriggerReset = true;
ShowResetBtn = false;
}
}
}
*/
}