possible to check if mod exist inside control.lua
cause this doesnt do it:
if mods[" "] then
if mod in the control stage?
Re: if mod in the control stage?
game.active_mods will be available only when loading the game has completed, but you may want to access the mod list before that (i.e. while on_load is active). Querying script.active_mods is more versatile (it's available right after control.lua has been entered).
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!
Re: if mod in the control stage?
when loading a map this pops up:
attempt to index global 'game' a nil value
Re: if mod in the control stage?
yes this one seems to do the trickPi-C wrote: ↑Fri Feb 05, 2021 3:02 pmgame.active_mods will be available only when loading the game has completed, but you may want to access the mod list before that (i.e. while on_load is active). Querying script.active_mods is more versatile (it's available right after control.lua has been entered).
if script.active_mods[" "] then
thank you guys