ippa / jaws

Jaws - HTML5 canvas javascript 2D Game Framework
https://jawsjs.ippa.se
GNU Lesser General Public License v3.0
364 stars 75 forks source link

Quadtree.js: Fixes, Docs #94

Closed videlais closed 11 years ago

videlais commented 11 years ago

An update to quadtree.js that switches the call to jaws.collideOneWithMany with the simplified jaws.collide with a callback. It also now supports any object that has a forEach (both SpriteList and Array-like objects). There is also testing in the more public insert and retrieve functions.

There is also an expansion of all documentation from simple comments to full JSDocs format for each function.

ippa commented 11 years ago

Merged and uploaded here: http://jawsjs.com/jawsjs/test/index.html .. I still see quite a few fails in the quadtree tests in chrome.

videlais commented 11 years ago

Opps.

Yeah, I need to fix those tests too. I changed some internal stuff.

I'm going to look at those next.

ippa commented 11 years ago

cool! heh, making a game for LD is a really good way of finding stuff to fix :). Just noticed I couldn't load BMPs anymore in chrome, fixed a couple of mins ago.

McFunkypants commented 11 years ago

NICE CATCH! I've always felt that all game engines need to have an actual game project to force on-demand features and as the only true TDD test case worth worrying about. Game Jams are like the ultimate testbed.