Hi there! Thanks for reading.
Let’s say I have an Actor Component which is derived from UStaticMeshComponent, and in the editor has a check “Simulate Physics”. I would like to hide this option for every user that’s gonna use this derived component. I know about UPROPERTY() and how to hide categories using Specifiers, but not how to hide a certain property that exists in a parent class.
Help is appreciated!
2 Likes
If it’s specifically related to SimulatePhysics, you can use SetSimulatePhysics(false); in the constructor. In general though, you can’t shadow uproperty variables of the parent class as Unreal doesn’t allow it (Maybe because of reflection?)
Thanks for answering Regalith. That’s a pity.I might just stick with designing my own Details panel and pushing the values in the contstructor upwards. I’m still curious though, because the Character class inherits components that are editable in the editor. I’ll just wait a little longer before marking this thread as solved
You can do it if you create your own DetailsPanel with CustomizeDetails. This hides the ComponentTags property from the UActorComponent:
TSharedRef<IPropertyHandle> tagsProperty = DetailBuilder.GetProperty(GET_MEMBER_NAME_CHECKED(UActorComponent, ComponentTags), UActorComponent::StaticClass());
DetailBuilder.HideProperty(tagsProperty);
5 Likes