diff --git a/changelog.txt b/changelog.txt index a770ea2..d4ecfad 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,4 +1,9 @@ --------------------------------------------------------------------------------------------------- +Version: 0.2.18 +Date: 2024-1-20 + Changes: + - Capped the animation speed of all mining drills to stop them from spazzing out at one zillion% speed when given beacons. +--------------------------------------------------------------------------------------------------- Version: 0.2.17 Date: 2024-1-19 Changes: diff --git a/data-final-fixes.lua b/data-final-fixes.lua index 7157778..0da334f 100644 --- a/data-final-fixes.lua +++ b/data-final-fixes.lua @@ -340,3 +340,25 @@ end if type(data.data_crawler) == 'string' and string.sub(data.data_crawler, 1, 5) == 'yafc ' then require('prototypes/yafc') end + +-- force mining drill speed to not increase with speed modules +for _, drill in pairs(data.raw['mining-drill']) do + if drill.wet_mining_graphics_set then + drill.wet_mining_graphics_set.max_animation_progress = drill.wet_mining_graphics_set.animation_progress or 1 + drill.wet_mining_graphics_set.min_animation_progress = drill.wet_mining_graphics_set.animation_progress or 1 + end + if drill.graphics_set then + drill.graphics_set.max_animation_progress = drill.graphics_set.animation_progress or 1 + drill.graphics_set.min_animation_progress = drill.graphics_set.animation_progress or 1 + elseif drill.animations then + drill.graphics_set = { + animation = drill.animations, + max_animation_progress = 1, + min_animation_progress = 1 + } + if not drill.wet_mining_graphics_set then + drill.wet_mining_graphics_set = drill.graphics_set + end + drill.animations = nil + end +end \ No newline at end of file