Auto Research (fixed + re-published abandoned mod)


Automates research. Toggle GUI with Shift+T (customizable).

Utilities
22 days ago
0.18 - 2.0
22.0K

b Crash on mod load

4 years ago

Happens to me when starting factorio. Also happens with the old autoresearch mod. Something seems to have changed with the space exploration rocket science pack, which is where the error occurs. I'll attempt to figure out what the actual problem is, but you might want to catch that anyway, so it doesn't crash on load if someone incorrectly configures the icons.

Error ModManager.cpp:1508: Failed to load mod "some-autoresearch": some-autoresearch/data-final-fixes.lua:12: attempt to perform arithmetic on field 'icon_size' (a nil value)
stack traceback:
some-autoresearch/data-final-fixes.lua:12: in main chunk

4 years ago

Findings so far: auto research relies on the icon size being specified in the tool table. That's not mandatory according to mod specification, as long as each icon has its own size defined. Space exploration does this:

icons = {
{
icon = "space-exploration-graphics/graphics/icons/catalogue/deep-1.png",
icon_size = 64
},
{
icon = "space-exploration-graphics/graphics/icons/catalogue/mask-1.png",
icon_size = 64
}
},

4 years ago

Finalized: Changed the data-final-fixes.lua to this:
https://pastebin.com/iShUbNYC

Works fine now.

4 years ago
(updated 4 years ago)

Your fix didnt work for me, but I adapted it a little and now it seems to work with current space exploration.

Plz test.

4 years ago

Can confirm that it works. Thank you very much

New response