java - Usage of WiFi-Direct in Game Development (Android) -


I am developing board games in Android. I want to play this game on two different devices, for that I have to use WiFi-Direct. I want to know that any library is available which will help me find and connect with the device

  • The board between two devices after the touch-listener event Send and receive coordinates

    I am interested in the built-in library. Or, if possible, please share the implementation examples of client / server architecture.

    This is for the server:

      thread servertrread = new thread (New Runnabal) {@Override Public Zero Run ({{serverSocketTCP = New ServerSet ()); ServerSocketTCP. Reset Resetress (true); Server socketsccp.band (newinetacademyadder ports)); Whereas (status) {clientSocketTCP = serverSocketTCP.accept (); BufferedReader bufferedReader = New InputStreamReader (client.getInputStream ()); Output stream output stream = client.getOutputStream ();}} Catch (exception E) {E.printStackTrace ();}}}; serverThread.start () ;   

    This is for the customer:

      socket client socket = new socket (server IP, serverport); Outputstream = clientSocket.getOutputStream (); bufferedReader = New buffer reader (New Input Stereo Reader (clientSocket.getInputStream ());    

  • Comments

    Popular posts from this blog

    How can I add a seperate action listener to all 14 of my buttons at once that can determine player turn?(java) -

    php - Sorting an multidimension array using usort fails -

    Simple file compression in C -