★ TouchArcade needs your help. Click here to support us on Patreon.

UDP communication over cellular network - for Red Conquest

02-11-2010, 02:33 PM
#1
Joined: Jan 2009
Location: Canada
Posts: 463
UDP communication over cellular network - for Red Conquest

Hey guys, I hope someone out there can help me.

I'm writing the online component of Red Conquest, and we've got wifi working (firewall hole punching and all that), but as soon as we try it on the cellular network, we can't get any responses back from our servers.

We're using UDP to send and receive data for absolutely everything, since TCP over 3G, we feel, would add too much lag to the game.


If you have anecdotal evidence that TCP connections don't have bad latency on iphone over edge or 3g networks, please let us know your latency figures.

If you know how to get UDP messages received over the cellular network, please let us know your technique, and what cellular provider you use. I'm in Canada and I use Fido.


Red Conquest needs your help!

Developer, Cat in a Box Games!
Blue Defense: Second Wave! - $2.99
Blue Attack! - $1.99

Fastar! - $1.99
Red Conquest! - $0.99
02-11-2010, 03:42 PM
#2
Joined: Nov 2009
Location: Ireland
Posts: 29
Have you tried to access any other UDP services over 3G? If I was having that problem I'd write a basic NTP client for the iPhone to see if I got a response from several different time servers.
02-12-2010, 10:13 AM
#3
Joined: Jan 2009
Location: Canada
Posts: 463
A quick STUN server request returns just fine from stunserver.org.

This means it's a problem with our server reply code.


thanks for suggesting such a simple test, I've been so frustrated I can't think straight.

Developer, Cat in a Box Games!
Blue Defense: Second Wave! - $2.99
Blue Attack! - $1.99

Fastar! - $1.99
Red Conquest! - $0.99
02-12-2010, 12:09 PM
#4
Joined: Nov 2009
Location: Ireland
Posts: 29
No problem, I've been there before. Best of luck with the multiplayer.
02-12-2010, 01:19 PM
#5
Joined: Sep 2009
Posts: 330
Quote:
Originally Posted by jakooistra View Post
A quick STUN server request returns just fine from stunserver.org.

This means it's a problem with our server reply code.


thanks for suggesting such a simple test, I've been so frustrated I can't think straight.
Wish I could help. Anything that speeds up the multiplayer update to Red Conquest would be awesome as I've been anticipating it ever since you guys put it in the app description.

If you can't figure out whats wrong w/your server, just throw in UIRequiresPersistentWiFi to info.plist and submit. :P

Water Your Body (ON SALE $0.99)
http://apps.google.com/#1iPhoneApp
Tic Tac Pro (FREE)
New and Noteworthy!
02-14-2010, 02:16 AM
#6
Joined: May 2009
Location: Pittsburgh, PA
Posts: 302
Just wanted to post my opinion on supporting 3G. Is this really needed? We had wanted to support 3G and Wifi but later decided to just go with Wifi just because the nature of usage for people on 3G is that they're outside and on the move. So disconnection due to cell tower switches does cause a bad gaming experience to players. Just something to consider.

Co-Founder/ IPhone Game Programmer
LeftRight Studios | LeftRight Studios Game Videos | Our iPhone Games: smackBOTS (Free) Top 100 App | KatchUp