Search found 32 matches
- Tue Oct 10, 2023 6:58 am
- Forum: News
- Topic: Friday Facts #379 - Abstract rewiring
- Replies: 153
- Views: 37452
Re: Friday Facts #379 - Abstract rewiring
Hey everyone. Is it possible to highlight the wired system a little bit more by giving the user the opportunity to change things like thickness or saturation for examples in the options? And is it possible to highlight connected buildings as well? And last is it possible to build wires on the ground...
- Wed Sep 18, 2019 7:28 am
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
What Adamo explained I did understand. I know how to copy and change attributes. But they were a bit easier. but my next question was a little bit harder, because there a lot more lines. And i try to figure out myself at home, but I got to the point where I look into long tunnel. And it would be nic...
- Tue Sep 17, 2019 6:47 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
i thought, that i would get help in this modding section called „Modding Help“! If you don’t want or can’t help then please let the stage free those who wants and can help! Thx Except you're not asking for modding help. You're asking for free personal programming lessons. Well, at least now it's ob...
- Tue Sep 17, 2019 4:51 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
i thought, that i would get help in this modding section called „Modding Help“! If you don’t want or can’t help then please let the stage free those who wants and can help! Thx
- Tue Sep 17, 2019 12:25 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
So i try it to my self. i added into my deepcopy this line sep1.pictures = {layers = {{direction_count = 1, {direction_count = 1}}, direction_count = 1, {direction_count = 1}}} i looked for this part right here, it is the picture section of the entity pictures = { layers = { { filename = "__bas...
- Mon Sep 16, 2019 7:13 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
So i am preparing a detail explanation about what i try to achieve Edit: This code is a original Part of the small-electric-pole in the entity.lua in the base folder { type = "electric-pole", name = "small-electric-pole", icon = "__base__/graphics/icons/small-electric-pole.p...
- Mon Sep 16, 2019 7:03 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
Ah makes sense. btw i try to read the Lua manual in german, because i live in german and even in german it seems more complicated to read and understand it, then make a mod here.
So, how about deleting code segments of an entity? is that possible in the same operation with the deepcopy part?
So, how about deleting code segments of an entity? is that possible in the same operation with the deepcopy part?
- Mon Sep 16, 2019 6:36 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
thx, but now my next big thing is comingAdamo wrote: ↑Mon Sep 16, 2019 6:34 pmExactly. And congratulations!Palaber1984 wrote: ↑Mon Sep 16, 2019 6:32 pm ah ok, when creating a table then with comma, and when changing a table then without.
BTW, my mod runs now with this short way,
before that, why you have use util in your code?
- Mon Sep 16, 2019 6:32 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
ah ok, when creating a table then with comma, and when changing a table then without.
BTW, my mod runs now with this short way,
BTW, my mod runs now with this short way,
- Mon Sep 16, 2019 6:01 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
minable = {mining_time = 0.1, result = "small-electric-pole"}, You mean that comma before result? It is strange because, in my orignal entity is like above and the game is running Edit: i have deleted all commas like this and get another error local sep1 = table.deepcopy(data.raw["el...
- Mon Sep 16, 2019 5:20 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
Would you agree so far i did it like this? --prototypes/entity.lua local sep1 = table.deepcopy(data.raw["electric-pole"]["small-electric-pole"]) sep1.name = "small-electric-pole", sep1.minable = {mining_time = 0.1, result = "small-electric-pole"}, sep1.max_hea...
- Mon Sep 16, 2019 5:04 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
--item.lua local fireArmor = table.deepcopy(data.raw.armor["heavy-armor"]) fireArmor.name = "fire-armor" fireArmor.icons= { { icon=fireArmor.icon, tint={r=1,g=0,b=0,a=0.3} }, } fireArmor.resistances = { { type = "physical", decrease = 6, percent = 10 }, { type = "...
- Mon Sep 16, 2019 4:47 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
Did you mean to ask another question, here? Yeah, can i write all my questions down here or how should i handle this? my next question is, like in the tutorial of the wiki.factorio there is this code --item.lua local fireArmor = table.deepcopy(data.raw.armor["heavy-armor"]) fireArmor.name...
- Mon Sep 16, 2019 11:19 am
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
Ah understand. And if I have multiple entities like small-electric-Pole-1, small-electric-Pole-2, small-electric-Pole-3, Then have to use every time a new variable or, can I use the same for all? You only need the variable if you're passing the data around, essentially. THe game picks up the data w...
- Sun Sep 15, 2019 5:18 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
small-electric-pole-2 is not a legal name in Lua. It thinks you are subtracting "electric" and "pole" from "small". and when i use smallelectricpole? You need to differentiate between the variable names you're using when you set something equal to something else and th...
- Sun Sep 15, 2019 4:53 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
- Sun Sep 15, 2019 4:34 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
Do you like this better? local pole2 = table.deepcopy(data.raw["electric-pole"]["small-electric-pole"]) pole2.name = "small-electric-pole-2" pole2.minable = {mining_time = 0.1, result = "small-electric-pole-2"} pole2.max_health = 50 pole2.maximum_wire_distanc...
- Sun Sep 15, 2019 4:24 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
What you really want is table.deepcopy(). local pole = table.deepcopy(data.raw["electric-pole"]["small-electric-pole"]) pole.name = "small-electric-pole-2" pole.minable = {mining_time = 0.1, result = "small-electric-pole"} pole.max_health = 50 pole.maximum_wi...
- Sun Sep 15, 2019 4:15 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
I used bobs power mod. There u can see this situation in the entity/pole.lua
https://mods.factorio.com/mod/bobpower
https://mods.factorio.com/mod/bobpower
- Sun Sep 15, 2019 4:12 pm
- Forum: Modding help
- Topic: using util.merge how does it works?
- Replies: 46
- Views: 10015
Re: using util.merge how does it works?
My picture are stored in a puplic folder of my google drive. So I don’t know how to show them here. I am getting strange link.eradicator wrote: ↑Sun Sep 15, 2019 4:04 pm
Oh, and btw the forum supports attaching screenshots to posts, which is much easier to read then jumping back and forth to an external site.