How to query circuit wire connections to ghost entities?

Place to get help with not working mods / modding interface.
Post Reply
JAetherwing
Inserter
Inserter
Posts: 31
Joined: Sat Dec 29, 2018 2:51 pm
Contact:

How to query circuit wire connections to ghost entities?

Post by JAetherwing »

Hello,

I made an entity which uses a placer entity. When that placer is built, it's settings are copied and modified and it then is deleted.
My problem is, that this removes the possibility to blueprint circuit wire connections to those entities, as the wires from ghost entities get deleted once my placer is replaced. It also does not work if I use fast_replace = true.

I initially planned to just record all circuit wire connections to the placer and rebuild that table for the new entity, but I soon discovered that connections with ghosts are not listed in circuit_connection_definitions (not even for the ghost entity itself). That does make some sense, but now I'm wondering how I can now recover the blueprinted circuit wires.

Any help is greatly appreciated, thank you!

PS: I have to use the placer for some other functionality, there's no way around it.

Post Reply

Return to “Modding help”