internal bool IsCollidingAt(FloatRectangle a_rect) { Vector2 tileSize = new Vector2(0.9f, 0.9f); for (int x = 0; x < g_levelWidth; x++) { for (int y = 0; y < g_levelHeight; y++) { FloatRectangle rect = FloatRectangle.createFromTopLeft(new Vector2(x, y), tileSize); if (a_rect.isIntersecting(rect)) { if (m_tiles[x, y] == TileType.BLOCKED || m_tiles[x, y] == TileType.Background) { return(true); } } } } return(false); }