Upload files to "Lua minecraft"

This commit is contained in:
2025-11-09 17:46:47 -05:00
parent 573cbaafbc
commit a0e08089e7
9 changed files with 1624 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
--Stable data
local p=peripheral.wrap("fissionReactorLogicAdapter_2")
local maxburn= tonumber(p.getMaxBurnRate())
local Height= tonumber(p.getHeight())
local Length= tonumber(p.getLength())
local Width= tonumber(p.getWidth())
local WasteCap= tonumber(p.getWasteCapacity())
local Coolantcap= tonumber(p.getCoolantCapacity())
local FuelCap= tonumber(p.getFuelCapacity())
while true do
--Live Data
local CurrentFuel= tonumber(p.getFuel().amount)
local CurrentCoolant= tonumber(p.getCoolant().amount)
local CurrentWaste= tonumber(p.getWaste().amount)
--Math
local TotalFuel= (CurrentFuel/FuelCap)*100
TotalFuel = string.format("%4.2f", TotalFuel)
local TotalCoolant= (CurrentCoolant/Coolantcap)*100
TotalCoolant = string.format("%4.2f", TotalCoolant)
local TotalWaste= (CurrentWaste/WasteCap)*100
TotalWaste = string.format("%4.2f", TotalWaste)
--Screen Clear
term.setCursorPos(0,0)
term.clear()
--Print Data
print("Max Burnrate: " .. maxburn .."\nCoolant Capacity: "..Coolantcap.."\nCoolant Percent: "..TotalCoolant.."\nCurrent Coolant: "..CurrentCoolant.."\nFuel Capacity: ".. FuelCap.."\nFuel Percent: "..TotalFuel.."\nCurrent Fuel: "..CurrentFuel.."\nWaste Capacity: "..WasteCap.."\nWaste Percent: "..TotalWaste.."\nCurrent Waste: "..CurrentWaste.."\nHeight: "..Height.."\nLength: "..Length.."\nWidth: "..Width)
sleep(1)
end