Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I am developing a flash-based game primarily for desktops, to be hosted on facebook platform (like cityville, sims social etc). The gameplay doesn't involve real-time communication between players unlike an mmorpg. Here each player plays in his own world without any knowledge of other online players. I've written almost 95% of the game logic in actionscript on the client side.
I used Smartfox Server pro on the server side (mostly used for getting data from the DB) and the entire server code is an extension written in java. I'm using json as the protocol for communication.
Although I love smartfox server, as an indie, its tough for me to afford the unlimited users license. Morever its limited just to one machine. So I'm looking for an alternative to smartfox server now.

The reason for choosing smartfox server earlier was to use the server properties supported by it.

Server properties on smartfox server take advantage of the socket connection and are essentially server side objects in java which store some data for the player which he can change frequently during the game. And when he logs out of the game, the extension can write out the final state in the DB (I'm using MySQL). This significantly reduces the number of DB UPDATE/INSERT calls made during the game.

I love the way this works since the data is secure as its on the server side and smartfox server is known to be scalable. (although I'm not sure whether this approach is used widely by gaming industry or not, since this is not an mmorpg, I'm putting all player in the lobby).
So my question is whether any of the free and community supported servers like reddwarf, firebase, BlazeDS etc can provide a similar architecture so that I can use server properties without many code changes?

EDIT : I am not insisting on the exact same feature (thats asking too much!), but atleast a viable messaging system on the server so that I can send actionscript objects from the client using json/binary so that its fast. OR maybe some completely different way to implement what I need here. Thanks in advance.

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

Have you looked at using Red5 as your server? The default includes Tomcat so you can write servlets or regular java web app code to do anything you need done at that tier. All the rtmp communications that you could want comes with this for free; free as in it costs you nothing, but you have to write what you need at the server level where the sky's the limit.

share|improve this answer
    
Thanks for your quick response. I don't know much about the protocol being used in smartfox server internally, but basically I send a as3 byteArray using a socket connection to the server and get back a Java HashMap( Its called ActionscriptObject in smartfox server) response which I cast as an Object in as3. Are socket connections available for the Red5 server? –  Sapots Thomas Feb 15 '12 at 17:24
    
If you're client app is flash based its easiest to just talk AMF0/3 over RTMP. Object serializing/deserializing is all handled by flash and red5. If you don't want to use RTMP you can always talk over HTTP using RTMPT; which is just RTMP over HTTP in the simplest terms. –  Mondain Feb 15 '12 at 23:21
    
I'm really sorry, but I've limited idea about RTMP. Does it provide a persistent connection like sockets without polling where the server can push data into the flash client? If thats true, then red5 can very easily solve my problem. I'm looking at red5, it seems to be quite a mature product. –  Sapots Thomas Feb 16 '12 at 13:37
    
Yes, its persistent; its exactly what you see being used in almost every flash streaming video from youtube to whatever video site. We talking audio/video, RPC, shared objects, etc.. –  Mondain Feb 16 '12 at 14:31
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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