mirror of
https://github.com/Cardidi/dotween-upm-fork.git
synced 2025-12-21 01:36:05 +08:00
22 lines
493 B
C#
22 lines
493 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using DG.Tweening;
|
|
|
|
public class IndexOutOfRangeOnKill : BrainBase
|
|
{
|
|
IEnumerator Start()
|
|
{
|
|
transform.DOScale(Vector3.zero, 1000).OnKill(() => transform.gameObject.SetActive(false));
|
|
yield return new WaitForSeconds(1.5f);
|
|
transform.DOKill();
|
|
Debug.Log("Start() completed");
|
|
}
|
|
|
|
|
|
void OnDisable()
|
|
{
|
|
Debug.Log("OnDisable()");
|
|
transform.DOKill();
|
|
}
|
|
} |