![](https://img-blog.csdnimg.cn/20201014180756738.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Unity
亚&&黑
这个作者很懒,什么都没留下…
展开
-
灭火,粒子碰撞,水
1.创建粒子系统,水 2.脚本 利用粒子系统的显示、隐藏,来实现水的开关 ///水粒子 public GameObject water;//水 //水粒子灭火 if (Input.GetMouseButton(1))//鼠标右键被持续按下,开水粒子系统 { water.SetActive(true); }else if (Input.GetMouseButtonUp(1))//右键抬起,水粒子系统关闭 { water.SetActive(false); } ...原创 2020-10-07 08:55:42 · 358 阅读 · 1 评论 -
灭火,粒子碰撞
1.创建粒子系统:火 2.创建脚本 /// /// 灭火 /// public ParticleSystem pa;//粒子系统 public Text text;//粒子系统的提示 // Use this for initialization void Start () { pa.startSize = 2;//设置初始粒子大小为2 } // Update is called once per frame void Update () { } //火焰被碰撞时 void OnPartic原创 2020-10-07 08:49:57 · 296 阅读 · 0 评论