void Awake() { Time.timeScale = 1; Rect initPixelInset = new Rect(0, 0, 1, 1); initPixelInset.height = Screen.height * 0.10f; initPixelInset.width = initPixelInset.height * 3f; initPixelInset.x = Screen.width * 0.05f; initPixelInset.y = -Screen.height * 0.475f; guiTexture.pixelInset = initPixelInset; color = guiTexture.color; color.a = 0; guiTexture.color = color; Gameflow.SetDifficulty(Gameflow.MEDIUM); // animation timeLeftAnimationChange = timeBetweenAnimationUnS; this.active = true; animationIndex = 0; timeLeftAnimationChange = timeBetweenAnimationS; currentAnimation = texturesS; easyButton.noActive(); hardButton.noActive(); animationForward = true; animationIndex = 0; }
public void OnMouseEnter() { if (!Gameflow.IsDifficulty(Gameflow.EASY) && !Gameflow.IsDifficulty(Gameflow.MEDIUM) && !Gameflow.IsDifficulty(Gameflow.HARD)) { Gameflow.SetDifficulty(Gameflow.MEDIUM); } selected = true; animationIndex = 0; timeLeftAnimationChange = timeBetweenAnimationS; currentAnimation = texturesS; }
public void OnMouseUpAsButton() { audio.PlayOneShot(level_hard); this.active = true; animationIndex = 0; timeLeftAnimationChange = timeBetweenAnimationS; currentAnimation = texturesS; easyButton.noActive(); normalButton.noActive(); // easy button NO active // normal button NO active Gameflow.SetDifficulty(Gameflow.HARD); }