Code tidy, add .luacheckrc

Improve callbacks
This commit is contained in:
stujones11 2019-03-19 19:23:23 +00:00
parent fde2b72a68
commit 2a0b7808a1
11 changed files with 114 additions and 56 deletions

50
.luacheckrc Normal file
View file

@ -0,0 +1,50 @@
allow_defined_top = true
read_globals = {
"ItemStack",
"vector",
"VoxelArea",
"VoxelManip",
"PseudoRandom",
string = {fields = {"split"}},
table = {fields = {"copy"}},
math = {fields = {"hypot"}},
os = {fields = {"time"}},
}
globals = {
"minetest",
}
files["shooter/init.lua"] = {
globals = {"shooter"}
}
files["shooter_crossbow/init.lua"] = {
globals = {"shooter", "SHOOTER_ARROW_TOOL_CAPS", "dye"}
}
files["shooter_flaregun/init.lua"] = {
globals = {"shooter"}
}
files["shooter_grenade/init.lua"] = {
globals = {"shooter"}
}
files["shooter_guns/init.lua"] = {
globals = {"shooter"}
}
files["shooter_hook/init.lua"] = {
globals = {"shooter"}
}
files["shooter_rocket/init.lua"] = {
globals = {"shooter"}
}
files["shooter_turret/init.lua"] = {
globals = {"shooter", "player_api"}
}