Hello,
I am creating a custom window in which I want the user to select which properties of a certain prefab will be affected by a certain value (which isn’t relevant for the discussion).
Currently I am manually selecting and showing the fields I am interested in and showing them to the user - such as “Position X”, “Rotation Z”, etc…
Is there I way via code that I can get all the editable fields for a certain component?
This way I would be able to loop through all the components of a certain prefab and thus basically show the user all the fields that are visible for this prefab in the regular inspector.
Thank you!
OK thanks guys I’ll try to find my way around
Have a look at SerializedObject for this. Alternatively, reflection would also work.