Android game networking
I need help finding the best method for networking in a multiplayer game. I want to connect to a phone and maintain the connection until the game is over, hosting the game on one of the phones. There are other threads, but none of them really explain how to connect or use the networking, only saying to use such-and-such library. Examples or links to good tutorials would b开发者_运维技巧e extremely helpful.
You have to options: TCP/IP sockets or Bluetooth.
For TCP/IP socket there is a good discussion on "Thinking in Enterprise Java" by Bruce Eckel, you can access the digital edition for free (see chapter 2).
Fro bluetooth there is a tutorial on the android developer website. Just be advised that peering between phones is supported only starting from android 2.0.
精彩评论