/** * Returns the item at location (x,y) in grid space * * @param x * @param y * @return null, if no item there, else a valid PickupableItem */ public PickupableItem PickupableAt(int x, int y) { for (PickupableItem m : m_pickupables) { if (m.getX() == x && m.getY() == y) { return m; } } return null; }
/** * Renders all items to the screen * * @param map */ public void renderAll(Map map) { for (PickupableItem m : m_pickupables) { m.render(map); } }