I have bunch of UPROPERTIES declared as public(because I need access to the from Blueprint).
But since they are public I can access to them by simply
And assign value by
Class->PropertyName = value.
Which honestly bothers me a bit. I need these properties to be accessible trough all blueprints (not just blueprint that derive from base class where property was declared). So Declaring them as public seem good idea in first place.
But then when I modify them in C++, I don’t have to use any Getters or Setters. I know I can just declare them anyway… But who will use them if they can just access property directly ?
My question though is. Is it good idea to declare UPROPERTIES that need to be access trough all blueprint as public, and just be careful in C++ or it is better to make them protected and create custom Getters, Setters for other blueprints to access them ?