fix luacheck warnings

This commit is contained in:
BuckarooBanzay 2020-06-18 11:42:23 +02:00
parent 022c6ad9a0
commit f3fbd1f75d
5 changed files with 26 additions and 33 deletions

View File

@ -28,6 +28,7 @@ read_globals = {
"protector", "isprotect",
"homedecor_expect_infinite_stacks",
"monitoring"
}
files["concrete/init.lua"].ignore = { "steel_ingot" }

View File

@ -7,12 +7,10 @@ local S = technic.getter
local illuminate = function(pos, mode)
local loc = {}
-- loc.x, loc.y, loc.z = pos.x, pos.y, pos.z
for y=1,3,1 do
for x=-3,3,1 do
for z = -3,3,1 do
loc = {x = pos.x - x, y = pos.y - y, z = pos.z - z}
local loc = {x = pos.x - x, y = pos.y - y, z = pos.z - z}
if mode then
if minetest.get_node(loc).name == "air" then
minetest.swap_node(loc, {name = "technic:dummy_light_source"})
@ -47,7 +45,6 @@ end
local led_off = function(pos, node)
local meta = minetest.get_meta(pos)
local eu_input = meta:get_int("LV_EU_input")
local machine_name = S("%s LED"):format("LV")
local machine_node = "technic:lv_led"
@ -80,7 +77,6 @@ end
local lamp_off = function(pos, node)
local meta = minetest.get_meta(pos)
local eu_input = meta:get_int("LV_EU_input")
local machine_name = S("%s Lamp"):format("LV")
local machine_node = "technic:lv_lamp"

View File

@ -258,12 +258,8 @@ technic.switching_station_run = function(pos)
local t0 = minetest.get_us_time()
local meta = minetest.get_meta(pos)
local meta1 = nil
local meta1
local pos1 = {}
local PR_EU = 0 -- EUs from PR nodes
local BA_PR_EU = 0 -- EUs from BA nodes (discharching)
local BA_RE_EU = 0 -- EUs to BA nodes (charging)
local RE_EU = 0 -- EUs to RE nodes
local tier = ""
local PR_nodes