diff options
author | orwell <orwell@bleipb.de> | 2025-06-11 21:36:17 +0200 |
---|---|---|
committer | orwell <orwell@bleipb.de> | 2025-06-11 21:36:17 +0200 |
commit | fb980caa7551f8c4ef62ac6bb702b02422e0e999 (patch) | |
tree | 47528c3f2928762d72ec23b42b5a7114c33080b8 /advtrains_luaautomation/init.lua | |
parent | ca1bd639b75c604ba5c3877f5ca4958eaf0561a1 (diff) | |
download | advtrains-fb980caa7551f8c4ef62ac6bb702b02422e0e999.tar.gz advtrains-fb980caa7551f8c4ef62ac6bb702b02422e0e999.tar.bz2 advtrains-fb980caa7551f8c4ef62ac6bb702b02422e0e999.zip |
Tag strings for luaautomation
Diffstat (limited to 'advtrains_luaautomation/init.lua')
-rw-r--r-- | advtrains_luaautomation/init.lua | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/advtrains_luaautomation/init.lua b/advtrains_luaautomation/init.lua index a2f4eb9..753340d 100644 --- a/advtrains_luaautomation/init.lua +++ b/advtrains_luaautomation/init.lua @@ -2,14 +2,20 @@ -- Lua automation features for advtrains -- Uses global table 'atlatc' (AdvTrains_LuaATC) -atltrans = attrans -local S = atltrans ---Privilege ---Only trusted players should be enabled to build stuff which can break the server. atlatc = { envs = {}} +-- Initialize internationalization (using ywang's poconvert) +advtrains.poconvert.from_flat("advtrains_luaautomation") +-- ask engine for translator instance, this will load the translation files +atlatc.translate = core.get_translator("advtrains_luaautomation") + +-- Get current translator +local S = atlatc.translate + +--Privilege +--Only trusted players should be enabled to build stuff which can break the server. minetest.register_privilege("atlatc", { description = S("Can place and configure LuaATC components, including execute potentially harmful Lua code"), give_to_singleplayer = false, default= false }) --Size of code input forms in X,Y notation. Must be at least 10x10 |