miwarnec / DOTSNET

Public DOTSNET issue tracker
20 stars 0 forks source link

Example Scene's some GameObjects are not set correctly #44

Closed Codeyounglings closed 3 years ago

Codeyounglings commented 3 years ago

Describe the bug bug 1. example scene's ground is converted to entity into Default World bug 2. example scene's some systems has set to 'ConvertAndInjectGameObject'

To Reproduce to Reproduce bug 1

  1. go to Benchmark example scene
  2. click GameObject 'Ground'

to Reproduce bug 2

  1. go to Benchmark example scene
  2. click GameObject 'PrefabSystem'

Expected behavior bug 1 : it should be attached 'ConvertToNetworkEntity' to both world bug 2 : it should be destroyed after conversion

Additional context For those newbies like me using URP with Hybrid Renderer V2 didn't know that can see only Client World.

But example scene's Ground GameObject is Converted to entity into default World I spent a lot of time to figure out why I can't see this Ground But for the future newbies, Ground and other SystemAuthoring GameObjects should not be send into Default World and also should not be injected after game starts

Codeyounglings commented 3 years ago

I found that if I destroy all of them after conversion, some scripts like NetworkClientHUD will be destroyed so can't do anything at game

so scripts which not to be disappeared should be sperated into different GameObjects

miwarnec commented 3 years ago

thanks for explaining. added a chapter to docs: https://dotsnet.gitbook.io/docs/user-manual/hybrid-renderer-v2-urp

miwarnec commented 3 years ago

ground is now converted to network entity. are you sure prefab system causes issues? if yes, please reopen.