Page 1 of 1

[1.1.53] Mod being blamed for modifying an entity when it doesn't ...

Posted: Fri Feb 04, 2022 12:16 pm
by EnigmaticAussie
Issue:
In certain combinations of mods, assembler-pipe-passthrough (APP) is blamed for creating invalid pipe connections, even when the mod makes no changes to the entity.

Steps to reproduce:
Enable mod list below, game should crash on start to the error message:
Image

Required mods:
base
angelsrefining
P-U-M-P-S
z_assembler-pipe-passthrough (attached) - custom mod to account for all of my troubleshooting steps

Troubleshooting steps:
  • adjusting mod load order to ensure APP loads after angelsrefining and PUMPS (both with optional mod requires, and mod rename (z_assembler-pipe-passthrough)
  • blacklisting the entity 'seafloor-pump'
  • I've also noted that the error message is slightly different if the entity is not blacklisted

Re: [1.1.53] Mod being blamed for modifying an entity when it doesn't ...

Posted: Fri Feb 04, 2022 1:38 pm
by Rseding91
Thanks for the report however the message is correct.

The table the mod is modifying is shared between multiple entities and by modifying one it modifies everything using that table. If you want to just modify the one entry you'd need to deep-copy the table, then make your modifications.

Re: [1.1.53] Mod being blamed for modifying an entity when it doesn't ...

Posted: Fri Feb 04, 2022 2:01 pm
by lyvgbfh
I took a look and you are in fact modifying it, you can check by dumping the prototype at the start and end of your data-final-fixes. Here's a browsable view of the differences.

Re: [1.1.53] Mod being blamed for modifying an entity when it doesn't ...

Posted: Fri Feb 04, 2022 2:38 pm
by EnigmaticAussie
Edit - I didn't read.

If this is the case, then either my code does miracles or something else is wrong.

If anyone has any idea on how it's possible that my code runs against an entity, but doesn't log it - like it's supposed to on line 9 of my data-final-fixes...

That would be greatly appreciated.


The table the mod is modifying is shared between multiple entities and by modifying one it modifies everything using that table. If you want to just modify the one entry you'd need to deep-copy the table, then make your modifications.

Thankyou.