Re-cooking / rebuilding an HDA programmatically?

   2344   2   3
User Avatar
Member
606 posts
Joined: May 2007
Offline
Hi all!

Is there a way to recook / rebuild a HoudiniAssetActor in a level programmatically? (preferably Python or BP).
In my case I would have many levels with many instanced HDAs, and I would like to rebuild those without manual work.

I've tried stuff like
    success = levelLib.load_level("/Game/Developers/eetu/BigWorldTest/Sublevel2")
    world_context_object = levelLib.get_editor_world()
    command = 'Houdini.RebuildAll'
    unreal.SystemLibrary.execute_console_command(world_context_object, command)
    time.sleep(5)
    success = levelLib.save_current_level()
but seems like the console command is run after the python script has executed (?) so it does not work the way I would like.

Is there a way to “push” the button? something in the vein of
newAsset.set_editor_property(“rebuild”, True)
?

eetu.
User Avatar
Member
6 posts
Joined: June 2020
Offline
Bumping this, very interested if this is possible
User Avatar
Member
132 posts
Joined: July 2007
Offline
There is an avenue to accomplish this, but it has to be done in C++ AFAIK.
  • Quick Links