我无法销毁StandardAssets

时间:2019-02-10 08:53:02

标签: c# unity3d

我想破坏水对象。 但是读取Destroy()时出现错误。 资产/标准资产/环境/水

我想摧毁这个↓

enter image description here

*控制台:*

Destroying GameObjects immediately is not permitted during physics trigger/contact, animation event callbacks or OnValidate. You must use Destroy instead.
UnityEngine.Object:DestroyImmediate(Object)
UnityStandardAssets.Water.Water:OnDisable() (at Assets/Standard Assets/Environment/Water/Water/Scripts/Water.cs:184)
UnityEngine.GameObject:SetActive()
GameController:DestroyBeforePuddle() (at Assets/Scripts/GameController.cs:52)
PlayerMovement:OnTriggerEnter(Collider) (at Assets/Scripts/PlayerMovement.cs:47)

我如何销毁它?

0 个答案:

没有答案