Injecting Game Objects?

I’m a little confused with how it works currently (or rather doesn’t). When Convert And Inject option is selected, the object still get’s destroyed. Why is that happening?

I wanted to create my own system to serialize and keep references to managed component in IComponentData as int keys and a database that will provide the actual objects. But that’s more work than I expected and I could use the injection instead. But…

  1. Why doesn’t it work for me?
  2. I think, injection used to create a lot of extra archetypes which led to performance degradation should that still be a concern?
  3. What is “ConvertToEntity (Stop)” script?

Are there other downsides to consider in regards to injecting game objects?

There was a bug in Entities 0.2 that caused the Convert And Inject to destroy the object instead. It was fixed in Entities 0.3

Cool, thanks.

Now since it works and I can test it, I can see that it stops conversion at a given transform hierarchy depth, which is perfect, exactly what I needed.