Create blueprint asset file with C++
It's perhaps not too difficult to achieve, but right now I don't find the right information concerning this.
I want to create a new blueprint in C++ as part of an importer module within our project, which I'm writing myself. With that I mean creating an actual full blueprint asset file (not just a node or a function etc.), that goes into the editor's asset browser for content creators to use. I want to be able to define the name, superclass and file path of the blueprint in my function.
What I found so far was this:
I'm don't know how to use this code snipped or what exactly it does (I can only assume it creates an asset) and I also think it's not applicable to what I want to achieve, since I want a blueprint based on a given superclass.
How can I do that?
unfortunately u cannot create a uasset file from any external sources. you need to use the editor for this.
answered Jan 08 '19 at 12:24 PM
I was able to find a function that may help after digging around in the FKismetEditorUtilities:
For my case this works, it creates the asset, saves it, and opens up the blueprint window in editor upon creation, which is all I need. However, as a warning, I ran in to trouble when I tried to save the asset before opening up the blueprint window in editor.
Follow this question
Once you sign in you will be able to subscribe for any updates here