EDIT: Ah goddamit, I'm probably looking at upgrading my distro to the next major version. Because apparently manually forcing an update to glibc is a sure-fire way to experience Fun in the DF sense of the word on Linux.
It's not that old, DF should have been built using an older version.
Yeah, we're working with Bay 12 to standardize on a more widely compatible build environment. It's not as easy as just switching build systems, though, since DF actually *uses* functionality only available in more recent versions of glibc and the c++ standard library.
I had trouble with running a modtools command. Can you apply one in the tutorial?
any script can be run with the
dfhack.run_script() command, modtools or otherwise (see
https://docs.dfhack.org/en/latest/docs/dev/Lua%20API.html#general-script-api). Which one were you having trouble running? Does the script have the "unavailable" tag (
https://docs.dfhack.org/en/stable/unavailable-tag-index.html#cap-m )? If so, it hasn't been updated yet and you can't expect it to work.
I missed the definition of the variable modId in the final example.
It's just a string that's set to the name of your mod. There are a few examples of the variable being set in the modding guide. Ctrl-F for "modid".
de mod deactivates by closing the game, but doesnt reactivatie. Id like to have my script always active, if my main mod is loaded .
This is what the onStateChange handler is for in
https://docs.dfhack.org/en/stable/docs/guides/modding-guide.html#putting-it-all-togetherThere's more information about this mechanism here:
https://docs.dfhack.org/en/latest/docs/dev/Lua%20API.html#enabling-and-disabling-scripts