public void StophandAnimation() { if (handImage.gameObject.activeSelf) { EGTween.Stop(handImage.gameObject); handImage.gameObject.SetActive(false); } }
/// <summary> /// Sets the timer For Bar Progress /// this method will set and reset the timer on clearing row and column /// </summary> /// <param name="timerToIncrease">Timer to increase.</param> public void SetTimer(int timerToIncrease = 0) { if (GamePlayMode == GameMode.timer) { EGTween.Stop(gameObject); TimerValue = TimerValue + timerToIncrease; TimerValue = Mathf.Clamp(TimerValue, 0, TotalTimerValue); float currentBarProgress = ((float)TimerValue / (float)TotalTimerValue) * 100F; float barFillValue = (555.0F / (100 / currentBarProgress)); Timer.sizeDelta = new Vector2(barFillValue, Timer.sizeDelta.y); EGTween.ValueTo(gameObject, EGTween.Hash("from", (float)Timer.sizeDelta.x, "to", 0.0f, "time", TimerValue, "onUpdate", "BarProgress", "onComplete", "OnBarCompelete", "onCompleteTarget", gameObject)); } }
/// <summary> /// Raises the disable event. /// </summary> void OnDisable() { EGTween.Stop(gameObject); }
/// <summary> /// Ends the rotation. /// </summary> public void EndRotation() { EGTween.Stop(gameObject); }
/// <summary> /// Updates the speed. /// </summary> void UpdateSpeed() { EGTween.Stop(gameObject); StartRotation(); }
void OnDisable() { GamePlay.OnScoreUpdatedEvent -= OnScoreUpdated; EGTween.Stop(gameObject); currentRing.SetActive(false); }
public void RestartTimer(int _timerValue) { EGTween.Stop(gameObject); TimerValue = _timerValue; SetTimer(0); }