Thursday, July 7, 2011

Game Platform

Let’s say I wanted to build a non-graphic intensive game and I wanted wider reach, I would filter out closed-heavy-graphics platform like Xbox, PlayStation, Nintendo and PC Native as well. To have wider reach, probably the web is the best way to go, and HTML5 would provide better capability as a web game platform (else I would need to resolve to Flash, which might not be very promising in the future). Chrome Web Store and Chromebook would increase the reach of web apps.

On the mobile front, people tend to use more native apps than mobile web apps; and to develop for each of the mobile platform (iPhone, Android, etc) could be quite a lot of extra work. Should I use HTML5, or Native Android or iPhone?



HTML5
HTML is pretty “ready” nowadays, with Canvas (for Graphics), Storage, Offline Mode and Web Socket which is crucial for the development of a game. I am quite sure Chrome could do HTML5 pretty well, but I am not sure about other browser especially IE. I am worry about Android’s Browser (and other Mobile Browser) capability and HTML5 support might be lacking behind Chrome.

HTML do support some native hardware and feature, such as Capture Image, Microphone, Location Awareness, Multi Touch, etc.

Perhaps Google Web Toolkit (GWT) for Game could be used to increase productivity on HTML5 development. There are more mobile libraries such as Sproutcore and jQuery Mobile; perhaps utilize Modernizr for feature detection and fallback. Refer to some HTML5 Mobile tips.

Android Native
Besides power and deep optimization, there are more hardware integration and API: Compass, Bluetooth, Gyroscope, Barometer, NFC, USB Accessories, Android@Home's Hardware. The ability to integrate with other apps and call native functions, such as SMS, Contacts, etc. There is a System Event Listener (listen for Incoming Calls, etc), Truly Background/Scheduling (Conserve Battery), Rich Offline Support (Synchronization), Notifications, etc.

Hybrid Approach
We could include WebView into a native app, and there is a HTML5 and Native bridge (HTML5 could call native, and vice versa). Problem is WebView might not have the full capability of a browser (certain HTML5 feature missing?).

Perhaps by using GWT, the Java code could be used at Android easily while churning out HTML5 for the web apps?

Conclusion
I would still go with HTML5 for the wider reach (praying HTML5 does live up to its reputation and promises), and the write once run many places (though platform optimization is still required). Hopefully mobile web apps are more discoverable in the future, and desktop and mobile browsers do become more standardized in terms of its HTML5 capabilities.

No comments:

Post a Comment