Breaking graphics by using size instead of height/width
Posted: Mon Dec 14, 2020 1:56 am
According to the wiki, the size parameter specifies
While preparing Bio Industries for 1.1, I tried to optimize the code, and using "size" instead of both "width" and "height" for square graphics seemed like a good idea to get rid of a couple of lines. But there was an issue with BI's wooden pipes: This happens with Factorio 0.18 and 1.1. While making the screenshots, I used the same version of the mod, with only one file differing. I've attached the two versions of the file, a diff should show that these versions really are the same except for the different specifications of sprite sizes. To reproduce the bug, you can use BI 0.18.29, build some wooden pipes, then replace prototypes/Wood_Products/entity.lua with the attached entities_size.lua.[t]he width and height of the sprite. If this is an array, the first member of the array is the width and the second is the height. Otherwise the size is both width and height.