I cant use the Unity.Netcode.Spawning namespace

When I learning the connection approval in this toturial (https://docs-multiplayer.unity3d.com/docs/getting-started/connection-approval), I find that I cant use the namespace that the example used, I cant use the
MLAPI.NetworkManager.ConnectionApprovedDelegate callback

The docs are outdated. using Unity.Netcode; is the only namespace you need. Instead of MLAPI.NetworkManager.ConnectionApprovedDelegate use just NetworkManager.ConnectionApprovedDelegate

1 Like

that doesnt work it gives me this error: CS0426 The type name ‘ConnectionApprovedDelegate’ does not exist in the type ‘NetworkManager’

@MemzDev what version of Netcode For GameObjects are you using? 1.2.0 is the latest

I just updated the netcode package and since then I have gotten this error:

Assets/NetCode/Tests/Manual/Scripts/ConnectionApprovalComponent.cs(157,98): error CS0426: The type name ‘ConnectionApprovedDelegate’ does not exist in the type ‘NetworkManager’

I haven’t modified them and I can’t find what is wrong with this. I am using version 1.2.0.

Any help would be appreciated.

Alright I think I found the solution, for some reason it had installed netcode twice in my project and then there was a version mismatch error.