void Update() { if (GameManager.Instance.IsGameStart == false || GameManager.Instance.PlayerIsMove == false) { return; } if (startTimer) { fallTime -= Time.deltaTime; if (fallTime < 0) { //掉落 startTimer = false; if (rg2d.bodyType != RigidbodyType2D.Dynamic) { rg2d.bodyType = RigidbodyType2D.Dynamic; StartCoroutine(CoroutineHelper.DealyHide(gameObject)); } } } if (transform.position.y - Camera.main.transform.position.y < -6) { StartCoroutine(CoroutineHelper.DealyHide(gameObject)); } }