Added light:getRange()

This commit is contained in:
Fox 2016-07-24 09:47:59 -07:00 committed by GitHub
parent 22f3ac5f80
commit e9151e95a3

View File

@ -49,7 +49,7 @@ function light:move(x, y, z)
end end
end end
-- get x -- get position
function light:getPosition() function light:getPosition()
return self.x, self.y, self.z return self.x, self.y, self.z
end end
@ -61,6 +61,11 @@ function light:setColor(red, green, blue)
self.blue = blue self.blue = blue
end end
-- get range
function light:getRange()
return self.range
end
-- set range -- set range
function light:setRange(range) function light:setRange(range)
if range ~= self.range then if range ~= self.range then