Small fixes to signs_lib.

This commit is contained in:
kaeza 2013-10-19 22:34:14 -02:00
parent d5f5785b13
commit ebe8adf855

View File

@ -116,7 +116,6 @@ local function build_char_db()
if ch and w then if ch and w then
local c = tonumber(ch) local c = tonumber(ch)
w = tonumber(w) w = tonumber(w)
print("*** DEBUG: c="..tostring(c)..", w="..tostring(w))
if c and w then if c and w then
if c == 0 then if c == 0 then
LINE_HEIGHT = w LINE_HEIGHT = w
@ -135,14 +134,13 @@ local function build_char_db()
-- (font probably was changed). -- (font probably was changed).
print("*** DEBUG: Randomly checking cache.") print("*** DEBUG: Randomly checking cache.")
if not check_random_chars() then if not check_random_chars() then
print("*** DEBUG: yey all ok.") LINE_HEIGHT = nil
minetest.log("info", "[homedecor]"
.." Font seems to have changed."
.." Rebuilding cache."
)
end end
print("*** DEBUG: something's fucked up; rebuild cache.")
else else
print("[homedecor] Warning:"
.." Could not find font line height in cached DB."
.." Trying brute force."
)
minetest.log("warning", "[homedecor]" minetest.log("warning", "[homedecor]"
.." Could not find font line height in cached DB." .." Could not find font line height in cached DB."
.." Trying brute force." .." Trying brute force."
@ -157,7 +155,6 @@ local function build_char_db()
total_width = 0 total_width = 0
char_count = 0 char_count = 0
LINE_HEIGHT = nil
for c = 32, 126 do for c = 32, 126 do
local filename = FONT_FMT:format(TP, c) local filename = FONT_FMT:format(TP, c)