protected virtual void Update() { if (transform.parent == null) { Destroy(gameObject); } else if (isStartPlanet == false) { if (transform.parent.GetComponent <Sector>().nowSectorTile.index == 4) { targetScale = 0.75f; } else if (transform.parent.GetComponent <Sector>().nowSectorTile.index == 3) { targetScale = 0.9f; } else if (transform.parent.GetComponent <Sector>().nowSectorTile.index == 2) { targetScale = 1.1f; } else if (transform.parent.GetComponent <Sector>().nowSectorTile.index == 1) { targetScale = 1.5f; } } if (isMove == false) { isMove = true; StartCoroutine(CoroutineUtil.LerpMove(this.gameObject, this.transform.position, targetPos, 2)); StartCoroutine(CoroutineUtil.LerpScale(this.gameObject, this.transform.localScale, new Vector3(1f, 1f, 1f) * targetScale, 2)); } }