Skip to content

Commit

Permalink
Desert Oasis fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
hanakocz committed Jan 23, 2025
1 parent e2e29e8 commit 48cade5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions maps/desert_oasis.lua
Original file line number Diff line number Diff line change
Expand Up @@ -438,6 +438,8 @@ local function deny_building(event)
if type_whitelist[entity.ghost_name] then
return
end
else
return
end
end

Expand Down Expand Up @@ -533,6 +535,9 @@ local function on_player_changed_position(event)
if player.vehicle then
return
end
if script.active_mods['space-age'] and player.cargo_pod then
return
end

if safe_tiles[surface.get_tile(player.physical_position.x, player.physical_position.y).name] then
return
Expand Down
2 changes: 1 addition & 1 deletion modules/thirst.lua
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ local function sip(player)
end
local water_tiles = player.surface.count_tiles_filtered({
name = { 'water', 'deepwater', 'water-mud', 'water-shallow' },
area = { { player.position.x - 1, player.position.y - 1 }, { player.position.x + 1, player.position.y + 1 } }
area = { { player.physical_position.x - 1, player.physical_position.y - 1 }, { player.physical_position.x + 1, player.physical_position.y + 1 } }
})
if water_tiles > 0 then
this.hydration[player.index] = this.hydration[player.index] + 200
Expand Down

0 comments on commit 48cade5

Please sign in to comment.