SmallJoker
2022-11-24 521c0b74bba5dd73cf7c0a59fde4a018813e835d
technic/machines/switching_station.lua
@@ -134,7 +134,8 @@
   --dprint(name.." is a "..machines[name])
   local meta = minetest.get_meta(pos)
   -- Normal tostring() does not have enough precision, neither does meta:set_int()
   meta:set_string(network.tier.."_network", string.format("%X", network_id))
   -- Bug: Cannot use hexadecimal notation for compression (LuaJIT Windows bug, #911)
   meta:set_string(network.tier.."_network", string.format("%.20g", network_id))
   if     eu_type == technic.producer then
      add_network_node(network.PR_nodes, pos, network_id)
@@ -355,6 +356,8 @@
         BA_eu_supply = BA_eu_supply + meta1:get_int(eu_supply_str)
         BA_eu_demand = BA_eu_demand + meta1:get_int(eu_demand_str)
      end
      -- Expose value for the supply converter
      meta:set_int("ba_demand", BA_eu_demand)
      --dprint("Total BA supply:"..BA_eu_supply)
      --dprint("Total BA demand:"..BA_eu_demand)