share/hedgewars/Data/Scripts/Locale.lua
author Henek
Tue, 21 Dec 2010 23:22:53 +0100
changeset 4600 5a3b1dbdd4c9
parent 4502 759c1a3bb156
child 4854 881c8232b66a
permissions -rw-r--r--
added copying also to schemes and updated some translations

local lang = loadfile(GetDataPath() .. "Locale/" .. tostring(L) .. ".lua")
if lang ~= nil then
    lang()
end

function loc(text)
    if lang ~= nil and locale ~= nil and locale[text] ~= nil then return locale[text]
    else return text
    end
end