From 579e52661579fb2da4066c8772d7712743e57504 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Thu, 21 Mar 2019 11:25:14 +0100 Subject: [PATCH] Signs: Add replacement character --- mods/ITEMS/mcl_signs/init.lua | 6 +++++- mods/ITEMS/mcl_signs/textures/_rc.png | Bin 0 -> 902 bytes 2 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 mods/ITEMS/mcl_signs/textures/_rc.png diff --git a/mods/ITEMS/mcl_signs/init.lua b/mods/ITEMS/mcl_signs/init.lua index f83e63396b..e878d16eaa 100644 --- a/mods/ITEMS/mcl_signs/init.lua +++ b/mods/ITEMS/mcl_signs/init.lua @@ -85,6 +85,7 @@ local generate_line = function(s, ypos) local printed_char_width = CHAR_WIDTH + 1 while chars <= LINE_LENGTH and i <= #s do local file = nil + -- Get and render character if charmap[s:sub(i, i)] ~= nil then file = charmap[s:sub(i, i)] i = i + 1 @@ -92,8 +93,11 @@ local generate_line = function(s, ypos) file = charmap[s:sub(i, i + 1)] i = i + 2 else - minetest.log("warning", "[mcl_signs] Unknown symbol in '"..s.."' at "..i.." (probably "..s:sub(i, i)..")") + -- No character image found. + -- Use replacement character: + file = "_rc" i = i + 1 + minetest.log("verbose", "[mcl_signs] Unknown symbol in '"..s.."' at "..i) end if file ~= nil then width = width + printed_char_width diff --git a/mods/ITEMS/mcl_signs/textures/_rc.png b/mods/ITEMS/mcl_signs/textures/_rc.png new file mode 100644 index 0000000000000000000000000000000000000000..8b66915e65362b2aad96f275bd0c7d9de2319bcc GIT binary patch literal 902 zcmV;119|+3P) zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=HGlH4E+MgLhvmVhLL#Bwm0s_Y=k&jmC6N@uF_ z_#9Jhuq*`JBXEcF$M+Gw;Udu#lA7m|bHtTODqPX8|P79%9=s7$!k2 z*JD1ne}!G|9V~78@oW#a1F`QwA0zL8GDl`Kwx91n!k3-)b11uCO%Kc2ztMQT*5i8h z`kV}6bVWSjz^9Nz+3i*#LXR_|`^Zl(L}H4M*Q0i$`xxi7x|%YS%3&|+V=1czN649Eb;~G*pQ3H6 z6coo28;Et#JWyJoLJYMBCF)dZ(7EbH4O2{fvY}>f(0$rmj0?8~CCx&E4S0GG2Z;u1 z0yE#{LTlWz#%tslxf48@5R4|f*Am_t|EAmmjWJV~DEg%n(gO41nKhWkBscHy0skV2#HW;!wKhmMqQ!KaDAD$Ygy7fJ7KuF&SiZqL^_=P^M_i zMg$!ld@5$nlK21tQsquzfQ?879OpSU`WP)=R=&(QS^z?^MGR=LfdDHdMgCZFdzVdgQ|nKgv-X(x;`SEjMf4N~@i_bZq~gyM^w(^m@{XR65hCXFl!pvz&Dx z*M^KVbmU>fM;Y}-jrO*EqDC*|KBq>T+9Z~ipWUg!Z1xd?=5eBv8HjNr5VuJH3C)vP zbV`XQxydXR#->mPHPQ*E(z=qu1yp!u(2bo^HfKLI?Cca7m=3IYHC z00v@9M??Vs0RI60puMM)00009a7bBm001r{001r{0eGc9b^rhX2XskIMF-;p6$%g* z&*D5M0000nNklDD&X2PPKfeG0xm?R^*Dr_oo cI|-}f0hh}R1fPdjIRF3v07*qoM6N<$f&&nYr~m)} literal 0 HcmV?d00001