Abandoned Ruins - Combined


Combined ruin-set content mod for Abandoned Ruins - Updated. Integrates 250 different ruins with Factorio 2.0.77 and runtime-aware compatibility.

Content
a month ago
2.0
301
Environment

b [FIXED]Crash on init: Require can't be used outside of control.lua parsing

2 months ago
(updated 2 months ago)

Hi! I encountered a crash when initializing the mod. Here is the error message:

Error while running event AbandonedRuins-Combined::on_init()
AbandonedRuins-Combined/control.lua:12: Require can't be used outside of control.lua parsing.
stack traceback:
[C]: in function 'require'
AbandonedRuins-Combined/control.lua:12: in function 'build_ruin_set'
AbandonedRuins-Combined/control.lua:25: in function <AbandonedRuins-Combined/control.lua:16>

In Factorio, the require function cannot be called dynamically inside runtime events like on_init(). It must only be used during the initial file parsing stage.

To fix this, please move the require statement from line 12 inside build_ruin_set to the very top of the control.lua file, outside of any functions or event handlers.Thank you for maintaining this mod!

2 months ago
(updated 2 months ago)

=)

2 months ago

Hey, that's wild. I actually removed that bug from the mod because I’d noticed it during testing, but somehow it must have snuck back into the zip file. It’s been fixed in version 0.1.1.
Cheers

New response