LV batbox should show charge on all X/Z sides

(also, fixup some other texture defs for readability)
This commit is contained in:
Vanessa Ezekowitz 2017-04-12 20:29:22 -04:00
parent 33455328bd
commit a34ea59105
1 changed files with 11 additions and 9 deletions

View File

@ -216,24 +216,26 @@ function technic.register_battery_box(data)
groups.tubedevice_receiver = 1 groups.tubedevice_receiver = 1
end end
local top_tex = "technic_"..ltier.."_battery_box_top.png"..tube_entry
local front_tex = "technic_"..ltier.."_battery_box_front.png^technic_power_meter"..i..".png" local front_tex = "technic_"..ltier.."_battery_box_front.png^technic_power_meter"..i..".png"
local tentry = tube_entry local side_tex = "technic_"..ltier.."_battery_box_side.png"..tube_entry
local bentry = tube_entry local bottom_tex = "technic_"..ltier.."_battery_box_bottom.png"..tube_entry
if ltier == "lv" then if ltier == "lv" then
top_tex = "technic_"..ltier.."_battery_box_top.png"
front_tex = "technic_"..ltier.."_battery_box_side.png^technic_power_meter"..i..".png" front_tex = "technic_"..ltier.."_battery_box_side.png^technic_power_meter"..i..".png"
tentry = "" side_tex = "technic_"..ltier.."_battery_box_side.png^technic_power_meter"..i..".png"
bentry = cable_entry bottom_tex = "technic_"..ltier.."_battery_box_bottom.png"..cable_entry
end end
minetest.register_node("technic:"..ltier.."_battery_box"..i, { minetest.register_node("technic:"..ltier.."_battery_box"..i, {
description = S("%s Battery Box"):format(tier), description = S("%s Battery Box"):format(tier),
tiles = { tiles = {
"technic_"..ltier.."_battery_box_top.png"..tentry, top_tex,
"technic_"..ltier.."_battery_box_bottom.png"..bentry, bottom_tex,
"technic_"..ltier.."_battery_box_side.png"..tentry, side_tex,
"technic_"..ltier.."_battery_box_side.png"..tentry, side_tex,
"technic_"..ltier.."_battery_box_side.png"..tentry, side_tex,
front_tex}, front_tex},
groups = groups, groups = groups,
connect_sides = {"bottom"}, connect_sides = {"bottom"},