[2.0.42] Upcoming breaking mod changes

Place to post guides, observations, things related to modding that are not mods themselves.
Rseding91
Factorio Staff
Factorio Staff
Posts: 15333
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [2.0.14] Upcoming breaking mod changes

Post by Rseding91 »

2.0. 22 will include several small breaking changes to make portions of the Lua API support quality when reading/writing.

Code: Select all

    - Changed all instances of get_item_count to support quality.
    - Changed LuaPlayer::get_quick_bar_slot to include quality.
    - Changed LuaEquipmentGrid::get_contents() to include quality.
    - Changed LuaEquipmentGrid::count() to support quality.
    - Changed LuaEntity::storagE_filter read to include quality.
If you want to get ahold of me I'm almost always on Discord.
Rseding91
Factorio Staff
Factorio Staff
Posts: 15333
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [2.0.14] Upcoming breaking mod changes

Post by Rseding91 »

2.0.25 changes how burner inserters initial energy is handled.

In this release the burner energy source prototype will have 2 new optional properties: initial_fuel and initial_fuel_percent.
If you want to get ahold of me I'm almost always on Discord.
Donion
Factorio Staff
Factorio Staff
Posts: 383
Joined: Sun Aug 22, 2021 9:18 am
Contact:

Re: [2.0.14] Upcoming breaking mod changes

Post by Donion »

There will be several soft breaking changes around sounds in 2.0.33

Code: Select all

    - Renamed WorkingSound::max_sounds_per_type to WorkingSound::max_sounds_per_prototype. The limit is now applied per prototype.
    - Removed WorkingSound::apparent_volume.
    - Removed WorkingSound::audible_distance_modifier, MainSound::audible_distance_modifier and SoundAccent::audible_distance_modifier. Sound::audible_distance_modifier is used instead.
    - Removed PlaySoundTriggerEffectItem::volume_modifier and PlaySoundTriggerEffectItem::audible_distance_modifier.
By soft breaking I mean that existing mods should load and function just fine but will be left with unused properties and defaults will be used where applicable.
Bilka
Factorio Staff
Factorio Staff
Posts: 3359
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: [2.0.42] Upcoming breaking mod changes

Post by Bilka »

There will be a breaking change in 2.0.42:

Changed working_visualisations to enforce that the provided array is contiguous.

This will make the game behaviour match the documentation. I recommend to already update your mods to match this. Especially please note that working_visualisations can NOT be set to a single WorkingVisualisation, it always has to be an array of WorkingVisualisation (which may be of size 1). With this upcoming change, the game will enforce this restriction instead of silently loading nothing as the working vis.
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
Locked

Return to “Modding discussion”