public override void DoCollised() { if (_touched == true) { return; } _touched = true; switch (_subtype) { case Subtype_AwardLife: GameMap.instance.ChangeLife(1); break; case Subtype_AwardStar: ActorController.instance.SetMagnet(); break; } DOTween.Play(SptMain.transform.DOMoveY(transform.position.y + 2.5f, 1.0f).SetEase(Ease.InOutBack)); DOTween.Play(SptMain.DOFade(0, 1.5f).OnComplete(() => { GameMap.instance.RemoveActiveElement(this); GameObject.Destroy(gameObject); })); }
public override void HitBottom(bool hitForward) { if (_isBroken == true) { return; } _isBroken = true; DOTween.Play(SptMain.DOFade(0, 0.3f)); DOTween.Play(SptMain.transform.DOMoveY(SptMain.transform.position.y + 0.5f, 0.3f)); }
public override void DoCollised() { if (_touched == true) { return; } _touched = true; _coinCreateIndex = 4; DOTween.Play(SptMain.DOFade(0.2f, 0.5f).OnComplete(() => { GameMap.instance.RemoveActiveElement(this); GameObject.Destroy(gameObject); })); }
public override void DoCollised() { if (_touched == true) { return; } _touched = true; _status = Status_Dead; DOTween.Play(SptMain.transform.DOMoveY(transform.position.y + 2.5f, 1.0f).SetEase(Ease.InOutBack)); DOTween.Play(SptMain.DOFade(0, 1.5f).OnComplete(() => { GameMap.instance.RemoveActiveElement(this); GameObject.Destroy(gameObject); })); }