diff --git a/config.lua b/config.lua index bc40caad..666eb66c 100644 --- a/config.lua +++ b/config.lua @@ -393,8 +393,8 @@ global.config = { -- when biter corpses in an area are above a threshold, remove the desired amount biter_corpse_util = { enabled = true, - radius = 3, -- radius to search around dying entities - corpse_threshold = 10 -- number of corpses allowed on surface inside radius + chunk_size = 3, -- size of chunk in tiles + corpse_threshold = 10 -- number of corpses allowed on surface inside chunk } } diff --git a/features/biter_corpse_util.lua b/features/biter_corpse_util.lua index da097705..ce91e820 100644 --- a/features/biter_corpse_util.lua +++ b/features/biter_corpse_util.lua @@ -91,8 +91,8 @@ local function biter_died(event) end --Calculate the hash position - local x = entity.position.x - (entity.position.x % biter_utils_conf.radius) - local y = entity.position.y - (entity.position.y % biter_utils_conf.radius) + local x = entity.position.x - (entity.position.x % biter_utils_conf.chunk_size) + local y = entity.position.y - (entity.position.y % biter_utils_conf.chunk_size) local hash_position = x .. "_" .. y -- check global table has this position, add if not