| | |
| | | "label[3,0;"..S("Charge").."]".. |
| | | "label[5,0;"..S("Discharge").."]".. |
| | | "label[1,3;"..S("Power level").."]".. |
| | | "list[current_player;main;0,5;8,4;]" |
| | | |
| | | "list[current_player;main;0,5;8,4;]".. |
| | | "listring[current_name;dst]".. |
| | | "listring[current_player;main]".. |
| | | "listring[current_name;src]".. |
| | | "listring[current_player;main]" |
| | | |
| | | if data.upgrade then |
| | | formspec = formspec.. |
| | | "list[current_name;upgrade1;3.5,3;1,1;]".. |
| | | "list[current_name;upgrade2;4.5,3;1,1;]".. |
| | | "label[3.5,4;"..S("Upgrade Slots").."]" |
| | | "label[3.5,4;"..S("Upgrade Slots").."]".. |
| | | "listring[current_name;upgrade1]".. |
| | | "listring[current_player;main]".. |
| | | "listring[current_name;upgrade2]".. |
| | | "listring[current_player;main]" |
| | | end |
| | | |
| | | local run = function(pos, node) |
| | |
| | | ..":technic_power_meter_fg.png]") |
| | | |
| | | local infotext = S("@1 Battery Box: @2/@3", tier, |
| | | technic.prettynum(current_charge), technic.prettynum(max_charge)) |
| | | technic.pretty_num(current_charge), technic.pretty_num(max_charge)) |
| | | if eu_input == 0 then |
| | | infotext = S("%s Idle"):format(infotext) |
| | | end |
| | |
| | | end |
| | | |
| | | for i = 0, 8 do |
| | | local groups = {snappy=2, choppy=2, oddly_breakable_by_hand=2, technic_machine=1} |
| | | local groups = {snappy=2, choppy=2, oddly_breakable_by_hand=2, |
| | | technic_machine=1, ["technic_"..ltier]=1} |
| | | if i ~= 0 then |
| | | groups.not_in_creative_inventory = 1 |
| | | end |
| | |
| | | "technic_"..ltier.."_battery_box_side.png^technic_power_meter"..i..".png", |
| | | "technic_"..ltier.."_battery_box_side.png^technic_power_meter"..i..".png"}, |
| | | groups = groups, |
| | | connect_sides = {"bottom"}, |
| | | tube = data.tube and tube or nil, |
| | | paramtype2 = "facedir", |
| | | sounds = default.node_sound_wood_defaults(), |
| | |
| | | allow_metadata_inventory_take = technic.machine_inventory_take, |
| | | allow_metadata_inventory_move = technic.machine_inventory_move, |
| | | technic_run = run, |
| | | after_place_node = tube and pipeworks.after_place, |
| | | after_dig_node = tube and pipeworks.after_dig |
| | | after_place_node = data.tube and pipeworks.after_place, |
| | | after_dig_node = technic.machine_after_dig_node |
| | | }) |
| | | end |
| | | |