mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2025-10-03 21:01:14 +00:00
Fix problematic Lua init and add user setting to keep 'os' and 'io' functions.
From the Lua 5.1 manual: "The luaopen_* functions (to open libraries) cannot be called directly, like a regular C function. They must be called through Lua, like a Lua function." All standard tables are now loaded with luaL_openlibs(), which includes os and io. Because these are inherently unsafe, there is a new config setting: <AllowDangerousScriptFunctions on="1" /> This is disabled by default. The title screen will show a warning when the setting is on.
This commit is contained in:
parent
3db8c9e13a
commit
86d2fcebda
5 changed files with 38 additions and 9 deletions
|
@ -208,6 +208,7 @@
|
|||
2032 [Achievements]
|
||||
2033 Retrieving online mod list...
|
||||
2034 Open URL in web browser?
|
||||
2050 -- WARNING: Dangerous script functions are ENABLED!
|
||||
2100 === for options menu ===
|
||||
2101 Action
|
||||
2102 Key 1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue