that's funny
[WIP] The Old Nexus 「 Grimrock XL 」
Re: [WIP] The Old Nexus 「 Grimrock XL 」
Finished Dungeons - complete mods to play
- Zo Kath Ra
- Posts: 931
- Joined: Sat Apr 21, 2012 9:57 am
- Location: Germany
Re: [WIP] The Old Nexus 「 Grimrock XL 」
https://github.com/7Soul/log2_the_old_nexus
mod_assets/scripts/init.lua contains this line:
I don't understand why the line is there.
I thought that init.lua and the files it imports could only contain definitions:
defineAnimationEvent
defineObject
etc.
And you also load mod_assets/scripts/functions.lua into a script entity called "functions" in dungeon.lua
Put another way, what would happen if you removed this line from mod_assets/scripts/init.lua ?
mod_assets/scripts/init.lua contains this line:
Code: Select all
import "mod_assets/scripts/functions.lua"
I thought that init.lua and the files it imports could only contain definitions:
defineAnimationEvent
defineObject
etc.
And you also load mod_assets/scripts/functions.lua into a script entity called "functions" in dungeon.lua
Put another way, what would happen if you removed this line from mod_assets/scripts/init.lua ?
Code: Select all
import "mod_assets/scripts/functions.lua"
Re: [WIP] The Old Nexus 「 Grimrock XL 」
When you use an external script, you gotta import it
Re: [WIP] The Old Nexus 「 Grimrock XL 」
This isn't true at all. How would that even work? import just runs the file you give it and returns whatever that file's main function returned, it doesn't do anything else.
edit: in fact it looks like Grimrock's import doesn't even pass through the return value, it always returns nothing.
Last edited by minmay on Mon Nov 16, 2020 1:42 am, edited 1 time in total.
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
Re: [WIP] The Old Nexus 「 Grimrock XL 」
Well then