Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

C++ Derived Blueprint: Inherited Component Properties not editable

Repro Steps:

1 Create c++ classes: one derived from actor, one derived from actor component

2 Create a editable UPROPERTY variable in the actor component

3 in the actor derived class Create a Default Subobject of the actor component and save as UPROPERTY variable, so it is editable

4 create a blueprint derived from our c++ actor class and compile

5 change the UPROPERTY in our actor component (for example add the "BlueprintReadWrite" specifier) and recompile

6 try to edit the UPROPERTY of our inherited actor component in the BP Class

to temporarily resolve the issue

1 comment out the line, where you CreateDefaultSubobject for our component

2 compile

3 uncomment the line

4 compile

Product Version: UE 4.12
more ▼

asked Jun 29 '16 at 10:51 AM in Bug Reports

avatar image

249 27 36 71

avatar image Matthew J Jul 01 '16 at 02:38 PM

Hello AllJonasNeeds,

From this workflow, the Actor Component variable and its UPROPERTY should never be editable inside of the blueprint editor. The bug here is actually that it is editable in this case. I'll be putting in a bug report for that.

To be able to edit the Actor Component in the Blueprint Editor, be sure to add the BlueprintReadWrite specifier to the Actor Component UPROPERTY inside of your Actor class. After doing this, it should be editable from inside of the Blueprint Editor whether the blueprint was already created or if it is created afterwards.

avatar image Matthew J Jul 12 '16 at 03:41 PM

I had a question about your reproduction steps, when you mention to make a "editable UPROPERTY" do you mean give it the specifier "EditAnywhere"?

avatar image AllJonasNeeds Jul 12 '16 at 07:04 PM

I can't check that this week, but I am sure I meant either EditAnywhere or EditDefaultsOnly. EditAnywhere more likely. Sorry for not being as clear as possible.

avatar image zeOrb Aug 19 '17 at 03:03 PM

I've bumped into the same problem and was able to understand more details about this issue:

  1. It happens only with already existing blueprints. If after meddling with UPROPERTY you create another BP based on C++ class then it will works fine, until you change UPROPERTY meta tags again.

2.Commenting out, compiling, uncommenting, compiling did not restore my old BPs, however after I reparented BP in Class settings to Actor and then restored parent back to my C++ class - everything was restored correctly. Due to updates in 4.17 all pins remained unharmed and I lost only some customization of default values on pre-existing components.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

3 answers: sort voted first

Hello AllJonasNeeds,

I apologize for the delay, I gave reproducing this a try again but can't get it to occur. I'll give exact steps w/ code to show what I did. Maybe you'll be able to see where I went wrong.

  1. Created a blank C++ project

  2. Added two classes, MyActor (Actor) and MyActorComponent (ActorComponent.)

  3. Inside of MyActorComponent, I created the following UPROPERTY:

    UPROPERTY(EditAnywhere) bool MyVariable;

  4. Inside of MyActor.h I created a UPROPERTY with EditAnywhere for a MyActorComponent variable and initialized it in the constructor with CreateDefaultSubcomponent

  5. I created a blueprint based off MyActor and then compiled the code.

  6. I added BlueprintReadWrite to the UPROPERTY from step 3 and compiled.

  7. I was able to edit MyVariable inside of the MyActor blueprint.

Full code at the end

more ▼

answered Jul 29 '16 at 09:10 PM

avatar image AllJonasNeeds Jul 30 '16 at 01:08 PM

Hi Matthew,

In your step 6, make sure you edit the UPROPERTY specifiers in MyActor.h. You do not need to change the UPROPERTY specifiers in MyActorComponent.h. That said I am now unable to reliably reproduce the issue. I was only able to reproduce the bug once. I believe I was using the following UPROPERTY specifiers, when the bug occured:

 UPROPERTY(VisibleAnywhere, BlueprintReadWrite)
         class UMyActorComponent* MyActorComp;

But since then I was unable to reproduce the bug. To me it seems like the updates to 4.12 inbetween the bug report and now have changed when the bug occurs.

I am sorry that I can not give you instructions to reliably reproduce the bug.

avatar image Matthew J Aug 01 '16 at 02:24 PM

It's okay. I'll be marking this as resolved for now. If you do eventually come up with a solid reproduction case, please feel free to reopen this and we can continue.

avatar image _h2o_ Sep 26 '16 at 08:13 PM

I can confirm that i have this issue too. Also other's guy thread about same issue for statistics :) https://answers.unrealengine.com/questions/369955/c-derived-blueprint-edit-inherited-component-prope.html

My 5 cents: I do not know if it starts since 4.12 or not, but i have this now in 4.12. Many (not all) inherited components from many different classes not editable in editor. For example if i open some BP created from c++ class where in constructor i created component - then i see on details tab that component is None and no properties. I have checked, constructor is executed, pointer is valid, also this component is working fine if you run play in editor.

for example i have this issue with character BP which is created from class extended from ACharacter and with added in code springarm and camera component. Both components have no properties in details pannel.

Also temp solution method provided by AllJonasNeeds is not helped me. To see and edit properties again i do so:

  1. comment code lines in constructor about CreateDefaultSubobject

  2. compile

  3. run editor

  4. Open BP, recompile, save

After that

  1. uncomment code lines in constructor about CreateDefaultSubobject

  2. compile

  3. run editor

  4. Open BP - and everything is fine now.

avatar image Matthew J Sep 27 '16 at 03:45 PM

Hello h2o,

What kind of UPROPERTY specifiers are you using for these properties? You mention that only some of the inherited components are having this issue. Is it certain types or does it just vary on a case-by-case basis? Some code examples would be helpful, as I'd like to have this reproduced on my end.

avatar image Cobryis Sep 28 '16 at 06:24 PM

I have this same property and I'm using the same UPROPERTY specifiers as the other, working components.

 // works
 UPROPERTY(VisibleDefaultsOnly, BlueprintReadOnly, Category = "Mesh", meta = (AllowPrivateAccess = true))
     USkeletalMeshComponent* Mesh;
 // doesn't work, this is a class that inherits from UPawnMovementComponent and really doesn't do much.
 UPROPERTY(VisibleDefaultsOnly, BlueprintReadOnly, Category = "Movement", meta = (AllowPrivateAccess= true))
     UVehicleMovementComponent* VehicleMovementComponent;

Something is very wrong with 4.12. I've had a C++ class get corrupted and the blueprint that inherited from it would work when created, but when I reloaded the editor it would say it references an invalid class. Now I have two separate, custom components, one a SceneComponent and the other a ActorComponent, that are broken in blueprint classes. My VehicleMovementComponent in particular works when I first create my blueprint derived from my Vehicle C++ class. But when I save it and reload the edtior, the component is now "none".

EDIT: Removed a line on what I thought was a shared trait between the two components. Turns out it's not..

alt text

avatar image Cobryis Sep 28 '16 at 06:35 PM

Oh and please don't say that the component should be set to EditAnywhere or EditDefaultsOnly. That just messes up the presentation in the details panel and is not what you guys do in your own engine: // from Character.h

 UPROPERTY(Category = Character, VisibleAnywhere, BlueprintReadOnly, meta = (AllowPrivateAccess = "true"))
     class UCharacterMovementComponent* CharacterMovement;
avatar image Cobryis Sep 28 '16 at 07:06 PM

Here is the component showing up when I make a new blueprint and save it. But still, after reloading the editor it's broken.

alt text

avatar image Cobryis Sep 28 '16 at 08:05 PM

The temporary solution provided in the OP is in fact very temporary. As soon as you reload the editor after getting the 'new' component to show up, the component is broken again. Even if it did work it would ruin derived classes that were not experiencing this issue and had many properties already set.

avatar image Cobryis Sep 28 '16 at 08:49 PM

My workaround:

Same thing I had to do to fix the corrupted C++ actor class I mentioned. I had to rename the whole C++ component class. Now it doesn't seem to be an issue. This is entirely insane though.

avatar image Matthew J Sep 29 '16 at 10:15 PM

Hello Cobryis,

I'm looking into this now and I'm currently seeing the same results, the oddest thing is that it seems that I'm using the same implementation as CharacterMovement in Character.h, as you mentioned.

As far as EditAnywhere goes, one thing that does show is that this seems to be the pointer just getting cleared when saving and restarting the editor. This is due to when you set this to EditAnywhere, restart the editor, and then check the component, you can hit the yellow arrow beside the "None" dropdown and it'll reset to default, filling that slot with the DefaultSubcomponent created in the constructor.

I'm going to ask around a bit to ensure that I'm doing this right then I'll be putting in a bug report if so. Thank you for bringing this up.

avatar image Matthew J Oct 06 '16 at 05:58 PM

Hello Cobryis,

I was just about to put in a bug report but wanted to make sure I had the reproduction case down before doing so and now I can't get it to occur for some reason. It's possible that I'm missing something so I'll list what I'm doing here, let me know if this seems off.

  1. Create a C++ project, add a new C++ class based off Pawn

  2. In the .h, add the following code to declare the components:

    UPROPERTY(VisibleDefaultsOnly, BlueprintReadOnly, Category = "Mesh", meta = (AllowPrivateAccess = true)) USkeletalMeshComponent* Mesh;

       UPROPERTY(Category = Character, VisibleAnywhere, BlueprintReadOnly, meta = (AllowPrivateAccess = "true"))
             class UCharacterMovementComponent* CharacterMovement;
  3. In the .cpp, add the following code to initialize these components:

    Mesh = CreateDefaultSubobject(TEXT("Mesh")); CharacterMovement = CreateDefaultSubobject(TEXT("CharacterMovement"));

  4. Compile the project

  5. Return to the editor and create a blueprint based off the custom Pawn class

  6. Check the blueprint to ensure that the details are available, save, restart the editor

At this point I would expect to see a blank details panel with that "None" entry but I'm still seeing the details.

avatar image Cobryis Oct 13 '16 at 05:03 PM

As I said before, it's not at all consistent. And I didn't have the issue with CharacterMovement. I was just showing that I was implementing my own components in the same fashion.

I don't have a repro for this really, it hasn't been consistent. You need to have your engineers look at how a component that is not optional could ever be listed as "None" in a blueprint subclass.

I can tell you what I did in the first scenario. We had a component that was only an ActorComponent. I changed it to a SceneComponent, and most implementing blueprints were fine. Except one, where the component was now listed as none and nothing I did would fix it except to recreate the blueprint from scratch.

In the second scenario, I think I changed the optional-ness of a component maybe? I don't know. In either case, blueprints inheriting a native parent class's component seem to break very easily if some profound aspect of that component has changed.

avatar image Matthew J Oct 14 '16 at 02:50 PM

After doing some testing, I can actually only get this to reproduce when using UWheeledVehicleMovement as my UPROPERTY. That ends up reproducing the "None" issue. Do you have any examples of other types of components that this has happened with or is it only UWheeledVehicleMovement? I'm ready to put a bug report in for this issue but I just want to make sure that I get as many examples as possible of components that are having this issue.

avatar image Cobryis Oct 17 '16 at 07:08 PM

For me, it's not UWheeledVehicleMovement. My VehicleMovementComponent is entirely custom and does not derive from WheeledVehicleMovement. Both of the components this has happened to are custom components, derived from either ActorComponent or SceneComponent.

avatar image _h2o_ Oct 05 '16 at 04:39 PM

Hello, Matthew Clark. I have tried many different UPROPERTY specifiers but it not solve this issue, also this is not a reason of this issue. And it happens randomly with classes, maybe after engine update, i do not know. I just can not any more edit this properties until i do things i have wrote about here

For example, i have a class:

 class ATeamPlayerStart : public APlayerStart
     AANX_PlayerStart(const FObjectInitializer& ObjectInitializer);
     UPROPERTY(EditInstanceOnly, Category = Team)
     ETeams Team;

I have a blueprint created from this class. And i can not see any properties of capsule component in editor detail window.

alt text

sdfsdf.jpg (385.9 kB)
avatar image Matthew J Oct 06 '16 at 05:13 PM

Hello h2o,

This is due to you making a blueprint based off a class that is inheriting that CapsuleComponent from PlayerStart. PlayerStart inherits its CapsuleComponent from NavigationObjectBase. When it is declared there, it is a UPROPERTY with no specifiers. You'll get the same result if you try to make a blueprint of a normal PlayerStart as well. This is intended. If you'd like these to be available in blueprints, I would suggest using a source version of the engine and adding the specifers to NavigationObjectBase's declaration of the CapsuleComponent, as this isn't related to the original issue.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users


I've spent a good amount of time trying to get this issue to reproduce reliably but haven't been able to manage to get it happen at all recently, even using UWheeledVehicleMovementComponent as mentioned previously. Unfortunately there isn't much more I can do without a reproduction of some sort. I'm going to mark this as resolved for now for tracking purposes. If you are able to find a lead on how to reproduce this issue, please feel free to comment.

more ▼

answered Nov 07 '16 at 07:38 PM

avatar image Furinyx Jan 17 '17 at 07:14 AM

I have spent two days trying to solve this issue with no luck in 4.14. Things were working fine and all of a sudden I get this issue and it has completely broken my Blueprint classes. Changing to VisibleAnywhere and BlueprintReadOnly is the only thing that works most of the time, setting to EditAnywhere breaks customisation and BlueprintReadWrite seems to make no difference.

My scenario is that I have a UStaticMeshComponent* on my C++ Actor class which I am applying a mesh and scale to via a Blueprint-derived class. My C++ Actor class also has a pointer to a C++ class that derives from UActorComponent. This C++ UActorComponent-derived class also contains a UStaticMeshComponent* so that it can store a reference to the actor's mesh component for applying movement functionality to it.

I have tried removing all functionality and properties from the UActorComponent-derived class and then just added a UStaticMeshComponent* to it (no functionality in the CPP file, it doesn't create one or anything); with or without stating it as a UPROPERTY in the Component class, it has the same result. Also, when the Blueprint class of the Actor is added to a map and then the Blueprint Editor is opened, it causes an onslaught of "Ensure condition failed: PropertyNodeMap.ParentProperty == CurObjectNode" errors. I'm not sure what that means or if it is a different problem but hopefully it is relevant.

Let me know if anything else can help; it is extremely random so I am not sure how to give reliable reproduction steps but will see if I can come up with something that continues to reproduce this.

avatar image Furinyx Jan 17 '17 at 07:39 AM

The errors I was getting are unrelated, it was a recursion issue with using PostEditChangeProperty.

It seems the main way to reproduce the edit issue is changing from VisibleAnywhere to any other value (EditDefaultsOnly/EditAnywhere/etc) but I started having the issue well before I changed the UPROPERTY from VisibleAnywhere to something else. Sometimes it just completely blanks out the detail page without showing anything and other times it only shows some of the details.

avatar image M-Pixel Mar 30 '18 at 02:05 AM

I've run into this issue several times today. Make blueprint from class, change some things in the C++ base, then a seemingly random subset of the components lack Details. Could you point out where in the source code I might set some breakpoints in order to figure out what is happening differently when I select one component (whose Details work) versus another (whose details are invisible)?

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

I think the more simple solution is to only change the variable name (with the rename feature on the visual studio), and compile the project. With that the component details on the BP will show again and non of the BP data is lost.

more ▼

answered Apr 04 '19 at 02:59 PM

avatar image


(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question