Remove ui_null.png

This commit is contained in:
Wuzzy 2019-08-29 05:46:44 +02:00
parent 0080a2bbb7
commit 52bd4bc52e
5 changed files with 15 additions and 15 deletions

View File

@ -141,8 +141,8 @@ function default.ui.fake_itemstack(x, y, itemstack, name)
local result = ""
if itemname ~= "" then
result = result .. "image_button["..x..","..y..";1,1;ui_null.png;"
..name..";;false;false;ui_null.png]"
result = result .. "image_button["..x..","..y..";1,1;blank.png;"
..name..";;false;false;blank.png]"
result = result .. "item_image["..x..","..y..";1,1;"
..minetest.formspec_escape(itemname .. " " .. itemamt).."]"
@ -163,8 +163,8 @@ function default.ui.fake_simple_itemstack(x, y, itemname, name)
local result = ""
if itemname ~= "" then
result = result .. "image_button["..x..","..y..";1,1;ui_null.png;"
..name..";;false;false;ui_null.png]"
result = result .. "image_button["..x..","..y..";1,1;blank.png;"
..name..";;false;false;blank.png]"
result = result .. "item_image["..x..","..y..";1,1;"
..minetest.formspec_escape(itemname).."]"
result = result .. "tooltip["..name..";"
@ -194,8 +194,8 @@ function default.ui.item_group(x, y, group, count, name)
local result = ""
if itemname ~= "" then
result = result .. "image_button["..x..","..y..";1,1;ui_null.png;"
..name..";;false;false;ui_null.png]"
result = result .. "image_button["..x..","..y..";1,1;blank.png;"
..name..";;false;false;blank.png]"
result = result .. "item_image["..x..","..y..";1,1;"
..minetest.formspec_escape(itemname .. " " .. count).."]"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 298 B

Binary file not shown.

View File

@ -13,22 +13,22 @@ if enable_headbars == nil then enable_headbars = true end
local headbars_scale = tonumber(minetest.settings:get("headbars_scale")) or 1.0
function headbars.get_sprite(icon, background, max, amt)
local img = "[combine:" .. (max * 8) .. "x16:0,0=ui_null.png:0,0=ui_null.png"
local img = "[combine:" .. (max * 8) .. "x16:0,0=blank.png:0,0=blank.png"
if amt < max then
for i = 0, max / 2 do
img = img .. "^[combine:16x16:0,0=ui_null.png:" .. (i * 16) .. ",0=" .. background
img = img .. "^[combine:16x16:0,0=blank.png:" .. (i * 16) .. ",0=" .. background
end
end
img = img .. "^([combine:" .. (max * 8) .. "x16:0,0=ui_null.png:0,0=ui_null.png"
img = img .. "^([combine:" .. (max * 8) .. "x16:0,0=blank.png:0,0=blank.png"
for i = 0, max / 2 do
if i < (amt - 1) / 2 then
img = img .. "^[combine:" .. (max * 8) .. "x16:0,0=ui_null.png:" .. (i * 16) .. ",0=" .. icon
img = img .. "^[combine:" .. (max * 8) .. "x16:0,0=blank.png:" .. (i * 16) .. ",0=" .. icon
elseif i < amt / 2 then
img = img .. "^[combine:" .. (max * 8) .. "x16:0,0=ui_null.png:" .. (i * 16) .. ",0=" .. icon
img = img .. "^[combine:" .. (max * 8) .. "x16:0,0=ui_null.png:" .. (i * 16) .. ",0=headbars_half.png"
img = img .. "^[combine:" .. (max * 8) .. "x16:0,0=blank.png:" .. (i * 16) .. ",0=" .. icon
img = img .. "^[combine:" .. (max * 8) .. "x16:0,0=blank.png:" .. (i * 16) .. ",0=headbars_half.png"
end
end
@ -42,7 +42,7 @@ minetest.register_entity(
{
visual = "sprite",
visual_size = {x = 1 * headbars_scale, y = 0.1 * headbars_scale, z = 1},
textures = {headbars.get_sprite("heart.png", "ui_null.png", 20, 20)},
textures = {headbars.get_sprite("heart.png", "blank.png", 20, 20)},
glow = 5,

View File

@ -12,7 +12,7 @@ local timer = 10 -- needs to be more than update_time
minetest.register_craftitem(
"wielditem:null",
{
wield_image = "ui_null.png"
wield_image = "blank.png"
})
minetest.register_entity(
@ -67,4 +67,4 @@ end
minetest.register_on_joinplayer(attach_wielditem)
minetest.register_on_leaveplayer(detach_wielditem)
default.log("mod:wielditem", "loaded")
default.log("mod:wielditem", "loaded")