OD27 fork of 5Dim's mod - New Core


Core for OD27 fork of 5Dim's mod Core, library and settings of OD27 fork of 5Dim's mod. REQUIRED for any other module

Content
10 months ago
1.1
5.83K

b Belts with animation_set.layers have nil animation_set.hr_version which causes errors on start

6 months ago
(updated 6 months ago)

Running into a conflict in relation to the 5dim (and 0D27 5dim) New Transport mod that aims back at Core\lib\transport\generation-transport-belt.lua when also using mods such as Black Rubber Belts.
When generating transport belts 1 to 10 it clones the animations.
Example:

entityTransportBelt.belt_animation_set.animation_set.hr_version.filename =
"OD27_5dim_transport/graphics/entities/transport-belt/transport-belt-" .. inputs.number .. ".png"

However, if an entity is using layers, there is no hr_version to call and results in
Failed to load mods: ..._5dim_core__/lib/transport/generation-transport-belt.lua:295: attempt to index field 'hr_version' (a nil value)

I believe 5dim Core\lib\transport\generation-transport-belt.lua needs some extra logic to detect if a belt's animations/graphics are using layer or using hr_version and use said version for its copying.
https://lua-api.factorio.com/latest/types/Animation.html#layers

New response