• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
Sign in to follow this  
Followers 0
Aurelius1664

Advice for Web Developer Creating Online RTS HTML5 with Proof of Concept

6 posts in this topic

New to the forum and looking for some advice...

We are a Web Development Company and have done some small to medium web sites using a mixture of C# and Javascript (including some fairly advanced JavaScript stuff). However, we are currently looking at diversifying to create products and one option was small games online and for mobiles.

We've developed a Real Time Strategy Engine, or at least a Proof of Concept for one, in pure HTML5. We've tested it to a certain degree on most of the modern browsers and on the iPhone (planning on testing on Android ICS but not sure about HTML5 support). All of the move, fire, build code and some visual effects and sounds are all working well (link below). It's probably about 5 weeks of research and development that originally started around learning the [color=#222222]nuances of [/color]HTML5.

[b]Proof of Concept (EDIT: Now works on iphone minus sound)[/b]
[url="http://jsrtsengine.cheironjavascript.co.uk/"]http://jsrtsengine.c...vascript.co.uk/[/url]

The idea is that the HTML will work not just on normal browser but also on phones (works fine on iphone other than sound) creating a nice cross platform game without massive cross paltform effort. We planned to write simple browser wrappers for iPhone and Android to create saleable apps (and fix the sound issues on iphone).

However, I'm really rather unsure of what to do next. Is it possible for an [color=#222222]independent [/color]company to achieve success with something like this? Is there any money to be made from this approach? Is this something that could be taken to a publisher? Or is this just so saturated that attempting anything like this just isn't worth any more effort?

One idea was to laucnh the game with an editor, which we have a basic rough and ready version of, and try do something community based. Any thoughts or ideas would be most welcome as we have no experience what so ever in this field!
1

Share this post


Link to post
Share on other sites
If anyone is interested we've got quite far on with this as a bit of a what if experiment and are now putting in into an open BETA. We've also got a native iPhone version that we're testing running from the same core JavaScript and XML files. We came across quite a few problems gettting the game to work on iPhone in "all" JavaScript though. The game runs in the UIWebView however the frame rate is shocking, despite being fine just running in Safari. Turns out this is a common problem with wrapped web apps as Apple does not alow their full Nitro JavaScript engine to be used due to security permissions. So we had to write a native canvas class called by the core javascript and rendered on top of the UIWebView. This seems to work and the framerate is now better than the native HTML5 even in Safari. We also used this method to get around Apple's restrictions on playing sound in HTML5 without a media player style UI and are attempting to use a smiliar process to enable multiplayer over Bluetooth.

Beta is below, any feedback is appreciated...

[url="http://www.enterprisewarfare.com"]http://www.enterprisewarfare.com[/url]
1

Share this post


Link to post
Share on other sites
Very impressive!

I think HTML5 is really going to take a place as a great development option over the next couple of years, and there are a lot of great development tools and libraries in the works.

I've found Android to be problematic thus far -- completely unplayable prior to ICS, and a HUGE variation in device capabilities to deal with -- hopefully this -- along with other problem areas such as audio -- is something that will be resolved over time.


I take it you're developing your own wrappers and support libraries where needed rather than trying to work with an existing platform such as AppMobi or CocoonJS? Of these libraries I've found PhoneGap to be the best in terms of exposing device functionality and working on the largest range of devices, but unfortunately only the simplest of graphics perform at an acceptable framerate -- it's a great library for a simple app, but unusable for most games -- I've heard it does offer good performance on a BlackBerry PlayBook however. AppMobi and CocoonJS seem to offer much better performance on their targeted platforms, but don't expose much device functionality, and seem to really be pushing their own deployment services and add-on (high-scores, etc.) APIs, which makes me more wary of any serious usage.
0

Share this post


Link to post
Share on other sites
Yeah we can pretty much hit our target of 25 to 30 fps when on IE9, Firefox, Safari and Chrome on desktop (Chrome seems fastest at present). This is running on fairly old spec. machines so we're quite happy as we've yet to optimise a lot of the code.

On iPhone 4 running through Safari we get about 15 to 20 fps (you can run this yourself via the links above). However, if you pin the game via 'Add to home screen' or run the game in an app via UIWebView the frame rate drops to 4-8fps. This is because Apple disables its Nitro compiler engine for 'security reasons' which slows everything right down if it is outside of Safari.

To get around this we have written a wrapper for the iPhone app version. The core engine and menus run via the UIWebView in exactly the same code as the browser version. However, the JSRTSCanvas JavaScript 'class' is 'overridden' on the iPhone to simply create a call log. This log is then passed back to iPhone native code at the end of frame and performs the drawing using Quartz 2d on a standard UIView. This gets us right back up to the target 25 to 30 fps (and possibly higher but that’s the target frame rate set by the engine). Indecently we also pass the sound calls back to Objective-C on the native app too and intend to do something similar to do Multiplayer support.

On Android (ICS) running directly in the browser we get about 10fps on a Samsung Galaxy 2 (newer phones will obviously be better but that's all we have to test on at the moment). Not sure how well this will work in an actual App using the Android’s embedded web view but I suspect similar if not worse performance. We anticipate we'll have to do something along the lines of what we're doing with the iPhone application. We’ll be moving on to the Android version once the iPhone and browser versions are complete hopefully.

This is very much a cross platform experiment/research project to see how viable HTML5 is for such things. So far whilst it runs well on desktops and runs on mobiles there are still major performance problems. However, it does seem that JavaScript as a cross platform core combined with overridden ‘system’ classes to cover gaps and improve performance is workable. The cost savings in not having to re-develop everything for native apps on each platform are still very attractive.
1

Share this post


Link to post
Share on other sites
We have just added multiplayer support for up to four players.

[url="http://www.enterprisewarfare.com/play.aspx"]http://www.enterprisewarfare.com/play.aspx[/url]

Also updated to show better loading progress on Chrome and Safari and fixed a few other bugs.

Plus it now runs, though a little slow, on the Playstation 3's browser.
0

Share this post


Link to post
Share on other sites
That looks amazing! I'll have to give it a longer try when I get home from work. I've actually dabbled with creating some games using HTML5, nothing as advanced as your's but I find it a decent enough platform to be able to create a decent game. The only thing that I can ever see as a problem is the ever changing world of browsers and what they support. I can see it being a pain to keep a large project maintained so it will be supported on all platforms at all times on all browsers.

Hopefully this will be an easy hurdle to jump.

I'll keep a watch out on the development of the game!
0

Share this post


Link to post
Share on other sites
We have just taken this into open beta on Facebook. The app now has Facebook integration with their credits api and the ability to challenge friends and play multiplayer in realtime. Still with everything written in HTML5 and Javascript (other than the server side code for multiplayer which is C#/.NET). Any feedback would be much appreciated, link below.

[url="http://apps.facebook.com/EnterpriseWarfare"]http://apps.facebook.com/EnterpriseWarfare[/url]
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0