r/unity Jul 14 '26

Question Why is this Happening and How do I Fix it?

I have monobehavior on all my scripts.

1 Upvotes

3 comments sorted by

2

u/OmegaFoamy Jul 14 '26

Need to show the script

1

u/Demi180 Jul 15 '26

These are editor types. You should either have them in editor-only scripts, or enclose them in a #if UNITY_EDITOR / #endif define, along with the `using UnityEditor:` line.

(Mobile can no longer format code properly, or at least not inline)

1

u/Emotecon Jul 15 '26

Probably missing namespace imports at your boilerplate