@dotstdy IME there are few “right answers” for these questions, only trade offs that are hard to reason about from the present. What matters more is users knowing and relying on specific behaviors.
A big benefit of USD is standardizing behavior to work a single way.
IME with past engines all inherited properties are sparsely persisted in the child assets. So defaults change everywhere they weren’t specified. You can then make features to “freeze” assets to bake defaults if the user wants.
@dotstdy @gorlak The float approach is tricky, since every add-in-between needs a bit. There are ways to deal with that, but the fractional indexing may need arbitrary amount of bits.
Another way is to use ID per array element. Some of the solutions that does the array merging "right" feel surprisingly random in action (e.g. interlacing).
I made a system a while back which used IDs for array elements, and stored a flag on the derived data if it was added/changed/deleted.
The merging was simply looking for runs of changes vs keeps, and favored the explicit changes. It was able to keep the changes at the beginning and end of the array (which was the most common case).
It did not go through a production, so I cannot say if others liked how it worked, I did :)
@dotstdy @gorlak
Yeah, the unordered set behavior is super simple, things get tricky when you want specific ordering. I put the sorted array to the unordered, since we dont care during the merge.
Most use cases I have had to solve, the ordering did not matter, but it sure is annoying if your arrays shuffle around seemingly at random. Or that new things appear at random position.