Page 1 of 1

Newbie modding question

Posted: Sun Oct 06, 2024 10:53 am
by wilk85
I'm sorry if that is a stupid question, but want to be sure if that's the case here

i want to develop mod for splitter, but as i'm checking splitter prototype
https://lua-api.factorio.com/latest/pro ... otype.html
i do not see any option here to create a circuit network connection

does that mean, that's not possible to achieve?
Or i'm not searching properly and that's is entirely possible to do?
If possible could you point me to place how to do that?

thank you


EDIT:

Code: Select all

circuit_splitter.circuit_wire_connection_points = circuit_connector_definitions["belt"].points
circuit_splitter.circuit_connector_sprites = circuit_connector_definitions["belt"].sprites
circuit_splitter.circuit_wire_max_distance = 9
is that what i need to add to be able to connect entity to a circuit network?

Re: Newbie modding question

Posted: Sun Oct 06, 2024 2:27 pm
by DaveMcW
It's not possible to connect a splitter prototype to a circuit network.

Re: Newbie modding question

Posted: Sun Oct 06, 2024 6:19 pm
by wilk85
so it isn't possible to create new entity based on splitter but with circuit network capabilities?
and with custom definitions?

Code: Select all

circuit_wire_connection_points,
circuit_wire_max_distance,
circuit_connector_sprites

Re: Newbie modding question

Posted: Mon Oct 07, 2024 10:34 am
by Bilka
wilk85 wrote: Sun Oct 06, 2024 6:19 pm so it isn't possible to create new entity based on splitter but with circuit network capabilities?
No.

Re: Newbie modding question

Posted: Mon Oct 07, 2024 10:45 am
by Qon
wilk85 wrote: Sun Oct 06, 2024 6:19 pm so it isn't possible to create new entity based on splitter but with circuit network capabilities?
and with custom definitions?

Code: Select all

circuit_wire_connection_points,
circuit_wire_max_distance,
circuit_connector_sprites
Like Bilka said, No.

But you could do a workaround with a special splitter and another circuit connection entity. You would have to write runtime Lua code that spawns and maintains the association between entities. But since you are asking, this is above your skill level and you should try making an easier mod first. We can't really help you further. And you would have to write your own lua splitter that destroys ups to do anything except change settings on the splitter.

Re: Newbie modding question

Posted: Tue Oct 08, 2024 4:26 pm
by wilk85
ok thank you for your answers, too bad that splitters do not posses api for wiring but maybe someday it will be added, until that day come i don't think i will have any interest to create mods ;)