Error when install NetCode package: : 'World' does not contain a definition for 'Active' and no accessible extension method 'Active' accepting a first argument of type 'World' could be found
I start learning the new Unity Netcode by this manual: https://docs.unity3d.com/Packages/com.unity.netcode@0.0/manual/getting-started.html
But when I install the package Unity Net Code, it comes out with error:
Library\PackageCache\com.unity.netcode@0.0.4-preview.0\Runtime\ClientServerWorld\ServerSimulationSystemGroup.cs(74,19): error CS1061: 'World' does not contain a definition for 'Active' and no accessible extension method 'Active' accepting a first argument of type 'World' could be found (are you missing a using directive or an assembly reference?)
The console marked with red error and prevented me compiling code. (My project has only one emty GameObject named SharedData, with no other script)
What I've tried: - I think that it need Entities, Hybrid Renderer, and Transport packages installed first, so I remove NetCode, then install all these packages above, then install NetCode again --> still doesn't work - I've search in the internet but found nothing relate to this issue
Does anyone have solution for this? I'm new to Unity, I appreciate your help.
Answer by IgnitedGames · Feb 23, 2020 at 11:44 PM
Got the same problem. It seems to be coming from these few lines appearing in multiple scripts, for example:
ServerSimulationSystemGroup
ClientInitializationSystemGroup
ServerInitializationSystemGroup
ClientPresentationSystemGroup
Whatever that pragma warning disable 618 thing is, it isn't working
After doing some experimenting with #pragma warning disable, and #pragma warning disable 1061 (because that was the error code), I have not been able to get a different result. This is probably a development thing, it should work again in a new version where they remove this.
So maybe I should wait for the new co$$anonymous$$g update. Thanks for your help. I'm waiting too long for NetCode, so a little more is ok :D
absolutely relatable man, hopefully they fix it soon
Answer by Tom60chat · Feb 25, 2020 at 10:44 AM
A new version of Unity NetCode 0.1.0 fixes this error.
On Package $$anonymous$$anager it says "Last update Feb 25, 11:28"
Your answer
Follow this Question
Related Questions
How should I verify that all of my client Object are created and ready after loading a new scene? 0 Answers
How do I properly deal with Internal_CloneSingle can only be called from the main thread 0 Answers
Network Multiple Cameras 4 Answers
[UNET] Client cannot call [Command]s, only the host can 1 Answer
How do I sync components porperties in a Network Game? 0 Answers