Add missing collisions to buildings
This commit is contained in:
@@ -286,7 +286,7 @@ void render(float dt, Game *game) {
|
||||
|
||||
DrawRectangleLines(tileX * 16, tileY * 16, sizeX * 16, sizeY * 16, placeColor);
|
||||
|
||||
if (canPlace && IsMouseButtonDown(MOUSE_BUTTON_LEFT)) {
|
||||
if (canPlace && IsMouseButtonDown(MOUSE_BUTTON_LEFT) && !io->WantCaptureMouse) {
|
||||
placeBuilding(&game->map, selectedBuilding, tileX, tileY, sizeX, sizeY);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user