I have developed a turn based game using android studio.I want to add local multiplayer feature to it. Don't need a detailed explanation, I need some idea about the following aspects:-

Do I need a thread for each client?

How can the server identify a client?(Which client device is sending the information or pressing a button)

I saw the code of bluetooth chat application. In that code, only two devices can communicate with one another. But my game has to be played with four players and I can't figure out a way to connect and communicate among four devices.

  • \$\begingroup\$ Does this existing answer set you on a path you can run with? \$\endgroup\$ – DMGregory Mar 24 '19 at 17:10
  • \$\begingroup\$ The answer is quite Ok.But I need some more informations like do i need different threads for each clients?And also how can the server identify the clients?(Which device is sending the information) \$\endgroup\$ – MeSterious Mar 24 '19 at 17:16
  • \$\begingroup\$ Sounds like you have a good lead then to edit your question above and refine it from "a little bit of an idea" to something more concrete, like "How does the server identify the clients in Bluetooth multiplayer?" \$\endgroup\$ – DMGregory Mar 24 '19 at 17:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.