Hello,
I am working with a few objects with particle systems attached. I am attempting to disable and re-enable these objects withe gameObject.setActive(false) and gameObject.setActive(true) respectively and while setActive(false) works fine I cannot seem to get setActive(true) to function. I am calling both from a parent object, so I am not just skipping the code to re-enable the gameObject.
My disabling code.
for (int i = 0; i < _Rain.Length; i ++) {
for (int x = 0; x < _Rain*.particleEffect.Length; x ++) {*
<em> _Rain *.particleEffect [x].gameObject.SetActive (false);*</em>
_* }*_
_*}*_
_*```*_
_*My enabling code.*_
_*```*_
_* if (x == rainAmount) {*_
<em>* for (int y = 0; y < _Rain[x].particleEffect.Length; y++) {*</em>
<em>* _Rain [x].particleEffect [y].gameObject.SetActive (true); *</em>
_* }*_
_*```*_
_*These are both called from a co-routine in a seperate object and class from the particleSystem.*_