mirror of
https://github.com/Refactorio/RedMew.git
synced 2025-01-05 22:53:39 +02:00
Don't run cleanup on every death.
This commit is contained in:
parent
c07b5a39e0
commit
c501c9ca85
@ -394,7 +394,8 @@ global.config = {
|
||||
biter_corpse_util = {
|
||||
enabled = true,
|
||||
radius = 3, -- radius to search around dying entities
|
||||
corpse_threshold = 10 -- number of corpses allowed on surface, inside radius
|
||||
corpse_threshold = 10, -- number of corpses allowed on surface inside radius
|
||||
cleanup_chance_percent = 10 -- 100 means check on every biter death, 50 means every second death, etc.
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -22,6 +22,11 @@ local function biter_died(event)
|
||||
return
|
||||
end
|
||||
|
||||
-- Only a chance of cleanup
|
||||
if biter_utils_conf.cleanup_chance_percent < random(100) then
|
||||
return
|
||||
end
|
||||
|
||||
local surface = entity.surface
|
||||
|
||||
local filter = {
|
||||
|
Loading…
Reference in New Issue
Block a user