StepHan
StepHan

Reputation: 61

(Unity) Network manager not working on android device

I added GameObject. To this object I added two components. (Network Manager and Network Manager Hud). Created cube and added Network Identity(Local Pl.Au). In Player Prefab added cube and deleted from scene. Finally I build&Run on windows. And it works well on windows. when I connect my real Android phone it installed successfully but when I tried press Lan Host or Lan Client it is not responding.The phone is connected to the laptop using a USB cable. What am I missing?

Upvotes: 0

Views: 2645

Answers (2)

Iyan Laylor
Iyan Laylor

Reputation: 1

You can use LAN on Andriod, you just have to enter the IP address of the Host device into the box where it says "localhost". To be clear, replace "localhost" with IP address of host device( can be andriod or PC)

Upvotes: 0

A.Boulianne
A.Boulianne

Reputation: 121

LAN Host or LAN Client will work on your PC, because your PC knows what a LAN is. Your android device, on the other hand, does not. To match your android device with another device or your PC, you will have to use a match making service. To develop and try your app, you can use Unity's match making Service, which can be used in a limited fashion with a Unity Personal license.

When using the NetworkManagerHUD tool, the "Enable Match Maker" button will take you there.

You will need to do a bit of setup to turn on Matchmaking Service on your unity account and server before you can try. Go to Window > Services. Perform the necessary steps to create or use your current organization and project, and enable Multiplayer.

Upvotes: 1

Related Questions