Skip to content

Commit b5fa9f5

Browse files
Merge pull request #158 from pyanodon:py.spoilage_enabled
added py.spoilage_enabled() to check if the feature flag and mod setting are enabled
2 parents 9aea54d + dd8bb34 commit b5fa9f5

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

lib/data-stage.lua

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ py.empty_image = function()
1717
}
1818
end
1919

20+
---Returns if the feature flag spoilage and the mod setting for decay are enabled
21+
py.spoilage_enabled = function()
22+
return feature_flags.spoiling and mods.pyalternativeenergy and settings.startup["py-enable-decay"].value or false
23+
end
24+
2025
---Returns a localised name with the respective properties of this item/entity/recipe, generalized to make localisation easier
2126
---@param base_name string
2227
---@param tier string?

0 commit comments

Comments
 (0)