mirror of
https://git.minetest.land/Mineclonia/Mineclonia.git
synced 2024-11-08 10:45:04 +00:00
Merge branch 'master' of https://git.minetest.land/MineClone2/MineClone2 into commands-refactoring-1
This commit is contained in:
commit
1f1f9f54a2
1 changed files with 2 additions and 3 deletions
|
@ -409,9 +409,8 @@ end
|
|||
function mcl_util.get_color(colorstr)
|
||||
local mc_color = mcl_colors[colorstr:upper()]
|
||||
if mc_color then
|
||||
return mc_color
|
||||
end
|
||||
if #colorstr ~= 7 or colorstr:sub(1, 1) ~= "#"then
|
||||
colorstr = mc_color
|
||||
elseif #colorstr ~= 7 or colorstr:sub(1, 1) ~= "#"then
|
||||
return
|
||||
end
|
||||
local hex = tonumber(colorstr:sub(2, 7), 16)
|
||||
|
|
Loading…
Reference in a new issue