VS Code doesn't recognize "OnClientConnect" or other Mirror Scripts

Hi

In the picture down below i get the error that VS Code does not recognize the “OnClientConnect” Method from Mirror and I have no Idea why that is.
Please help if you have any idea how I can fix this :frowning:

Hi,
Make sure you have the latest version of Mirror installed in the package manager. Let me know if you are still having this problem.

Even after installing its not showing

Hi, the other thing to check is that the VS Code package is installed in Unity and the Unity Extensions are updated in VS Code.

It’s installed and updated and i have the latest version of Mirror so i don’t know why it’s not showing up

I am Also having this problem

Hi, try deleting your Library folder and restarting Unity so it rebuilds it. Also try deleting the Mirror folder and reimporting it completely.

deleting the libary folder bricks the whole install

Hi, I do this all the time. Close Unity, delete the Library folder, reopen Unity. Unity rebuilds the temp files in the Library folder. What do you mean it bricks the install?

Have to re-add network manager > telepathy transport > network hud > player prefab> build location> project name

You have to re-add GameObject components after deleting the Library folder?

Yes

Have you been saving things in the Library folder, the Library folder is generally only for temporary files.

vs code Editor aswell as Vs code? or just VS code editor

Can’t hurt to install both, which editor are you using?

1 Like

vs code editor only

So start with the VS Code package.

still not getting confirmation in the unity console " a player has connected"

image

the “Player” objects are beiung seen as different Net ID’s
Server
image

Client
image

nope the current Library folder only has the below folders
image

@Yitzchak_Cohen @Sh0rts1

Any resolution on this?

Privacy & Terms