News for hackers. Stuff that matters.
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by kevincennis on Wednesday October 17, 2012 @01:53PM (#4665656)
It's awesome that people are writing articles on this stuff, but man -- some of the code in those examples is pretty rough.
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by WesleyJohnson on Wednesday October 17, 2012 @02:36PM (#4665844)
Any specific examples you'd like to site? I always enjoy learning new things by seeing how people might re-factor or rewrite existing code samples.
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by kevincennis on Wednesday October 17, 2012 @04:10PM (#4666191)
The block that starts with the comment `//shop items`:

`var label` gets declared 3 times inside each loop iteration. Even if JS had block scope, which it doesn't, that would be pretty bad.

Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by fariazz on Wednesday October 17, 2012 @05:05PM (#4666433)
Thanks for noticing that kevincennis I've just corrected it.
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by dclowd9901 on Wednesday October 17, 2012 @04:09PM (#4666186)
Glad to see some HTML5 game dev articles up. Since this thread is bound to attract devs involved in HTML5 game creation, is impact.js any good? I find Lime.js to be severely lacking in tools to create something like a platforming game (I'd really rather not write physics and collision code).
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by fariazz on Wednesday October 17, 2012 @05:00PM (#4666413)
In LimeJS you can use the Box2D library to simulate physics, you don't have to write it yourself.

For collision detection is pretty easy, as the Closure Library (which LimeJS is built around) comes with "bounding box" support to perform this very easily.

Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by krapp on Wednesday October 17, 2012 @05:05PM (#4666436)
Construct 2 uses Box2d and Easel.js I believe.. I've seen a number of html5 game tutorials on tutsplus for easel.js but they mostly seem to be "copy what the dev did step by step" as opposed to really explaining things well.

Still this might be worth looking at.

Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by cstrat on Wednesday October 17, 2012 @04:34PM (#4666287)
Am I the only one worried about the 100x Farmville clones that will now be built by 15 year olds and spammed across the social sites. =) Great tute though.
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by krapp on Wednesday October 17, 2012 @04:53PM (#4666378)
I'm worried about the other 99x if I decide to crank one out...
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by dlopez on Wednesday October 17, 2012 @02:07PM (#4665730)
great tutorial!
Re:Tutorial: Create a Mobile HTML5 Farming Game with LimeJS by thisiswei on Wednesday October 17, 2012 @07:53PM (#4666932)
cooooool