1
\$\begingroup\$

I have been making a mobile game that is similar to "Street Fighter" where two players play with each other via Internet.

The game sends out a small packet (controller status) to the other party every 30ms (a lot of packets going on).

I am currently using a server to connect two players and all communications are via TCP through the server. The server load increases a lot even for just 30 concurrent players. I know it sounds not wise to let the communication go through the server, so I think the best design should let these two players to communicate directly via UDP after the server hooks them up.

However, I have some questions when trying to move on to the new design:

Since it's a mobile game, players might be using 3G network a lot. Does UDP hole punching work well in 3G network? Does it matter when a player is actually moving physically (such as inside a car)? Do you think I should change the design or any recommendation of better design concepts?

\$\endgroup\$
4
\$\begingroup\$

3G is optimized for stuff like streaming video. It's terrible with regard to latency when talking about small bits of data. There's a reason multiplayer mobile games over 3G with split-second timing don't exist.

|improve this answer|||||
\$\endgroup\$
  • \$\begingroup\$ Yes, some said it can't but I also found some said it's doable: forum.unity3d.com/threads/network-over-3g.69367 \$\endgroup\$ – Joe Huang Jan 18 '15 at 12:59
  • \$\begingroup\$ I don't see anything there that leads me to believe a "a mobile game that is similar to 'Street Fighter'" would work. I see people talking about how in an FPS you can get killed by a late packet and not really know if it missed you on your client or not because you can't see yourself. \$\endgroup\$ – Almo Jan 18 '15 at 13:04
  • \$\begingroup\$ I did make some experiments with 3G and the latency is pretty bad. I thought if I change the app to send UDP directly to each other, the situation can be improved. Ok, maybe I shall consider to give up the idea then. \$\endgroup\$ – Joe Huang Jan 18 '15 at 13:12
  • \$\begingroup\$ It's unpleasant to have to say "give up on the idea" but in this case, I don't think the technology will deliver what you need. :( \$\endgroup\$ – Almo Jan 18 '15 at 17:51

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.