I'm making a mod that needs to know when power poles are connected/disconnected and this would be really helpful.
I don't even know how to approach this considering pasting blueprints can also create wires.
Event for wire connected/disconnected to entity
-
- Fast Inserter
- Posts: 234
- Joined: Fri Sep 09, 2022 4:33 pm
- Contact:
Re: Event for wire connected/disconnected to entity
There's been a large number of these type of requests over the years (i count 10+) was there any resolution to this? Perhaps it could be called naturally after `on_built` events, and if mods add/modify circuit connections it could have an option to `raise_connected` just like how `surface.create_entity` has `raise_built`?
If you need to reach me, message me on discord.
I make qol mods. Check them out, maybe.
https://mods.factorio.com/user/protocol_1903
If you have a mod idea, I can look into it.
I make qol mods. Check them out, maybe.
https://mods.factorio.com/user/protocol_1903
If you have a mod idea, I can look into it.
Re: Event for wire connected/disconnected to entity
The devs have explicitly rejected this and related ideas a few times on the forums and on Discord.
We just have to keep hoping they eventually change their minds. Maybe posting more use cases will help, as folks think up mods that could be done with this and can't reasonably be done without it.
We just have to keep hoping they eventually change their minds. Maybe posting more use cases will help, as folks think up mods that could be done with this and can't reasonably be done without it.
-
- Fast Inserter
- Posts: 234
- Joined: Fri Sep 09, 2022 4:33 pm
- Contact:
Re: Event for wire connected/disconnected to entity
In that case, I'm making a mod to apply a different set of default settings for machines, which can be either entity settings or circuit settings. The plan is to have circuit settings only apply when a wire is connected, but as of right now that's not possible. So it's either some hacky way to get that 'event' or apply the circuit settings when the entity is constructed, which just exaggerates the problem by having custom circuit settings on every entity (including common ones like belts, assemblers, inserters...) which I believe uses a lot more data than 'unmodified' entities. This not has been tested however, and I would love to be proven wrong here.
If you need to reach me, message me on discord.
I make qol mods. Check them out, maybe.
https://mods.factorio.com/user/protocol_1903
If you have a mod idea, I can look into it.
I make qol mods. Check them out, maybe.
https://mods.factorio.com/user/protocol_1903
If you have a mod idea, I can look into it.