Make a blueprint change itself in Editor and be able to save those changes? UFUNC property?

So I have come to a point where I have too many SceneComponents on my blueprints. I only need their full transform and tags. Cool, I’ll make a C++ class based off of scene component that holds a TArray<String, FTransform, TArray Tag>. That’s all the info I need. Then I’ll make a function that uses BlueprintCallable and CallInEditor. This should expose that UFUNCTION to BP. Boom easy.

Nope. Adding this new SceneComponent to the actor does not expose that CallInEditor function. So maybe I can make a CallInEditor function on that actor. I have a base actor type. Just add a CallInEditor there, that calls my new MakeFunction. Sort of success, I have to have the actors in game/level to make these conversions. Yep the documentation states that CallInEditor works on instances, not the actual BP actor. Shoot… To be clear, the code works and is in place. I just don’t know how to call a func in editor on a BP itself.

Now I don’t know what my options are. I want to make a list of these scene components, then delete the ones I have a reference of. Do I need to make a blutility? I haven’t made one in a year. I think that could work but isn’t there some way to expose a function to enact changes on the actual BP/Class?

Hi Sluggernot,

Have a look at Editor Utility Blueprints:

Just to make things clear:

  1. You want to read data from a scene component added to an actor.
  2. You want to store that data as a property on the CDO.
  3. You are sure this data is equal for all instances of that blueprint.
  4. Then you want to delete the scenecomponent permanently from CDO.

Sounds like you want to make a backup first, then attempt to modify what is called the “CDO”, the base template of which all instances are made.

Oh shoot, I should have explicitly stated I would manually delete the scene components that I am just using as Transforms with tags. I do want to add this new component to the base BP and then do this for all children. I’ll check it out (CDO) and the other reply is most likely what I will need to do: Make an editor utility. I am not seeing a UFUNC definition that means “Make this function blueprint callable to edit this very blueprint” Thanks for the info!