diff --git a/concrete/init.lua b/concrete/init.lua index de96738..bccf5ee 100644 --- a/concrete/init.lua +++ b/concrete/init.lua @@ -1,4 +1,4 @@ ---Minetest 0.4.7 mod: concrete +--Minetest 0.4.7 mod: concrete --(c) 2013 by RealBadAngel local technic = rawget(_G, "technic") or {} @@ -107,19 +107,19 @@ minetest.register_node(":technic:concrete_post_platform", { groups={cracky=1, level=2}, sounds = default.node_sound_stone_defaults(), paramtype = "light", - drawtype = "nodebox", + drawtype = "nodebox", node_box = { type = "fixed", fixed = {box_platform} }, on_place = function (itemstack, placer, pointed_thing) local node = minetest.get_node(pointed_thing.under) - if not technic.concrete_posts[node.name] then - return minetest.item_place_node(itemstack, placer, pointed_thing) + if not technic.concrete_posts[node.name] then + return minetest.item_place_node(itemstack, placer, pointed_thing) end local links = technic.concrete_posts[node.name] if links[6] ~= 0 then -- The post already has a platform - return minetest.item_place_node(itemstack, placer, pointed_thing) + return minetest.item_place_node(itemstack, placer, pointed_thing) end local id = technic.get_post_id({links[1], links[2], links[3], links[4], links[5], 1}) minetest.set_node(pointed_thing.under, {name="technic:concrete_post"..id}) @@ -135,7 +135,7 @@ local function gen_post_nodebox(x1, x2, z1, z2, y, platform) local zz = z1 + z2 if ((xx == 2 and zz == 0) or (xx == 0 and zz == 2)) and y == 0 then box = {} - else + else box = {box_center} end if x1 ~= 0 then @@ -235,7 +235,7 @@ for platform = 0, 1 do if id ~= 0 then groups.not_in_creative_inventory = 1 end - + local drop = "technic:concrete_post0" local after_dig_node = function(pos, oldnode, oldmetadata, digger) technic.update_posts(pos, false) @@ -255,7 +255,7 @@ for platform = 0, 1 do drop = drop, paramtype = "light", sunlight_propagates = true, - drawtype = "nodebox", + drawtype = "nodebox", node_box = { type = "fixed", fixed = gen_post_nodebox(x1, x2, z1, z2, y, platform), diff --git a/extranodes/init.lua b/extranodes/init.lua index d2ffb2e..41f1ee5 100644 --- a/extranodes/init.lua +++ b/extranodes/init.lua @@ -98,7 +98,7 @@ if minetest.get_modpath("moreblocks") then minetest.register_alias(modname .. ":panel_" .. origname .. "_vertical", newmod..":panel_" .. newname .. "_vertical") minetest.register_alias(modname .. ":micro_" .. origname .. "_bottom", newmod..":micro_" .. newname .. "_bottom") minetest.register_alias(modname .. ":micro_" .. origname .. "_top", newmod..":micro_" .. newname .. "_top") - end + end register_technic_stairs_alias("stairsplus", "concrete", "technic", "concrete") register_technic_stairs_alias("stairsplus", "marble", "technic", "marble") diff --git a/technic/init.lua b/technic/init.lua index 25361af..0e0f808 100644 --- a/technic/init.lua +++ b/technic/init.lua @@ -30,10 +30,10 @@ dofile(modpath.."/config.lua") -- Helper functions dofile(modpath.."/helpers.lua") --- Items +-- Items dofile(modpath.."/items.lua") --- Craft recipes for items +-- Craft recipes for items dofile(modpath.."/crafts.lua") -- Register functions diff --git a/technic/items.lua b/technic/items.lua index 27e05e4..8c664d4 100644 --- a/technic/items.lua +++ b/technic/items.lua @@ -35,7 +35,7 @@ minetest.register_tool("technic:blue_energy_crystal", { fleshy = {times={}, uses=10000, maxlevel=0} } } -}) +}) minetest.register_tool("technic:green_energy_crystal", { description = S("Green Energy Crystal"), @@ -51,7 +51,7 @@ minetest.register_tool("technic:green_energy_crystal", { fleshy = {times={}, uses=10000, maxlevel=0} } } -}) +}) minetest.register_tool("technic:red_energy_crystal", { description = S("Red Energy Crystal"), @@ -67,7 +67,7 @@ minetest.register_tool("technic:red_energy_crystal", { fleshy = {times={}, uses=10000, maxlevel=0} } } -}) +}) minetest.register_craftitem("technic:fine_copper_wire", { diff --git a/technic/machines/switching_station.lua b/technic/machines/switching_station.lua index d6f23a3..cad2191 100644 --- a/technic/machines/switching_station.lua +++ b/technic/machines/switching_station.lua @@ -198,7 +198,7 @@ minetest.register_abm({ end return end - + -- Which kind of network are we on: pos1 = {x=pos.x, y=pos.y-1, z=pos.z} @@ -211,7 +211,7 @@ minetest.register_abm({ meta:set_string("infotext", S("%s Has No Network"):format(machine_name)) return end - + -- Run all the nodes local function run_nodes(list) for _, pos2 in ipairs(list) do @@ -226,7 +226,7 @@ minetest.register_abm({ end end end - + run_nodes(PR_nodes) run_nodes(RE_nodes) run_nodes(BA_nodes) diff --git a/technic/tools/flashlight.lua b/technic/tools/flashlight.lua index 7b43d70..4ce6648 100644 --- a/technic/tools/flashlight.lua +++ b/technic/tools/flashlight.lua @@ -8,7 +8,7 @@ local S = technic.getter technic.register_power_tool("technic:flashlight", flashlight_max_charge) minetest.register_alias("technic:light_off", "air") - + minetest.register_tool("technic:flashlight", { description = S("Flashlight"), inventory_image = "technic_flashlight.png", diff --git a/technic/tools/mining_drill.lua b/technic/tools/mining_drill.lua index 8a25abe..72722e5 100644 --- a/technic/tools/mining_drill.lua +++ b/technic/tools/mining_drill.lua @@ -62,7 +62,7 @@ end local function drill_dig_it1 (player) local dir=player:get_look_dir() - if math.abs(dir.x)>math.abs(dir.z) then + if math.abs(dir.x)>math.abs(dir.z) then if dir.x>0 then return 0 end return 1 end @@ -152,7 +152,7 @@ local function drill_dig_it(pos, player, mode) if mode == 1 then drill_dig_it0(pos, player) end - + if mode == 2 then -- 3 deep dir = drill_dig_it1(player) if dir == 0 then -- x+ @@ -184,7 +184,7 @@ local function drill_dig_it(pos, player, mode) drill_dig_it0 (pos,player) end end - + if mode==3 then -- 3 wide dir=drill_dig_it1(player) if dir==0 or dir==1 then -- x @@ -202,7 +202,7 @@ local function drill_dig_it(pos, player, mode) drill_dig_it0 (pos,player) end end - + if mode==4 then -- 3 tall, selected in the middle drill_dig_it0 (pos,player) pos.y=pos.y-1 @@ -225,7 +225,7 @@ local function drill_dig_it(pos, player, mode) drill_dig_it4(pos,player) end end - + minetest.sound_play("mining_drill", {pos = pos, gain = 1.0, max_hear_distance = 10,}) end diff --git a/technic/tools/prospector.lua b/technic/tools/prospector.lua index b28f1d8..f8dd359 100644 --- a/technic/tools/prospector.lua +++ b/technic/tools/prospector.lua @@ -93,7 +93,7 @@ minetest.register_tool("technic:prospector", { "label[0,7.5;Accuracy:]".. "label[0,8;98%]") return - end, + end, }) minetest.register_on_player_receive_fields(function(user, formname, fields) @@ -117,7 +117,7 @@ minetest.register_on_player_receive_fields(function(user, formname, fields) user:set_wielded_item(toolstack) return true end) - + minetest.register_craft({ output = "technic:prospector", recipe = { diff --git a/technic/tools/sonic_screwdriver.lua b/technic/tools/sonic_screwdriver.lua index 300d363..536f47c 100644 --- a/technic/tools/sonic_screwdriver.lua +++ b/technic/tools/sonic_screwdriver.lua @@ -86,7 +86,7 @@ minetest.register_tool("technic:sonic_screwdriver", { return itemstack end, }) - + minetest.register_craft({ output = "technic:sonic_screwdriver", recipe = { diff --git a/technic_worldgen/nodes.lua b/technic_worldgen/nodes.lua index 9e7e4e1..21f4d8b 100644 --- a/technic_worldgen/nodes.lua +++ b/technic_worldgen/nodes.lua @@ -8,7 +8,7 @@ minetest.register_node( ":technic:mineral_uranium", { groups = {cracky=3, radioactive=1000}, sounds = default.node_sound_stone_defaults(), drop = "technic:uranium_lump", -}) +}) minetest.register_node( ":technic:mineral_chromium", { description = S("Chromium Ore"), @@ -17,7 +17,7 @@ minetest.register_node( ":technic:mineral_chromium", { groups = {cracky=3}, sounds = default.node_sound_stone_defaults(), drop = "technic:chromium_lump", -}) +}) minetest.register_node( ":technic:mineral_zinc", { description = S("Zinc Ore"), @@ -52,7 +52,7 @@ minetest.register_node( ":technic:granite", { is_ground_content = true, groups = {cracky=1}, sounds = default.node_sound_stone_defaults(), -}) +}) minetest.register_node( ":technic:marble", { description = S("Marble"), @@ -60,7 +60,7 @@ minetest.register_node( ":technic:marble", { is_ground_content = true, groups = {cracky=3, marble=1}, sounds = default.node_sound_stone_defaults(), -}) +}) minetest.register_node( ":technic:marble_bricks", { description = S("Marble Bricks"), @@ -68,7 +68,7 @@ minetest.register_node( ":technic:marble_bricks", { is_ground_content = true, groups = {cracky=3}, sounds = default.node_sound_stone_defaults(), -}) +}) minetest.register_node(":technic:uranium_block", { description = S("Uranium Block"), diff --git a/wrench/init.lua b/wrench/init.lua index 76605c4..daee636 100644 --- a/wrench/init.lua +++ b/wrench/init.lua @@ -140,7 +140,7 @@ minetest.register_tool("wrench:wrench", { lists[listname] = list end metadata.lists = lists - + local metas = {} for name, meta_type in pairs(def.metas or {}) do if meta_type == wrench.META_TYPE_INT then @@ -152,7 +152,7 @@ minetest.register_tool("wrench:wrench", { end end metadata.metas = metas - + stack:set_metadata(minetest.serialize(metadata)) minetest.remove_node(pos) itemstack:add_wear(65535 / 20) diff --git a/wrench/support.lua b/wrench/support.lua index 1d21811..21aebfc 100644 --- a/wrench/support.lua +++ b/wrench/support.lua @@ -11,7 +11,7 @@ Syntax: store_meta_always = true, } owned - nodes that are protected by owner requirements (Ex. locked chests) - store_meta_always - when nodes are broken this ensures metadata and + store_meta_always - when nodes are broken this ensures metadata and inventory is always stored (Ex. active state for machines) --]] @@ -19,7 +19,7 @@ wrench.META_TYPE_INT = 0 wrench.META_TYPE_FLOAT = 1 wrench.META_TYPE_STRING = 2 -local INT, STRING, FLOAT = +local INT, STRING, FLOAT = wrench.META_TYPE_INT, wrench.META_TYPE_STRING, wrench.META_TYPE_FLOAT diff --git a/wrench/technic.lua b/wrench/technic.lua index c404180..5b529e8 100644 --- a/wrench/technic.lua +++ b/wrench/technic.lua @@ -1,5 +1,5 @@ -local INT, STRING, FLOAT = +local INT, STRING, FLOAT = wrench.META_TYPE_INT, wrench.META_TYPE_STRING, wrench.META_TYPE_FLOAT @@ -294,7 +294,7 @@ wrench:register_node("technic:mv_centrifuge_active", { local chest_mark_colors = { '_black', - '_blue', + '_blue', '_brown', '_cyan', '_dark_green',