explicitClick to confirm you are 18+

[ReadOnly] Attribute for Unity Editor

AntonSemJun 26, 2019, 7:54:24 PM
thumb_up2thumb_downmore_vert

Read the full version on my blog. I'm not gonna write the whole thing here, because there is no code tags and it is hard (and useless) to take screenshots. Just visit the blog if you are interested. Here is the summary:

There are certain cases when you want to see a variable in the inspector but don’t want to change it. Sadly, there is no default solution for that in Unity. But with a little work, you can do it for yourself. Enter the world of editor scripting!

Read-Only float

Get the full code from the GitHub and check out my other blog posts. Let me know if you have any suggestions or if you know any other patterns. Suggestions for future posts are also very much welcome!