Hi. Im working on an offline multiplayer project and I wonder if Network code work on mobiles devices on same wifi hotspot. If not then how to connect them. And what’s about bluetooth and wifi-direct,is there any free solution to connect mobile devices with out internet. Thanks!
no one know?
Yes it is possible to connect a smartphone to a Unity app on PC. You can do it with both Bluetooth or WiFi. I have written an Android app which automatically connects via WiFi or Bluetooth, allowing me to use my phone as a gaming controller. Internet connection is irrelevant.
2 Likes
Did you write a plugin to handle the Bluetooth connectivity. If so, how easy was that?
I wrote a .NET executable file which talked to Unity via UDP sockets. the .NET exe could use the InTheHand bluetooth library because is could use .NET 4+
Now you could write it within Unity because I believe .NET 4 is supported.
lol that some next level necro. Well, for anyone who looking this:
- For local network, my advice is just learn about networking in general first, you’ll have much better luck finding resources on C#/.Net in general than for Unity
- For bluetooth, last time I check it will required native plugin. For that you’ll need to learn to make a native app first.
- No idea about Wifi direct, also I’ve never seen anyone use it for anything.
Can someone close this, please.
1 Like