fix an issue with populateThrusterValues? idk how this regression happened...
This commit is contained in:
6
main.lua
6
main.lua
@@ -410,11 +410,11 @@ local function populateThrusterValues()
|
||||
thruster.power = thruster.thruster.getPower()
|
||||
elseif thruster.type == "rotator" then
|
||||
if thruster.transmission ~= nil then
|
||||
local transmissionType = peripheral.getType(thruster.transmission)
|
||||
local transmissionType = peripheral.getType(peripheral.wrap(thruster.transmission))
|
||||
if transmissionType == "analog_transmission" then
|
||||
thruster.power = (thruster.transmission.getSignal())/15
|
||||
thruster.power = (peripheral.wrap(thruster.transmission).getSignal())/15
|
||||
elseif transmissionType == "Create_RotationSpeedController" then
|
||||
thruster.power = (thruster.transmission.getTargetSpeed())/256
|
||||
thruster.power = (peripheral.wrap(thruster.transmission).getTargetSpeed())/256
|
||||
end
|
||||
else
|
||||
print("ERROR: Thruster "..peripheral.getName(thruster.thruster).." has no transmission.")
|
||||
|
||||
Reference in New Issue
Block a user