开发者

Language to choose for a board game (flash or HTML5/JS)

I am developing a web based multi-player board game and wondering what the best language for the UI would be? Its a board game similar to Go but a lot simpler.

I have开发者_高级运维 two options flash or the much touted HTML5 with JS. I have to learn both though I have basic knowledge of JS.

The problem with flash is I have to pay for the server component but the UI development could be easier and have a richer look and feel to it. With HTML5 + JS there is no cost involved but the UI development I feel will be clunky and not smooth. This I am not sure. Any experienced devs out there care to give some advice? Are there any particular issues to worry about, look into?

EDIT: Thanks for the comments. I will go with HTML5/JS.

As far as the server side goes, I have not yet decided what to use but want to look into node.js. May be I need to post it to programmers.stackoverflow.com about how it handles load and concurrent users.

Thanks,

Pav


Go with HTML and JS, you said your game was similar to GO, well check out http://govsgo.com/.

The site is written in JavaScript, well there's not much on the front end, the backend is based on Ruby on rails, check out Railscasts #237 (http://railscasts.com/episodes/243-beanstalkd-and-stalker) for some background info on the Ruby part.

You can even do really heavy stuff these days in JavaScript, like multiplayer asteroids (http://bonsaiden.github.com/NodeGame-Shooter/), so a "simple" game like you want to build, shouldn't be problem at all.


HTML5/JS will be less compatible with your audience. A lot of people still have non-compliant browsers.

That being said, HTML5/JS would be more fun I think. :)


http://html5readiness.com/ Provided by Robert Pitt


Is your game meant to be used on the iPhone? If yes, Flash is a no-go, as it is not available on the iPhone.


My vote: HTML5/JS.

Why? Consider:

  • Flash is fading away. On the other hand, you will enjoy a growing audience for your game (including iPhone, iPad and Android).
  • Flash is more expensive.
  • I am confident that you can create any UI in HTML5 that you can in Flash. In fact, and presumed limitations of HTML5 may actually force you to refine your UI in a positive way.
  • Have you seen Grooveshark since they recreated their entire application in HTML5 instead of Flash? Check it out as a proof of concept.
  • HTML5/JS is easy.
  • Flash requires a third party plugin, HTML5 only requires an up to date browser- which requirement is better for the user? Personally, I'd rather update my browser than install a third party plugin.


Since your making a multi-user game flash is the way to go. Multi-user stuff is possible with html5/js but as Chuck says its not available in all the browsers. For the multi-user side of things you can use Red5 (which is free) or SmartFox which is not free if you have more than 100 concurrent users. I built a big project with SmartFox awhile back and I found it really easy to work with. Depending on the simplicity of your game you could roll your own socket server code with a language of your choice.


Flash is pretty hard to learn unless you know Java or classic OO (I could add a lot to that comment). I would go with JS/HTML/CSS. As Chuck said, it would be more fun.

The server is only an issue if you plan to use Flash Interactive Server which is pricey. There are open source alternatives. But you say that as if JS has this built in - it doesn't. If you want real time updates, you'll need a CometD server and those are not easy to implement. I'd go with a short poll regardless of whether it's Flash or JS.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜