Inspector attribute for showing a field with a custom name? Possible?

Hullo!

I have a UI class containing a load of settings for different elements in my game. I like to keep my inspector tidy using attributes. But here’s my question. Can I somehow display a field in the inspector with another name than the name of the actual field in script, obviously while keeping the same name in the script? For example, the class contains settings for two types of texts, both these text have a default position that I change in the inspector. At the moment I have something like this:


Text 1:

Text Number One Position X [ … ]

Text Number One Position Y [ … ]

Text 2:

Text Number Two Position X [ … ]

Text Number Two Position Y [ … ]


What I’d like to achieve is having the inspector display something like the following:


Text 1:

Position X [ … ]

Position Y [ … ]

Text 2:

Position X [ … ]

Position Y [ … ]


Custom Editors will help you out of the misery :wink: