mirror of
https://github.com/ComfyFactory/ComfyFactorio.git
synced 2024-12-26 22:56:43 +02:00
Mtn: fix collapse hanging when utilizing LuaSurface::find_tiles_filtered
This commit is contained in:
parent
0e69b99b40
commit
4579e97c64
@ -1720,11 +1720,14 @@ function Public.find_void_tiles_and_replace()
|
||||
return
|
||||
end
|
||||
|
||||
if not Public.get('find_void_tiles_and_replace') then
|
||||
Public.set('find_void_tiles_and_replace', true)
|
||||
|
||||
local cp = Collapse.get_position()
|
||||
local rp = Collapse.get_reverse_position()
|
||||
|
||||
local area = {
|
||||
left_top = { x = (-zone_settings.zone_width / 2) + 10, y = -rp.y - 1000 },
|
||||
left_top = { x = (-zone_settings.zone_width / 2) + 10, y = rp.y },
|
||||
right_bottom = { x = (zone_settings.zone_width / 2) - 10, y = cp.y }
|
||||
}
|
||||
|
||||
@ -1741,6 +1744,7 @@ function Public.find_void_tiles_and_replace()
|
||||
if tiles and #tiles > 0 then
|
||||
Public.set('tiles_to_replace', tiles)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function Public.set_difficulty()
|
||||
|
@ -157,6 +157,7 @@ function Public.reset_main_table()
|
||||
this.announced_message = false
|
||||
this.notified_game_over = false
|
||||
this.game_reset_tick = nil
|
||||
this.find_void_tiles_and_replace = nil
|
||||
-- @end
|
||||
this.breach_wall_warning = false
|
||||
this.icw_locomotive = nil
|
||||
|
Loading…
Reference in New Issue
Block a user