During testing, I noticed that restored nested UObjects were being created with their Outer set to the UClass of their containing UObject. Digging deeper, I found that this was being caused by the call to OProp->GetOwnerUObject().
My 'fix' isn't the nicest, but I have been unable to find a way to get back from the given parameters to the containing RootObject.
It could be neater to leave the Outer as nullptr, which will create the object in the transient package, but it feels more 'correct' to set it to the parent UObject.
During testing, I noticed that restored nested UObjects were being created with their Outer set to the UClass of their containing UObject. Digging deeper, I found that this was being caused by the call to OProp->GetOwnerUObject().
My 'fix' isn't the nicest, but I have been unable to find a way to get back from the given parameters to the containing RootObject.
It could be neater to leave the Outer as nullptr, which will create the object in the transient package, but it feels more 'correct' to set it to the parent UObject.