Skip to content

Commit

Permalink
fix luacheck warnings and remove stray print()
Browse files Browse the repository at this point in the history
  • Loading branch information
OgelGames authored and SX committed Feb 23, 2021
1 parent 60ae65d commit b2369b3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
1 change: 0 additions & 1 deletion controller.lua
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ local function release_player(pos)
local player = minetest.get_player_by_name(players_on_controller[hash])
if player and player:get_properties()._is_gamecontroller then
local parent = player:get_attach()
print(dump(parent:get_properties()))
if parent then
player:set_detach()
end
Expand Down
4 changes: 2 additions & 2 deletions gpu.lua
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ local function runcommand(pos,meta,command)
local x1 = math.min(64,math.floor(command.x1))
local y1 = math.min(64,math.floor(command.y1))
local x2 = math.min(64,math.floor(command.x2))
local y2 = math.min(64,math.floor(command.y2))
local y2 = math.min(64,math.floor(command.y2))
if x1 < 1 or y1 < 1 or x2 < 1 or y2 < 1 then return end
x2 = math.min(x2,buffer.xsize)
y2 = math.min(y2,buffer.ysize)
Expand All @@ -227,7 +227,7 @@ local function runcommand(pos,meta,command)
tempbuf[dsty][dstx] = buffer[y][x]
end
end
digiline:receptor_send(pos,digiline.rules.default,command.channel,tempbuf)
digilines:receptor_send(pos,digilines.rules.default,command.channel,tempbuf)
elseif command.command == "drawrect" then
if type(command.buffer) ~= "number" or type(command.x1) ~= "number" or type(command.y1) ~= "number" or type(command.x2) ~= "number" or type(command.y2) ~= "number" then return end
local bufnum = math.floor(command.buffer)
Expand Down
7 changes: 3 additions & 4 deletions touchscreen.lua
Original file line number Diff line number Diff line change
Expand Up @@ -332,15 +332,14 @@ minetest.register_node("digistuff:advtouchscreen", {
fixed = {
{ -0.5, -0.5, 0.4, 0.5, 0.5, 0.5 }
}
},
_digistuff_channelcopier_fieldname = "channel",
},
_digistuff_channelcopier_fieldname = "channel",
_digistuff_channelcopier_onset = function(pos)
minetest.get_meta(pos):set_int("init",1)
digistuff.update_ts_formspec(pos)
end,
on_receive_fields = digistuff.ts_on_receive_fields,
digiline =
{
digiline = {
receptor = {},
effector = {
action = digistuff.ts_on_digiline_receive
Expand Down

0 comments on commit b2369b3

Please sign in to comment.