views:

254

answers:

11

Some time ago I tought that using the right click and giving it a real function wans't even possible in Flash world, 3 days ago I found out that via javascript is perfectly possible, and doable

So, is it possible to make a Flash game that acts like a multiplayer pc game?, I mean, real online games, no delay, no lag.

I heard that the netcode in Flash sucks, but, you know, I thought that too about right click.. and I was plain wrong :).

Thx.

+3  A: 

Yes.

http://www.dofus.com/en

QED

moonshadow
Proof by example.
Greg
I dont think that Dofus is a Flash game.. mybe I'm wrong, but the website says that I need to downlaod the game before I can play it.
Artemix
@Artemix: the two are not mutually exclusive. See the bottom of [this](http://www.dofus.com/en/mmorpg-free/starting-out) page, for instance. Or, y'know, try it out ;) Plenty of other people have given examples too by now though.
moonshadow
Btw, yesterday I saw Dofus's gameplay, and that is NOT real time multiplayer, that's some sort of turn based.Doesn't qualify to my question.
Artemix
@Artemix: the battles are turnbased with a time limit, but the interactions on the world map are real time. If you want a completely seamless example, check out [Gaia Online's zOMG](http://www.gaiaonline.com/games/zomg/)
moonshadow
+1  A: 

They already have them. Facebook has those games you play against other members. There are plenty of examples of multiplayer flash games online.

Ed B
A: 

They are indeed possible, there are a bunch over at http://www.kongregate.com/

Accounting for lag in Flash games is just like accounting for it in any other language/framework.

MikeD
Can you point me to one real time multiplayer game on that site if it's not too much to ask?
Artemix
A: 

For developing multi-player Flash games, you really need a server component. Take a look at these:

http://www.smartfoxserver.com/

Rich
A: 

or this:

http://osflash.org/red5

Rich
A: 

The opensource way to run multiplayergames that I've played with is Red5 Server It sets up XML sockets for the various clients to connect to and update eachothers gameplay. My tests (and the examples that came with it) worked really well, but the client ended up going with another vendor, so I never got to build the final project.

There may also be a way to use FP10 to connect directly to another client using Stratus, which is I think the way that ChatRoulette does it (P2P).

Nilloc
And.. ask you for a real time multiplayer game using Stratus I guess is too much to ask right? :P
Artemix
I've read about Stratus, and seems like the only posibility would be a 1 vs 1 game, since the other 2 technologies are not supported by Flash nor Air.
Artemix
A: 

And... just like I supposed... I was wrong, again.

Cant thank you enough.

I'm certainly be back here to ask you guys again.

Artemix
If someone answered your question, mark them as answered so the question doesn't stay open (hence getting more confirmations). Also, you can post comments in your questions so you don't have to "answer" your own question :)
Organiccat
Yes, you are right, I'll remember it the next time.
Artemix
A: 

One common way this is done is to use a PHP backend (or other server side language). Using this, you can store, translate and send data via a database backend. If you need to do real time multiplayer, you need to learn some Flash netcode and dig into streaming and shared objects.

This is the point at which you have to do some of your own research to figure out what will work best with your scenario or at least figure out the options and then ask which will work after describing it and the options you think will fit.

Here are some docs from the Adobe site about streaming and shared objects:

(for real time communication between players) http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/net/NetStream.html

(for tracking shared objects like a level or a group party) http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/net/SharedObject.html

Organiccat
A: 

You can. I think alternativa platform is worth looking at: http://tankionline.com/en/

back2dos
A: 

You should try the Smart Fox Server as your socket server. Currently it's the backend of Disney's Club Penguin (Over 12 Million users).

Juanda
A: 

Yes it is possible you can use smartfox server or union server.

slayerIQ