XDracam / unity-corelibrary

Collection of classes and extension methods that make life with Unity3D more comfortable
MIT License
15 stars 3 forks source link

InPercievable should disable Queryables #22

Closed Eregerog closed 5 years ago

Eregerog commented 5 years ago

Since the idea behind inpercievablility is to have the good things of disabeling a gameObject (no colliders, no renderers) without the bad ones (continued coroutine and sound execution), it might make sense to also disable all Queryables when an object is made inpercievable. Therefore SetPercievable can be used in the same way for the query system, since AllActive will not return objects that are (almost) no longer active, or, at any rate, not really meant to be active.