When using the Level instance Edit, the moment I click save, it edits as expected, but the packed level actor has a side effect of cleaning out the custom primitives that were set before. I imagine it’s a bu,g and the expected behavior would be to keep the previous state.
Hello,
It seems this is a known issue, as I found an internal ticket on the subject. Unless you edit the PLA in place, it will not be automatically updated even if you edit the source level some other way. I’ll try to take a look next week to see if there’s perhaps an easy fix, and I’ll update you if so.
Thanks,
Ryan
I guess is not such an easy update, correct?
I’m sorry. I haven’t had much time, honestly. At a glance, I think you might be able to make a quick change in ULevelInstanceSubsystem::CommitLevelInstanceInternal to check if there are any PLAs associated with the world asset, and if so, call APackedLevelActor::OnCommit to update the BP of the PLA.
-Ryan
Existing code can be used to update all the packed blueprints associated with the level. See FLevelInstanceMenuUtils::UpdatePackedBlueprintsFromMenu, which is called when right-clicking a level in the content browser to “Update Packed Blueprints.”
I’ve requested a review from the team to introduce a cVar to auto-update the packed BPs on commit, and I’ll let you know if it’s approved.
-Ryan
Submitted the new cVar levelinstance.ShouldAutoUpdatePackedBlueprintsOnCommit (disabled by default) with cl 43491894 (UE5-Main).
-Ryan