-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
crash: mods: Deadlock-SE-bridge + deadlock-beltboxes-loaders + space-exploration #105
Comments
That is indeed a strange thing. If I find the time, I might be looking into it. |
The critical lines are these two in Deadlock-SE-bridge/prototypes/deadlock.lua: local DBL = require("__deadlock-beltboxes-loaders__/prototypes/shared")
require("__deadlock-beltboxes-loaders__/prototypes/create_loader") In Factorio, the second require adds a My theory is that YAFC sees the local declaration twice and creates two different tables, while Factorio creates only one table. If I make these two changes, the mods load in both YAFC and Factorio:diff --git a/Deadlock-SE-bridge_0.6.6/prototypes/deadlock.lua b/Deadlock-SE-bridge_0.6.6/prototypes/deadlock.lua
index 0fe598b..100ffa7 100644
--- a/Deadlock-SE-bridge_0.6.6/prototypes/deadlock.lua
+++ b/Deadlock-SE-bridge_0.6.6/prototypes/deadlock.lua
@@ -84,8 +84,7 @@
--BELTBOX
--Add beltbox tier
if deadlock_stacking then
- local DBL = require("__deadlock-beltboxes-loaders__/prototypes/shared")
- require("__deadlock-beltboxes-loaders__/prototypes/create_loader")
+ local DBL = require("__deadlock-beltboxes-loaders__/prototypes/create_loader")
remove_tech_pack ( data.raw.technology["deadlock-stacking-3"], { "production-science-pack" } )
diff --git a/deadlock-beltboxes-loaders_2.4.2/prototypes/create_loader.lua b/deadlock-beltboxes-loaders_2.4.2/prototypes/create_loader.lua
index 08bd05d..e771123 100644
--- a/deadlock-beltboxes-loaders_2.4.2/prototypes/create_loader.lua
+++ b/deadlock-beltboxes-loaders_2.4.2/prototypes/create_loader.lua
@@ -277,3 +277,5 @@
)
end
end
+
+return DBL I don't know where to go from here, but hopefully someone else will be able to take this further. |
…decoding. (#202) Lua uses UTF8 strings, not Ansi. This usually doesn't matter, except that Schall Alien Loot has setting values containing the character `×` (U+00D7), and this gets garbled when loaded from mod-settings.dat. In addition to Schall, I checked loading with AngelBobMadClown, ExoticIndustries, IR3, Nullius, Pyanodon, and SE. The only error I encountered was #105.
last messages:
global variable
deadlock_stacking
:they're internally adding to previously
require
d tables, will this work the same way in YAFC?:"static" function to
global
DBL, while required islocal
- this looks weird to me......maybe they're totally wrong, but a crash must not happen!
The text was updated successfully, but these errors were encountered: