The intent here is to get a sense of what pains are hurting HTML5 game developers most in the real world to help prioritize which ones to address.
I just did a talk on building html5 games for mobile. Slides
For me the hardest issue to get around when starting a game was browser compatibility. Lack of SVG support with older Android, unusable implementation of html5 audio for mobile safari, slow canvas performance, weird css3 transform bugs (again android). Granted mobile is far more limiting however, the same case could potentially be made for desktop browser games as well. It usually means i'm spending a lot of time at the beginning on caniuse or running tests to see what my limitations/possibilities are for each browser. Not really sure what the solution is here. Just thought I would get the ball rolling and possibly spark some conversations.
Having to write all the boilerplate code to begin development. Every game I make, I need to create the same index.html, style.css, game.js, keyboard.js, mouse.js, and other files and fill them with the basic stuff.
Would be nice if, like XNA, there was a prebuilt set of js classes that just let me go "Mouse.X" or "if(KeyDown(Keys.A))" so I can worry less about coding the engine and focus on the game mechanics instead.
Haxe/NME is great for building an HTML5 game, but getting the exact same output on different browsers still seems some distance away. With NME I didn't have to write any boilerplate, and the majority of the API works well across platforms. It seems like not many people know about Haxe, but every time it shows up on HN or similar sites, people always seem turned off by the "write once, run everywhere" idea and don't even bother trying it for single-platform projects. Maybe it's because they've been let down by similar technologies in the past and have become prejudiced as a result.
@blackjk3 I like those slides, both style and content. We've been thinking about spinning up a embeddable benchmarking library for games, which solves some of the issues you mention. What process do you typically go through when starting a game? Having a design in mind, and then searching for which mobile platforms will support that design? Or picking platforms ahead of time and designing to them? Or something else?
@nklsrh That makes sense. It might be that this template by itself solves some of the problems you're hitting (index.html, style.css) and makes others easier to solve (by adding a framework that does what you want, like "volo add craftyjs"). Of course, that would require you to find and select the appropriate libraries/frameworks. Alternately, it sounds like you would be better served with a less minimalist and more opinionated/specialized template that could provide more functionality. Your thoughts?
@benlan that does look interesting. Getting the same output everywhere can be complicated, and, I think that "write once, run everywhere" as a slogan (which I first encountered as a sales pitch for Java) sets people up to be disappointed, because it's really "write once, test and customize everywhere", much like the Web.
A question for all three of you (and anyone else who wishes to chime in): is this template project something you think you're likely to use in the future? If not, I'd love to understand more about why not...
@dmose for me it all starts with an idea. Then I would figure out the logistics of what platforms will support that idea. For example, it may be a multiplayer game so figuring out all the different platforms that web sockets are available on or if there are acceptable fallbacks. After figuring out all those questions and compiling a list of available platforms I try to create a quick prototype to benchmark performance. At this point I should know if the game is possible given my researched limitations. If possible, I would then build out the game based on fully designed concepts. My process as described unfortunately leads to a lot of abandoned game concepts. There is probably a better process, and, I would be all ears if it would help go from idea to a polished game with less steps in between.
As for your second question... I would be very interested in using the project. I am already using a require.js approach to structure my games, and I had rolled my own build process using r.js and some ant scripts. So in my mind this looks like a great start for someone.
@blackjk3 So one thing occured to me is that one could take an embeddable performance library as I described earlier and give it a very thin wrapper so that you could run it on all the hardware you cared about and it could generate a report. I would imagine this could offer at least a start. One could also imagine doing this in tandem with a service such as jsperf.com, and then the submitted benchmarks determined to be the most useful could be included in the library.
Glad to hear you're interested in using the template. If you come up with ways to make it more useful or usable, I'd love to hear them (as a github issue or elsewhere).
@dmose that would be unbelievably useful information. Especially if joined with something like jsperf. That way I could have some data up front. Instead of building a prototype and realizing later on that i'm only going to get 6 fps or whatever with canvas before iOS 5 (Mobile Safari 5.1) when HW acceleration was added. Right now the only way I figure these issues out is through trial and error. Again, would love to hear other peoples process. I could easily be missing something here.
@nklsrh Thanks for giving it a try! I'll be very interested to hear what the experience of actually going through it is like for you.
@blackjk3 Knowing that you'd find that useful is great info, thanks! As far as other folks processes, that's probably a bit out of scope for this "git issue", but it is a very interesting question. The gamedev sub-reddit http://www.reddit.com/r/gamedev/ might be an interesting place to poll for that...