Page 1 of 1
Wrong icon in electric network window
Posted: Tue Apr 26, 2016 4:58 am
by Taehl
I'm making a mod which updates some of the game's icons. I just noticed that my new Electric Mining Drill icon, which is fine in inventory and chests and whatnot, isn't used in the electric network window.

- Icon discrepancy
- icon-bug.png (90.39 KiB) Viewed 2970 times
Two things worthy of note:
1) About "base->IconFix->Tmod"... Tmod changes .default_request_amount of every item to 1, but otherwise doesn't touch the mining drill.
2) I didn't think about it until after I took the pictures, but I noticed that while mousing-over the icon on the left gives you the "base->IconFix->Tmod", it's not present in the mouse-over on the right... But both of them have "base->UsefulMapColors". No idea why that would be.
Re: Wrong icon in electric network window
Posted: Tue Apr 26, 2016 7:58 am
by prg
Did you also change the entity's icon, or only the item's?
Re: Wrong icon in electric network window
Posted: Tue Apr 26, 2016 11:14 am
by Klonan
Electric network icon is from the entity prototype, not item
Re: Wrong icon in electric network window
Posted: Tue Apr 26, 2016 6:07 pm
by Taehl
To change one icon for one thing, I have to declare it in more than one place? That's counter-intuitive and leaves open the doors for error. Do I need to do this for every icon? Are there any other places I have to declare it?
We really need that "able to replace graphics without having to code it and require multiplayer synch" feature.
Re: Wrong icon in electric network window
Posted: Tue Apr 26, 2016 6:14 pm
by Klonan
Taehl wrote:To change one icon for one thing, I have to declare it in more than one place? That's counter-intuitive and leaves open the doors for error. Do I need to do this for every icon? Are there any other places I have to declare it?
We really need that "able to replace graphics without having to code it and require multiplayer synch" feature.
Well they aren't the same thing,
There is the item definition, and the entity definition, the only relation between them is that you use the item to place the entity. So yes pretty much you have to do this for every entity as well as every item.
Re: Wrong icon in electric network window
Posted: Tue Apr 26, 2016 6:16 pm
by prg
An item is not the same thing as an entity. Multiple items with their own icon each could be used to place the same entity. Mining an entity can result in multiple items. Which icon should be used for the entity if it's not explicitly specified then?
Re: Wrong icon in electric network window
Posted: Tue Apr 26, 2016 7:16 pm
by Taehl
Mining an entity can result in multiple items (beside anything "contained" in it such as ore or modules)? Isn't data.raw[type][item].mineable.result a string, not a table?
Re: Wrong icon in electric network window
Posted: Tue Apr 26, 2016 7:24 pm
by daniel34
Taehl wrote:Mining an entity can result in multiple items (beside anything "contained" in it such as ore or modules)? Isn't data.raw[type][item].mineable.result a string, not a table?
According to
http://lua-api.factorio.com/0.12.30/Lua ... properties it is products :: array of Product: Products obtained by mining this entity.
But this is off-topic, if you need more advice on that create a new topic in the appropiate subforum.