Rotates.org

December 23, 2009 - Belated excuses

It’s been a very busy year for me, mainly due to my commitments at work (let me assure you this won’t be a long winded entry which eventually leads to ‘so thanks for your support but I quit’!) and as such the big project that I’m sure 99% of visitors to this site are waiting for is still under slow methodical planning and development.

It’s dawned on me that I’ve been very secretive even about the name of the project, so I think at the very least I owe you guys that – so here it is!

Archaos

I think this is slightly more pleasing than ‘Chaos Enhanced Enhanced’!

I’d also like to talk about the plans regarding its launch and features, because I’m taking quite a different approach to the norm. Early on in the planning I wanted to make sure Archaos could be playable by as many people on as many different formats as possible. The general idea I had was that I’d write the game in haXe and then generate the various sets of code for servers and clients from that one source, and ‘et voila’ I’d have a cross-platform game. Since then, I’ve spent a lot of time at work playing with various web-based JSON APIs, and I’ve watched some fantastic projects appear (such as node.js, Persevere and CouchDB) and realised that, in fact, Archaos’s core could live on the web as a data-based API.

It makes a lot of sense when you think about it – you have a scalable server with a scalable database, written in Javascript (a language which I simply adore), using JSON as its end-to-end data format, accessible by anything with a web connection. Being turn-based, it doesn’t need to rely on any complicated comet solutions, and (and here’s the really exciting part) you can make your own client in whatever language, format or platform you like!

I’m really big on open source and open web, and so it’s really exciting for me to think that, although I will still be creating clients in Flash and (with Flash CS4’s leave) for iPhone, there’ll also be a well documented API out there that can be used by anyone. You can easily have pure HTML/Javascript clients, text-based clients to run in terminal windows and so on – and no matter which client you use, you’ll be able to play Archaos with anyone else.

As I said before, I’ll also be making the server and client source available (though the server source will likely need a closed development phase after launch so I can work out bugs, security issues and exploits before I make it available to all) so anyone with a Linux box can host their own server – though I’m not quite sure why anyone would want to do this at the moment, as a server will handle many hundreds, or possibly thousands of concurrent games with ease, and take care of matchmaking, login and so on. In fact this area of development will probably result in the separation of the login/matchmaking master server from the core gameplay servers.

So, to summarise:

  • My current work focus has shifted away from a unified client/server architecture, and my time is now being devoted to creating a robust HTTP-based server for Archaos.
  • In tandem to the server work I’ll have to develop a client for testing purposes, and so the first client may be a simple HTML/JS or Flash visual interface.
  • Once these are at a satisfactory level, I will announce a beta period to work out bugs, and then shortly after that I will release full API documentation for the Archaos server (which will have its own snappy name, already got a few ideas) and allow interested parties to get the ball rolling on their own clients.
  • Finally, I’ll finish and release my own client for Flash, and hopefully soon after for iPhone.

As you can probably tell, I’m fantastically excited by this whole project; indeed I can’t see why this hasn’t been done before – though no doubt it has, and I’ve just not looked hard enough… I’d love to hear your opinions on all of this – and I’d also love to find out if other people have attempted something similar!

Edit: Looks like someone has thought of this – in fact pretty much verbatim! http://web.archive.org/web/20031129175919/http://www.openchaos.org/

6 responses to “Belated excuses”

  1. Andy says:

    Sounds good, I’d be interested to discover how much game logic would be handed over to the client, for example making a HTTP request every time a creature/wizard moves may suffer from latency problems, so presumably the movement/engaged/manoeuvre rules would be handled by the client and updated server side after a certain amount of moves are chunked and/or completed?

  2. SEPTiMUS says:

    The way I see it working is that a user makes their move – their client ‘predicts’ the outcome of the move from its version of the board (which will in 99.99999999999% of cases be the correct version, unless there’s a bug or the user’s cheating) and shows the move. In the background, the client sends the server its move (if it’s a land move then it sends an array of tiles it passes) and the server verifies the move. If all’s ok, the server responds with the end location of the move and all’s well with the world. If it’s not ok, the move is retracted and the client should then respond by asking for a full refresh of the board from the server (this is open to optimisation)

    I’ve also compressed each unit on the board into just a few bytes and combined it with gzip, so the JSON that’s going back and forth will be very compact. Even on a large board, with 8 players and several gooey blobs and magic fires doing their start-of-turn spread phase, there shouldn’t be a lot of data being thrown around.

    I may play with other ideas too – such as doing a user’s entire move client-side (using a common seed and index for any rolls) and then submitting it all in one go at the end of the turn. It’s a tad less secure, as an unscrupulous player knowing the seed and index can potentially predict future outcomes of rolls, but it’s a possibility to be explored.

  3. Andy says:

    Yeah, there’s a bit of scope for cheating from dishonest clients if they know the entire state of the board, i.e. which creatures are illusions.

  4. SEPTiMUS says:

    I can see why so many people have given up with Chaos remakes, especially when trying to implement multiplayer – it’s deceptively complex. All of this planning and theorising really does help though. Thanks and merry Christmas Andy!

  5. Is this project still alive? I stumbled across it while planning a… service-based multiplayer Chaos remake 🙂 Have you completed the server and is there any api documentation available please?

  6. lewster32 says:

    Hi Charlie, yes the project is very much alive, however the server is not yet finished and the specs have changed somewhat. It’s still a RESTful web service built on node.js and when it’s released I’ll upload the API documentation for it.