Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

packet size limit for iPhone games?

i am creating a multi player iPhone game using the multi player tutorial as the skeleton in the following link http://www.raywenderlich.com/3276/how-to-make-a-simple-multiplayer-game-with-game-center-tutorial-part-12.

With the architecture i am using (GameCentre peer to peer)one of the devices plays the role of the server. I have a question, just what is the limitation of the packet size? On average i need to send out 890 bytes per go...

like image 619
godzilla Avatar asked May 03 '12 23:05

godzilla


2 Answers

Generally you should not rely on the network packet size. The packets can get fragmented (via TCP/IP and get re-assembled by the stack) or data get packetized based on MTU of the sending/receiving parameters.

like image 146
Zepplock Avatar answered Sep 27 '22 22:09

Zepplock


Per the Game Kit Programming Guide:

  • Limit the size of unreliable messages to 1000 bytes or smaller in size.
  • Limit the size of reliable messages to 87 kilobytes or smaller in size.
like image 36
nrp Avatar answered Sep 27 '22 22:09

nrp