Jump to content

  • Log In with Google      Sign In   
  • Create Account

Asynchronous turn based games for social and mobile


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
8 replies to this topic

#1 bigtunacan   Members   -  Reputation: 173

Like
0Likes
Like

Posted 09 February 2012 - 09:06 PM

I've done a few indie games, but up until now they have all been single player games. For my next game I want to create a small asynchronous turn based game (something along the lines of Scrabble, Words With Friends, or Dominion). I know that the newest version of GameCenter supports something like this, but then it would be locked to only iOS; or at the very least I would have seperate code for each platform and someone on iPhone wouldn't be able to play someone else who is on Android or Facebook...

So I don't want to use GameCenter, instead I would rather an independent push server app I could use/purchase, or preferably just write my own. Since I'm new to this bit of it though I'm not sure where to start. I've googled a bunch but everything just points me back to GameCenter or something similar. Any advice would be greatly appreciated on this! Thanks.

Sponsor:

#2 frob   Moderators   -  Reputation: 21470

Like
0Likes
Like

Posted 10 February 2012 - 09:51 AM

If you have web hosting -- which you can get free from many places -- you can implement it as a simple http command. It doesn't need to be complex, AJAX uses small requests like that.

You send a single HTTP request to the server with your information as the query parameters. Then the web page returned is text containing the data your app needs.

The web server is then responsible for handling the actual game. You can implement any number of game clients on any platform since they only need to know about the web server and the commands it supports.
Check out my personal indie blog at bryanwagstaff.com.

#3 GGMich   Members   -  Reputation: 107

Like
0Likes
Like

Posted 17 February 2012 - 02:41 PM

You send a single HTTP request to the server with your information as the query parameters. Then the web page returned is text containing the data your app needs.

I second this if you are looking to avoid GameCenter. That's probably my first inclination if I were to approach this. If you want overkill or you're just looking for more options, there's always RakNet or OpenTNL.

Slightly off-topic, GameCenter will be expanding to "another platform." OS X Mountain Lion is going to have GameCenter support, which means it's a possibility for an iPad user to play a game with someone on their Mac. Not the same as a social or web experience like Facebook, but interesting none the less.
"I work for GarageGames, home of the award winning line of Torque engines and a community of more than 150,000 independent game developers. Learn more about us at garagegames.com"

#4 SymLinked   Members   -  Reputation: 870

Like
0Likes
Like

Posted 19 February 2012 - 05:16 AM

Slightly off-topic, GameCenter will be expanding to "another platform." OS X Mountain Lion is going to have GameCenter support, which means it's a possibility for an iPad user to play a game with someone on their Mac. Not the same as a social or web experience like Facebook, but interesting none the less.


Have you even seen the state of OpenTNL recently? I wouldn't even recommend that in the "overkill" case.

I was surprised the site was even online as it wasn't before. But it's almost worse now that the site is up again - the Sourceforge page has broken links all over the place, the "News" section leads to an odd website in German, the downloads lead to 404, heck even the documentation is 404.. etc. RakNet or even ENet would be a better choice here.

#5 interNEKO   Members   -  Reputation: 122

Like
0Likes
Like

Posted 27 February 2012 - 08:01 PM

The catch is if you want the server to notify all the clients when someone finishes their turn. If you want the server to notify them, then use NodeJS, but you will need access to the server to install and set it up. Otherwise, you can have a js timer, and just do AJAX calls for status updates, but this can be costly depending on your queries and bandwidth available. Hosting any multi-player game is costly bandwidth wise, so as long as the requests can be fulfilled fast, then it washes out in the end.

As people have mentioned, it is easy to have something like PHP return JSON, and use jQuery's AJAX calls to interact with them. Going one step further, you can then use Backbone or JMVC to incorporate templates.
-Phil uthang.com, www.UrbanLegions.net : The Best Super Hero Text based RPG!interNEKO Ltd. Co

#6 swiftcoder   Senior Moderators   -  Reputation: 10060

Like
0Likes
Like

Posted 27 February 2012 - 08:15 PM

There is an open-source project that allows you to deploy your own push-notification server, on any php web host, that is compatible with Apple's APNS protocol. That's probably your best option in the 'roll your own' line of things.

Tristam MacDonald - Software Engineer @Amazon - [swiftcoding]


#7 lmbarns   Members   -  Reputation: 460

Like
0Likes
Like

Posted 03 March 2012 - 11:25 AM

You might take a look at a browser game called "Lord of Ultima". It uses html5 canvas for the game, with ajax calls to update the clients. It's a very, very, basic game but from a big publisher, EA. It gave me a lot of ideas...

You also might like this 48 hour competition scrabble MMO http://www.startupmonkeys.com/2010/09/building-a-scrabble-mmo-in-48-hours/ it utilizes mongoDB's "Geo Spatial" indexing to:

MongoDB geospacial indexing was a lifesaver here. We are able to store every tile thats placed on the board by its x,y coordinate and query a bounding box whenever someone changes their view. The resulting queries are ridiculously fast, even with a tile collection approaching over 90 thousand. Once we get too big for that, scaling is going to be dead simple given we can just use modular arithmetic to produce a shard key.



#8 JamesMintram   Members   -  Reputation: 101

Like
0Likes
Like

Posted 01 April 2012 - 03:44 PM

There is a web service called parse which supports the kind of thing you want and it is free up to a certain amount of messages/api requests (Like GAE)

It has cross platform libraries (iOS and Android) and supports REST so you can use it with anything. Supports push notifications and offline sending of messages (You create the message to send and the library will save it transparently and upload it next time you get a connection)

Check it out here: www.parse.com

Regards,
James Mintram

#9 Buster2000   Members   -  Reputation: 1676

Like
0Likes
Like

Posted 03 May 2012 - 01:12 AM

I am also using Parse for my current game. There is no point implementing something if it is already there waiting for you to use.
There are also several other platform as services that are similar to Parse such as Kinvey, Pubnub and TrestleApp. These kinds of service seem to be pretty big this year with VCs giving funding to a new one every couple of weeks.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS