JavascriptBattle/hero-starter — pull request #28 by yojimbo311 (2014-10-10 20:37:49+00:00)
Title: Helpers: Return the found object from the generic nearby search

Modifying helpers.findNearestObjectDirectionAndDistance to return the found tile object including the relative location properties instead of just the location properties.

This allows for a much richer definition of hero brains by being able to evaluate object status conditions beyond their distance and direction. Currently brain definitions have to do a secondary lookup against the gameData's board tiles to get the supposed target object in order to evaluate object status and it would be a lot easier, and more efficient, if that step was eliminated.