Closed Podden closed 1 month ago
I found this bug but don't know if this is the right place to fix.
Nice find, massive thanks 🙏
The IsNullComponent
property should probably be checking if Type
is null rather than having a manual assignment:
public bool IsNullComponent => Type == null
.
Would you be able to make another commit changing it to that and then using that in place of the fix? This will encapsulate the check for easy reuse.
I can also merge in and then modify afterwards to be as such (but would rather you have credit)
At some point I should maybe revise how Item types are evaluated as valid so there aren't as many checks all over the place
I've picked a different apporach for performance reasons. You're checking the component for null only once so it seems okay to check the type only one as well and not on every IsNullComponent Call. If you're not okay with this, feel free to implement it yourself, I don't mind not getting credit ;)
I've found another problem: The Scene get's dirtied every frame as soon as there is a gameobject with a component on it (except Transform). I've pushed a fix for that but don't know all the implications when I moved the SetDirty
Call to SetActive
instead of UpdateActiveState
. Maybe you could have a look as well.
Apologies for the delay - I've been trying to speed up time with this but actual work kinda makes it a bit troublesome. I'll push this in appreciate it! 🙏
Missing Script Components on GameObjects throw NullException when UpdateActiveState is called, resulting in a broken Hierarchy Window from this GameObject onward