   @param [sourceObject] An object to exclude from the results.
   @returns {Array} An array of objects that collide with the given bounds.
   ###
-  collidesWith: (bounds, sourceObject) ->
-    collided = []
-
-    self.objects().each (object) ->
-      return unless object.solid()
-      if object != sourceObject && object.collides(bounds)
-        collided.push(object)
-
-    return collided if collided.length
+  collidesWith: (bounds, sourceObject, selector=".solid") ->
+    self.find(selector).select (object) ->
+      object != sourceObject and object.collides(bounds)
 
   ###*
   Detects collisions between a ray and the game objects.

  @param source The origin point
  @param direction A point representing the direction of the ray
  @param [sourceObject] An object to exclude from the results.
  ###
  rayCollides: (source, direction, sourceObject) ->
    hits = self.objects().map (object) ->
      hit = object.solid() && (object != sourceObject) && Collision.rayRectangle(source, direction, object.centeredBounds())
      hit.object = object if hit

      hit

  @param [sourceObject] An object to exclude from the results.
  @returns {Boolean} true if the bounds object collides with any of the game objects, false otherwise.
  ###
  collides: (bounds, sourceObject, selector=".solid") ->
    self.find(selector).inject false, (collided, object) ->
      collided or (object != sourceObject) and object.collides(bounds)

  ###*
  Detects collisions between a bounds and the game objects.
  Returns an array of objects colliding with the bounds provided.

  @name collidesWith
