Add a Luacheck configuration file and tweak code style

master
Hugo Locurcio 2019-02-21 13:42:38 +01:00
parent a0d37ec2aa
commit 8aac427d41
No known key found for this signature in database
GPG Key ID: 39E8F8BE30B0A49C
2 changed files with 29 additions and 3 deletions

25
.luacheckrc Normal file
View File

@ -0,0 +1,25 @@
std = "lua51+minetest"
unused_args = false
allow_defined_top = true
max_line_length = 90
stds.minetest = {
read_globals = {
"DIR_DELIM",
"minetest",
"core",
"dump",
"vector",
"nodeupdate",
"VoxelManip",
"VoxelArea",
"PseudoRandom",
"ItemStack",
"default",
table = {
fields = {
"copy",
},
},
}
}

View File

@ -11,7 +11,7 @@ minetest.register_ore({
ore_type = "scatter",
ore = "bedrock:bedrock",
wherein = "default:stone",
clust_scarcity = 1 * 1 * 1,
clust_scarcity = 1,
clust_num_ores = 5,
clust_size = 2,
height_min = -30912, -- Engine changes can modify this value
@ -22,7 +22,7 @@ minetest.register_ore({
ore_type = "scatter",
ore = "bedrock:deepstone",
wherein = "default:stone",
clust_scarcity = 1 * 1 * 1,
clust_scarcity = 1,
clust_num_ores = 5,
clust_size = 2,
height_min = -30656,
@ -33,7 +33,8 @@ minetest.register_node("bedrock:bedrock", {
description = "Bedrock",
tile_images = {"bedrock_bedrock.png"},
drop = "",
groups = {unbreakable = 1, not_in_creative_inventory = 1}, -- For Map Tools' admin pickaxe
-- Set `unbreakable` for Map Tools' admin pickaxe
groups = {unbreakable = 1, not_in_creative_inventory = 1},
sounds = default.node_sound_stone_defaults(),
})