From fbe33b14cd06d9a07121387a7a65f2d9de6bf9b2 Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Tue, 13 Jan 2015 21:08:35 +0100 Subject: [PATCH 01/15] HUD still buggy --- mods/hud/hunger.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/mods/hud/hunger.lua b/mods/hud/hunger.lua index 236af426..c9e74f39 100755 --- a/mods/hud/hunger.lua +++ b/mods/hud/hunger.lua @@ -368,6 +368,7 @@ function hud.handle_node_actions(pos, oldnode, player, ext) new = HUD_HUNGER_EXHAUST_MOVE end if exhaus == nil then return end + print("zerobin") print(exhaus) -- If exhaus goes through the condition exhaus = exhaus + new if exhaus > HUD_HUNGER_EXHAUST_LVL then From 69bd6f34450b247573518b88b658773db139768a Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Tue, 13 Jan 2015 21:17:48 +0100 Subject: [PATCH 02/15] Commented stuff --- mods/hud/hunger.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/hud/hunger.lua b/mods/hud/hunger.lua index c9e74f39..d26054c0 100755 --- a/mods/hud/hunger.lua +++ b/mods/hud/hunger.lua @@ -352,7 +352,7 @@ end -- player-action based hunger changes function hud.handle_node_actions(pos, oldnode, player, ext) - if not player or not player:is_player() then + --[[if not player or not player:is_player() then return end local name = player:get_player_name() @@ -379,7 +379,7 @@ function hud.handle_node_actions(pos, oldnode, player, ext) hud.hunger[name] = h hud.set_hunger(player) end - hud.exhaustion[name] = exhaus + hud.exhaustion[name] = exhaus]] end minetest.register_on_placenode(hud.handle_node_actions) From 0f7316f5e9532f6f353dcce4ea38b885c6723d29 Mon Sep 17 00:00:00 2001 From: crabman77 Date: Wed, 14 Jan 2015 13:58:13 +0100 Subject: [PATCH 03/15] correction de bug message irc pour shout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit correction d'une condition toujours fausse qui ne déclenche pas l'affichage du message pour l'option privs shout --- mods/_misc/noshout_messages.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/_misc/noshout_messages.lua b/mods/_misc/noshout_messages.lua index 889984d3..a61ef8e6 100755 --- a/mods/_misc/noshout_messages.lua +++ b/mods/_misc/noshout_messages.lua @@ -5,9 +5,9 @@ minetest.register_globalstep(function(dtime) TIMER = 0 for _,player in ipairs(minetest.get_connected_players()) do local name = player:get_player_name() - if not minetest.check_player_privs(name, {interact=shout}) then + if not minetest.check_player_privs(name, {shout=true}) then minetest.chat_send_player(name, "Hey " .. name .. " ! Pour pouvoir communiquer avec les autres joueurs sur ce serveur, tu dois lire les règles de l'irc et les accepter. Tape /irc.") minetest.chat_send_player(name, "Hey " .. name .. " ! To speak to other people on this server, you have to read the rules of our irc channel and agree them. Type /irc.") end end -end) \ No newline at end of file +end) From 1f248792a5a49dd022ee2ed48858e2fb7dbdf327 Mon Sep 17 00:00:00 2001 From: crabman77 Date: Wed, 14 Jan 2015 16:09:03 +0100 Subject: [PATCH 04/15] =?UTF-8?q?debug=20et=20am=C3=A9lioration=20de=20fut?= =?UTF-8?q?ure=5Fban?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit debug d'une mauvaise variable ajout d'une vérification pour éviter de rebannir un joueur déja banni --- mods/future_ban/init.lua | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/mods/future_ban/init.lua b/mods/future_ban/init.lua index d3854c8c..3380fbe4 100755 --- a/mods/future_ban/init.lua +++ b/mods/future_ban/init.lua @@ -26,6 +26,12 @@ minetest.register_chatcommand("future_ban", { minetest.chat_send_player(name, "Future ban list: " .. dump(future_ban_list)) return end + for _,n in ipairs(future_ban_list) do + if n == param then + minetest.chat_send_player(name, param .. " is already in future ban list.") + return + end + end if not minetest.get_player_by_name(param) then table.insert(future_ban_list, param) minetest.chat_send_player(name, param .. " to future ban list added.") @@ -35,8 +41,8 @@ minetest.register_chatcommand("future_ban", { end if not minetest.ban_player(param) then table.insert(future_ban_list, param) - minetest.chat_send_player(name, desc .. " to future ban list added.") - minetest.log("action", name .. " added " .. desc .. " to future ban list.") + minetest.chat_send_player(name, param .. " to future ban list added.") + minetest.log("action", name .. " added " .. param .. " to future ban list.") save_file() else local desc = minetest.get_ban_description(param) From 0dc48fc64367ea16dff75689c388c4621bcd0c0e Mon Sep 17 00:00:00 2001 From: crabman77 Date: Wed, 14 Jan 2015 17:33:46 +0100 Subject: [PATCH 05/15] passage de variables global en local passage de variables global en local --- mods/ambience_modpack/ambience/init.lua | 16 ++++++++-------- mods/builtin_falling/func.lua | 8 ++++---- mods/builtin_falling/rewirting.lua | 2 +- mods/builtin_item/init.lua | 2 +- mods/gauges/init.lua | 4 ++-- mods/lavatemple/dagger.lua | 8 ++++---- 6 files changed, 20 insertions(+), 20 deletions(-) diff --git a/mods/ambience_modpack/ambience/init.lua b/mods/ambience_modpack/ambience/init.lua index 11ae692e..3a14d97d 100755 --- a/mods/ambience_modpack/ambience/init.lua +++ b/mods/ambience_modpack/ambience/init.lua @@ -236,15 +236,15 @@ local is_daytime = function() end local nodes_in_range = function(pos, search_distance, node_name) - minp = {x=pos.x-search_distance,y=pos.y-search_distance, z=pos.z-search_distance} - maxp = {x=pos.x+search_distance,y=pos.y+search_distance, z=pos.z+search_distance} - nodes = minetest.find_nodes_in_area(minp, maxp, node_name) + local minp = {x=pos.x-search_distance,y=pos.y-search_distance, z=pos.z-search_distance} + local maxp = {x=pos.x+search_distance,y=pos.y+search_distance, z=pos.z+search_distance} + local nodes = minetest.find_nodes_in_area(minp, maxp, node_name) --minetest.chat_send_all("Found (" .. node_name .. ": " .. #nodes .. ")") return #nodes end local nodes_in_coords = function(minp, maxp, node_name) - nodes = minetest.find_nodes_in_area(minp, maxp, node_name) + local nodes = minetest.find_nodes_in_area(minp, maxp, node_name) --minetest.chat_send_all("Found (" .. node_name .. ": " .. #nodes .. ")") return #nodes end @@ -394,11 +394,11 @@ local get_ambience = function(player) -- minetest.chat_send_all("n3uf:" ..node_3_under_feet) -- local air_or_ignore = {air=true,ignore=true} - minp = {x=pos.x-3,y=pos.y-4, z=pos.z-3} - maxp = {x=pos.x+3,y=pos.y-1, z=pos.z+3} + local minp = {x=pos.x-3,y=pos.y-4, z=pos.z-3} + local maxp = {x=pos.x+3,y=pos.y-1, z=pos.z+3} local air_under_player = nodes_in_coords(minp, maxp, "air") local ignore_under_player = nodes_in_coords(minp, maxp, "ignore") - air_plus_ignore_under = air_under_player + ignore_under_player + local air_plus_ignore_under = air_under_player + ignore_under_player -- minetest.chat_send_all("airUnder:" ..air_under_player) -- minetest.chat_send_all("ignoreUnder:" ..ignore_under_player) -- minetest.chat_send_all("a+i:" ..air_plus_ignore_under) @@ -448,7 +448,7 @@ local get_ambience = function(player) end - desert_in_range = (nodes_in_range(pos, 6, "default:desert_sand")+nodes_in_range(pos, 6, "default:desert_stone")) + local desert_in_range = (nodes_in_range(pos, 6, "default:desert_sand")+nodes_in_range(pos, 6, "default:desert_stone")) --minetest.chat_send_all("desertcount: " .. desert_in_range .. ",".. pos.y ) if desert_in_range >250 then if music then diff --git a/mods/builtin_falling/func.lua b/mods/builtin_falling/func.lua index 478d2745..5d2a714e 100755 --- a/mods/builtin_falling/func.lua +++ b/mods/builtin_falling/func.lua @@ -1,6 +1,6 @@ function spawn_falling_node(p, node, owners) - obj = minetest.add_entity(p, "__builtin:falling_node") + local obj = minetest.add_entity(p, "__builtin:falling_node") obj:get_luaentity():set_node(node) obj:get_luaentity():set_owner(owners) end @@ -52,10 +52,10 @@ end -- function nodeupdate_single(p, delay) - n = minetest.get_node(p) + local n = minetest.get_node(p) if minetest.get_item_group(n.name, "falling_node") ~= 0 then - p_bottom = {x=p.x, y=p.y-1, z=p.z} - n_bottom = minetest.get_node(p_bottom) + local p_bottom = {x=p.x, y=p.y-1, z=p.z} + local n_bottom = minetest.get_node(p_bottom) -- Note: walkable is in the node definition, not in item groups if minetest.registered_nodes[n_bottom.name] and (minetest.get_item_group(n.name, "float") == 0 or diff --git a/mods/builtin_falling/rewirting.lua b/mods/builtin_falling/rewirting.lua index 5033c1e4..af78035d 100755 --- a/mods/builtin_falling/rewirting.lua +++ b/mods/builtin_falling/rewirting.lua @@ -29,7 +29,7 @@ minetest.register_entity(":__builtin:falling_node", { item_texture = minetest.registered_items[itemname].inventory_image item_type = minetest.registered_items[itemname].type end - prop = { + local prop = { is_visible = true, textures = {node.name}, } diff --git a/mods/builtin_item/init.lua b/mods/builtin_item/init.lua index cd58665f..b5fbd6c6 100755 --- a/mods/builtin_item/init.lua +++ b/mods/builtin_item/init.lua @@ -30,7 +30,7 @@ minetest.register_entity(":__builtin:item", { item_texture = minetest.registered_items[itemname].inventory_image item_type = minetest.registered_items[itemname].type end - prop = { + local prop = { is_visible = true, visual = "sprite", textures = {"unknown_item.png"} diff --git a/mods/gauges/init.lua b/mods/gauges/init.lua index f9134cbf..c2c66d0a 100755 --- a/mods/gauges/init.lua +++ b/mods/gauges/init.lua @@ -19,8 +19,8 @@ function hp_bar:on_step(dtime) self.object:remove() return end - hp = wielder:get_hp() - breath = wielder:get_breath() + local hp = wielder:get_hp() + local breath = wielder:get_breath() self.object:set_properties({textures = {"health_" .. tostring(hp) .. ".png^breath_" .. tostring(breath) .. ".png"}}) end diff --git a/mods/lavatemple/dagger.lua b/mods/lavatemple/dagger.lua index bdd3c5d1..e1e24f13 100755 --- a/mods/lavatemple/dagger.lua +++ b/mods/lavatemple/dagger.lua @@ -3,13 +3,13 @@ minetest.register_globalstep(function(dtime) local players = minetest.get_connected_players() for i,player in ipairs(players) do - target = lavatemple.mapgen_data.pos; + local target = lavatemple.mapgen_data.pos; if not target then return end - pos = player:getpos() - dir = player:get_look_yaw() + local pos = player:getpos() + local dir = player:get_look_yaw() local angle_north = math.deg(math.atan2(target.x - pos.x, target.z - pos.z)) if angle_north < 0 then angle_north = angle_north + 360 end - angle_dir = 90 - math.deg(dir) + local angle_dir = 90 - math.deg(dir) local angle_relative = (angle_north - angle_dir) % 360 local compass_image = math.floor((angle_relative/30) + 0.5)%12 From db6c18ee365535eb76d3c2e63f7da3496acd0227 Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Wed, 14 Jan 2015 23:16:22 +0100 Subject: [PATCH 06/15] Removed debug print from crabman77's pull-request in sprint --- mods/sprint/esprint.lua | 1 - 1 file changed, 1 deletion(-) diff --git a/mods/sprint/esprint.lua b/mods/sprint/esprint.lua index 4ae36218..d200b2ed 100755 --- a/mods/sprint/esprint.lua +++ b/mods/sprint/esprint.lua @@ -12,7 +12,6 @@ local staminaHud = {} minetest.register_on_joinplayer(function(player) local playerName = player:get_player_name() - print("playename: " ..playerName) players[playerName] = { sprinting = false, timeOut = 0, From e1ba20639b9453aed40b93af9b551fdd782840e0 Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 18:57:59 +0100 Subject: [PATCH 07/15] Removed global variables in maptools --- mods/maptools/default_nodes.lua | 70 +++++++++++++++++---------------- 1 file changed, 36 insertions(+), 34 deletions(-) diff --git a/mods/maptools/default_nodes.lua b/mods/maptools/default_nodes.lua index 83d0df02..f7667586 100644 --- a/mods/maptools/default_nodes.lua +++ b/mods/maptools/default_nodes.lua @@ -6,13 +6,15 @@ if (minetest.get_modpath("intllib")) then S = function ( s ) return s end end + + minetest.register_node("maptools:stone", { description = S("Unbreakable Stone"), range = 12, stack_max = 10000, tiles = {"default_stone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -22,7 +24,7 @@ minetest.register_node("maptools:stonebrick", { stack_max = 10000, tiles = {"default_stone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -32,7 +34,7 @@ minetest.register_node("maptools:tree", { stack_max = 10000, tiles = {"default_tree_top.png", "default_tree_top.png", "default_tree.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -43,7 +45,7 @@ minetest.register_node("maptools:jungletree", { stack_max = 10000, tiles = {"default_jungletree_top.png", "default_jungletree_top.png", "default_jungletree.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -54,7 +56,7 @@ minetest.register_node("maptools:cactus", { stack_max = 10000, tiles = {"default_cactus_top.png", "default_cactus_top.png", "default_cactus_side.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -75,7 +77,7 @@ minetest.register_node("maptools:papyrus", { type = "fixed", fixed = {-0.375, -0.5, -0.375, 0.375, 0.5, 0.375} }, - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_leaves_defaults(), }) @@ -85,7 +87,7 @@ minetest.register_node("maptools:dirt", { stack_max = 10000, tiles = {"default_dirt.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_dirt_defaults(), }) @@ -95,7 +97,7 @@ minetest.register_node("maptools:wood", { stack_max = 10000, tiles = {"default_wood.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_wood_defaults(), }) @@ -105,7 +107,7 @@ minetest.register_node("maptools:junglewood", { stack_max = 10000, tiles = {"default_junglewood.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_wood_defaults(), }) @@ -118,7 +120,7 @@ minetest.register_node("maptools:glass", { paramtype = "light", sunlight_propagates = true, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_glass_defaults(), }) @@ -130,7 +132,7 @@ minetest.register_node("maptools:leaves", { tiles = {"default_leaves.png"}, paramtype = "light", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_leaves_defaults(), }) @@ -140,7 +142,7 @@ minetest.register_node("maptools:sand", { stack_max = 10000, tiles = {"default_sand.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_sand_defaults(), }) @@ -150,7 +152,7 @@ minetest.register_node("maptools:gravel", { stack_max = 10000, tiles = {"default_gravel.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_gravel_footstep", gain=0.35}, dug = {name="default_gravel_footstep", gain=0.6}, @@ -163,7 +165,7 @@ minetest.register_node("maptools:clay", { stack_max = 10000, tiles = {"default_clay.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_dirt_defaults(), }) @@ -173,7 +175,7 @@ minetest.register_node("maptools:desert_sand", { stack_max = 10000, tiles = {"default_desert_sand.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_sand_defaults(), }) @@ -183,7 +185,7 @@ minetest.register_node("maptools:sandstone", { stack_max = 10000, tiles = {"default_sandstone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -193,7 +195,7 @@ minetest.register_node("maptools:sandstone_brick", { stack_max = 10000, tiles = {"default_sandstone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -203,7 +205,7 @@ minetest.register_node("maptools:desert_stone", { stack_max = 10000, tiles = {"default_desert_stone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -213,7 +215,7 @@ minetest.register_node("maptools:desert_cobble", { stack_max = 10000, tiles = {"default_desert_cobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -223,7 +225,7 @@ minetest.register_node("maptools:desert_stonebrick", { stack_max = 10000, tiles = {"default_desert_stone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -234,7 +236,7 @@ minetest.register_node("maptools:grass", { tiles = {"default_grass.png", "default_dirt.png", "default_dirt.png^default_grass_side.png"}, paramtype2 = "facedir", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_grass_footstep", gain = 0.4}, }), @@ -246,7 +248,7 @@ minetest.register_node("maptools:fullgrass", { stack_max = 10000, tiles = {"default_grass.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_grass_footstep", gain=0.4}, }), @@ -267,7 +269,7 @@ for slab_num = 1,3,1 do paramtype = "light", paramtype2 = "facedir", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_dirt_defaults({footstep = {name="default_grass_footstep", gain = 0.4}}), }) end @@ -278,7 +280,7 @@ minetest.register_node("maptools:cobble", { stack_max = 10000, tiles = {"default_cobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -288,7 +290,7 @@ minetest.register_node("maptools:mossycobble", { stack_max = 10000, tiles = {"default_mossycobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -298,7 +300,7 @@ minetest.register_node("maptools:brick", { stack_max = 10000, tiles = {"default_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -308,7 +310,7 @@ minetest.register_node("maptools:coalblock", { stack_max = 10000, tiles = {"default_coal_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -319,7 +321,7 @@ minetest.register_node("maptools:steelblock", { stack_max = 10000, tiles = {"default_steel_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -329,7 +331,7 @@ minetest.register_node("maptools:goldblock", { stack_max = 10000, tiles = {"default_gold_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -339,7 +341,7 @@ minetest.register_node("maptools:copperblock", { stack_max = 10000, tiles = {"default_copper_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -349,7 +351,7 @@ minetest.register_node("maptools:bronzeblock", { stack_max = 10000, tiles = {"default_bronze_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -359,7 +361,7 @@ minetest.register_node("maptools:diamondblock", { stack_max = 10000, tiles = {"default_diamond_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, sounds = default.node_sound_stone_defaults(), }) @@ -371,7 +373,7 @@ minetest.register_node("maptools:soil_wet", { stack_max = 10000, tiles = {"farming_soil_wet.png", "farming_soil_wet_side.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative, soil = 3, wet = 1, grassland = 1}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, soil = 3, wet = 1, grassland = 1}, sounds = default.node_sound_dirt_defaults(), }) @@ -381,6 +383,6 @@ minetest.register_node("maptools:desert_sand_soil_wet", { stack_max = 10000, drop = "", tiles = {"farming_desert_sand_soil_wet.png", "farming_desert_sand_soil_wet_side.png"}, - groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative, soil = 3, wet = 1, desert = 1}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, soil = 3, wet = 1, desert = 1}, sounds = default.node_sound_sand_defaults(), }) From a19c57fe440216c262ca8406ee23caeee24e6623 Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 19:06:12 +0100 Subject: [PATCH 08/15] Maptool's update --- mods/maptools/{LICENSE.txt => LICENSE.md} | 7 +- mods/maptools/NODES.md | 45 ++ mods/maptools/README.md | 11 + mods/maptools/README.txt | 22 - mods/maptools/_README.txt | 53 -- mods/maptools/aliases.lua | 9 +- mods/maptools/config.lua | 29 + mods/maptools/craftitems.lua | 47 ++ mods/maptools/default_nodes.lua | 85 +-- mods/maptools/init.lua | 583 +----------------- mods/maptools/nodes.lua | 429 +++++++++++++ .../textures/maptools_super_apple_bottom.png | Bin 295 -> 0 bytes .../textures/maptools_super_apple_side.png | Bin 295 -> 0 bytes .../textures/maptools_super_apple_top.png | Bin 498 -> 0 bytes mods/maptools/tools.lua | 61 ++ 15 files changed, 707 insertions(+), 674 deletions(-) rename mods/maptools/{LICENSE.txt => LICENSE.md} (71%) create mode 100644 mods/maptools/NODES.md create mode 100644 mods/maptools/README.md delete mode 100644 mods/maptools/README.txt delete mode 100644 mods/maptools/_README.txt create mode 100644 mods/maptools/config.lua create mode 100644 mods/maptools/craftitems.lua create mode 100644 mods/maptools/nodes.lua delete mode 100644 mods/maptools/textures/maptools_super_apple_bottom.png delete mode 100644 mods/maptools/textures/maptools_super_apple_side.png delete mode 100644 mods/maptools/textures/maptools_super_apple_top.png create mode 100644 mods/maptools/tools.lua diff --git a/mods/maptools/LICENSE.txt b/mods/maptools/LICENSE.md similarity index 71% rename from mods/maptools/LICENSE.txt rename to mods/maptools/LICENSE.md index f42bd647..ca48e3a1 100644 --- a/mods/maptools/LICENSE.txt +++ b/mods/maptools/LICENSE.md @@ -1,8 +1,9 @@ -+---- zlib/libpng license ----+ +zlib license +============ -Copyright (c) 2013 Calinou +Copyright (c) 2012-2015 Calinou and contributors -This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. +**This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.** Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: diff --git a/mods/maptools/NODES.md b/mods/maptools/NODES.md new file mode 100644 index 00000000..f5ce3cc3 --- /dev/null +++ b/mods/maptools/NODES.md @@ -0,0 +1,45 @@ +Item names for spawning the items using /give or /giveme +======================================================== + +Items +----- + +* `admin_pick:` magenta pickaxe, infinite durability, mines everything including unbreakable blocks instantly. No drops. Don't put this pickaxe in the hands of a griefer, of course. + +* `admin_pick_with_drops:` same as admin pickaxe, but drops stuff. + +* `infinite_fuel:` fuel lasting for a (near)-infinite time. Don't worry about the "near" * it lasts for about 50 in-real-life years. + +* `super_apple:` a yellow apple which heals 20 HP. + +* `copper_coin,` +* `silver_coin,` +* `gold_coin:` these have nothing to do with the More Ores mod; they can be used as a currency for trading, or as an universal currency for mods that add shops. + +Blocks +------ + +**[!]** denotes an unpointable, unbreakable block; be very careful with them, they cannot be removed by hand (they can only be removed with WorldEdit or similar). + + +* `(block)_u` : unbreakable, non-flammable, non-falling, non-decaying blocks, most common blocks have their unbreakable form (examples: maptools:stone or maptools:wood for unbreakable stone/wood). Examples: `stone_u`, `wood_u`, `glass_u`, … + +* `full_grass:` unbreakable block with the grass texture on all sides. + +* `player_clip:` **[!]** invisible block, not pointable. + +* `full_clip:` invisible block, pointable. Also available as a thin face: full_clip_face. + +* `smoke_block:` some smoke (does not harm players or entities). + +* `no_build:` **[!]** very basic building prevention. + +* `no_interact:` prevents interacting through the block (opening chests, furnaces, attacking entities, …). + +* `damage_(1…5):` **[!]** damaging blocks. The damage is in half hearts and ranges from 1 to 5 (0.5 to 2.5 hearts damage every second). + +* `kill:` **[!]** instant kill (deals 10 heart damage) blocks. + +* `light_block:` **[!]** invisible non-solid block, prevents light from passing through. + +* `light_bulb:` **[!]** invisible non-solid block, emitting a good amount of light. diff --git a/mods/maptools/README.md b/mods/maptools/README.md new file mode 100644 index 00000000..3a428b7e --- /dev/null +++ b/mods/maptools/README.md @@ -0,0 +1,11 @@ +Map Tools +========= + +Map Tools for Minetest , a free/libre infinite +world block sandbox game. + +To install, just clone this repository into your "mods" directory. + +Map Tools code is licensed under the zlib license, textures are by Calinou and are licensed under CC BY-SA 3.0 Unported. + +**Forum topic:** diff --git a/mods/maptools/README.txt b/mods/maptools/README.txt deleted file mode 100644 index 4c155813..00000000 --- a/mods/maptools/README.txt +++ /dev/null @@ -1,22 +0,0 @@ -Calinou's Minetest Mods -===================== - -Calinou's Mods for Minetest [http://minetest.net], a free and opensource Minecraft-like game. - -This Git repository is mostly made for servers; it allows easy updating. - -To install, just clone this repository somewhere, then copy the "calinou_mods" folder in the "mods/minetest" folder of Minetest's installation folder. - - - -Misc stuff -===================== - -All these mods' source codes, except More Ores are under the zlib/libpng license. More Ores is under the GNU GPLv3; the mods' textures are under the CC BY-SA 3.0 Unported. - -Mods' forum threads: -More Blocks: http://minetest.net/forum/viewtopic.php?id=509 -More Ores: http://minetest.net/forum/viewtopic.php?id=549 -Map Tools: http://minetest.net/forum/viewtopic.php?id=1882 -Doors+: http://minetest.net/forum/viewtopic.php?id=2059 -Stairs+: http://minetest.net/forum/viewtopic.php?id=2092 diff --git a/mods/maptools/_README.txt b/mods/maptools/_README.txt deleted file mode 100644 index cfbe0b2e..00000000 --- a/mods/maptools/_README.txt +++ /dev/null @@ -1,53 +0,0 @@ -*** Item names for spawning the items using /give or /giveme *** - -Items: - -- admin_pick -Purple pickaxe, infinite durability, mines everything including unbreakable blocks instantly. Don't put this pickaxe in the hands of a griefer, of course. :) - -- infinitefuel -Fuel lasting for a (near)-infinite time. Don't worry about the "near" - it lasts for about 50 in-real-life years. - -- superapple -An apple which heals all 10 hearts. - -- copper_coin -- silver_coin -- gold_coin -These have nothing to do with the More Ores mod; they can be used as a currency for trading, or as an universal currency for mods that add shops. - -Blocks: -A /!\ denotes an unpointable, unbreakable block; be very careful with them, they cannot be removed by hand (they can only be removed with WorldEdit). - -- (insert block name here)_u -- example: stone_u -Unbreakable, non-flammable, non-falling, non-decaying blocks, most common blocks have their unbreakable form (examples: maptools:stone or maptools:wood for unbreakable stone/wood). - -- fullgrass -Unbrakable block with the "grass" texture on all sides. - -- playerclip -/!\ Invisible block, not pointable. - -- fullclip -Invisible block, pointable. - -- smoke_block -Some smoke (does not harm players or entities). - -- nobuild -/!\ Very basic building prevention. - -- nointeract -Prevents interacting through the block (interacting as in opening chests, furnaces, attacking entities...). - -- damage_(insert damage in half hearts here) -/!\ Damaging blocks. The damage is in half hearts and ranges from 1 to 5 (0.5 to 2.5 hearts damage every second). - -- killblock -/!\ Instant kill (deals 10 heart damage) blocks. - -- lightblock -/!\ Invisible non-solid block, prevents light from passing through. - -- lightbulb -/!\ Invisible non-solid block, emitting a good amount of light. diff --git a/mods/maptools/aliases.lua b/mods/maptools/aliases.lua index 8742f44e..f1f0cc57 100644 --- a/mods/maptools/aliases.lua +++ b/mods/maptools/aliases.lua @@ -1,4 +1,9 @@ --- Aliases +--[[ +Map Tools: alias definitions + +Copyright (c) 2012-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] minetest.register_alias("adminpick", "maptools:pick_admin") minetest.register_alias("adminpickaxe", "maptools:pick_admin") @@ -69,8 +74,6 @@ minetest.register_alias("fake_fire", "maptools:fake_fire") minetest.register_alias("ffire", "maptools:fake_fire") minetest.register_alias("igniter", "maptools:igniter") --- Unbreakable block aliases - minetest.register_alias("stone_u", "maptools:stone") minetest.register_alias("tree_u", "maptools:tree") minetest.register_alias("cobble_u", "maptools:cobble") diff --git a/mods/maptools/config.lua b/mods/maptools/config.lua new file mode 100644 index 00000000..63f1a260 --- /dev/null +++ b/mods/maptools/config.lua @@ -0,0 +1,29 @@ +--[[ +Map Tools: configuration handling + +Copyright (c) 2012-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +maptools.config = {} + +local function getbool_default(setting, default) + local value = minetest.setting_getbool(setting) + if value == nil then + value = default + end + return value +end + +local function setting(settingtype, name, default) + if settingtype == "bool" then + maptools.config[name] = + getbool_default("maptools." .. name, default) + else + maptools.config[name] = + minetest.setting_get("maptools." .. name) or default + end +end + +-- Show Map Tools stuff in creative inventory (1 or 0): +setting("integer", "hide_from_creative_inventory", 1) diff --git a/mods/maptools/craftitems.lua b/mods/maptools/craftitems.lua new file mode 100644 index 00000000..c311aa95 --- /dev/null +++ b/mods/maptools/craftitems.lua @@ -0,0 +1,47 @@ +--[[ +Map Tools: item definitions + +Copyright (c) 2012-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = maptools.intllib + +maptools.creative = maptools.config["hide_from_creative_inventory"] + +minetest.register_craftitem("maptools:copper_coin", { + description = S("Copper Coin"), + inventory_image = "maptools_copper_coin.png", + wield_scale = {x = 0.5, y = 0.5, z = 0.25}, + stack_max = 10000, + groups = {not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_craftitem("maptools:silver_coin", { + description = S("Silver Coin"), + inventory_image = "maptools_silver_coin.png", + wield_scale = {x = 0.5, y = 0.5, z = 0.25}, + stack_max = 10000, + groups = {not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_craftitem("maptools:gold_coin", { + description = S("Gold Coin"), + inventory_image = "maptools_gold_coin.png", + wield_scale = {x = 0.5, y = 0.5, z = 0.25}, + stack_max = 10000, + groups = {not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_craftitem("maptools:infinitefuel", { + description = S("Infinite Fuel"), + inventory_image = "maptools_infinitefuel.png", + stack_max = 10000, + groups = {not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_craft({ + type = "fuel", + recipe = "maptools:infinitefuel", + burntime = 1000000000, +}) diff --git a/mods/maptools/default_nodes.lua b/mods/maptools/default_nodes.lua index f7667586..3ac0caf5 100644 --- a/mods/maptools/default_nodes.lua +++ b/mods/maptools/default_nodes.lua @@ -1,12 +1,13 @@ -local S -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) - else - S = function ( s ) return s end -end +--[[ +Map Tools: unbreakable default nodes +Copyright (c) 2012-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] +local S = maptools.intllib + +maptools.creative = maptools.config["hide_from_creative_inventory"] minetest.register_node("maptools:stone", { description = S("Unbreakable Stone"), @@ -14,7 +15,7 @@ minetest.register_node("maptools:stone", { stack_max = 10000, tiles = {"default_stone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -24,7 +25,7 @@ minetest.register_node("maptools:stonebrick", { stack_max = 10000, tiles = {"default_stone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -34,7 +35,7 @@ minetest.register_node("maptools:tree", { stack_max = 10000, tiles = {"default_tree_top.png", "default_tree_top.png", "default_tree.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -45,7 +46,7 @@ minetest.register_node("maptools:jungletree", { stack_max = 10000, tiles = {"default_jungletree_top.png", "default_jungletree_top.png", "default_jungletree.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -56,7 +57,7 @@ minetest.register_node("maptools:cactus", { stack_max = 10000, tiles = {"default_cactus_top.png", "default_cactus_top.png", "default_cactus_side.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -77,7 +78,7 @@ minetest.register_node("maptools:papyrus", { type = "fixed", fixed = {-0.375, -0.5, -0.375, 0.375, 0.5, 0.375} }, - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_leaves_defaults(), }) @@ -87,7 +88,7 @@ minetest.register_node("maptools:dirt", { stack_max = 10000, tiles = {"default_dirt.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_dirt_defaults(), }) @@ -97,7 +98,7 @@ minetest.register_node("maptools:wood", { stack_max = 10000, tiles = {"default_wood.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_wood_defaults(), }) @@ -107,7 +108,7 @@ minetest.register_node("maptools:junglewood", { stack_max = 10000, tiles = {"default_junglewood.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_wood_defaults(), }) @@ -120,7 +121,7 @@ minetest.register_node("maptools:glass", { paramtype = "light", sunlight_propagates = true, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_glass_defaults(), }) @@ -132,7 +133,7 @@ minetest.register_node("maptools:leaves", { tiles = {"default_leaves.png"}, paramtype = "light", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_leaves_defaults(), }) @@ -142,7 +143,7 @@ minetest.register_node("maptools:sand", { stack_max = 10000, tiles = {"default_sand.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_sand_defaults(), }) @@ -152,7 +153,7 @@ minetest.register_node("maptools:gravel", { stack_max = 10000, tiles = {"default_gravel.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_gravel_footstep", gain=0.35}, dug = {name="default_gravel_footstep", gain=0.6}, @@ -165,7 +166,7 @@ minetest.register_node("maptools:clay", { stack_max = 10000, tiles = {"default_clay.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_dirt_defaults(), }) @@ -175,7 +176,7 @@ minetest.register_node("maptools:desert_sand", { stack_max = 10000, tiles = {"default_desert_sand.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_sand_defaults(), }) @@ -185,7 +186,7 @@ minetest.register_node("maptools:sandstone", { stack_max = 10000, tiles = {"default_sandstone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -195,7 +196,7 @@ minetest.register_node("maptools:sandstone_brick", { stack_max = 10000, tiles = {"default_sandstone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -205,7 +206,7 @@ minetest.register_node("maptools:desert_stone", { stack_max = 10000, tiles = {"default_desert_stone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -215,7 +216,7 @@ minetest.register_node("maptools:desert_cobble", { stack_max = 10000, tiles = {"default_desert_cobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -225,7 +226,7 @@ minetest.register_node("maptools:desert_stonebrick", { stack_max = 10000, tiles = {"default_desert_stone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -236,7 +237,7 @@ minetest.register_node("maptools:grass", { tiles = {"default_grass.png", "default_dirt.png", "default_dirt.png^default_grass_side.png"}, paramtype2 = "facedir", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_grass_footstep", gain = 0.4}, }), @@ -248,7 +249,7 @@ minetest.register_node("maptools:fullgrass", { stack_max = 10000, tiles = {"default_grass.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_grass_footstep", gain=0.4}, }), @@ -269,7 +270,7 @@ for slab_num = 1,3,1 do paramtype = "light", paramtype2 = "facedir", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_dirt_defaults({footstep = {name="default_grass_footstep", gain = 0.4}}), }) end @@ -280,7 +281,7 @@ minetest.register_node("maptools:cobble", { stack_max = 10000, tiles = {"default_cobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -290,7 +291,7 @@ minetest.register_node("maptools:mossycobble", { stack_max = 10000, tiles = {"default_mossycobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -300,7 +301,7 @@ minetest.register_node("maptools:brick", { stack_max = 10000, tiles = {"default_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -310,7 +311,7 @@ minetest.register_node("maptools:coalblock", { stack_max = 10000, tiles = {"default_coal_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -321,7 +322,7 @@ minetest.register_node("maptools:steelblock", { stack_max = 10000, tiles = {"default_steel_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -331,7 +332,7 @@ minetest.register_node("maptools:goldblock", { stack_max = 10000, tiles = {"default_gold_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -341,7 +342,7 @@ minetest.register_node("maptools:copperblock", { stack_max = 10000, tiles = {"default_copper_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -351,7 +352,7 @@ minetest.register_node("maptools:bronzeblock", { stack_max = 10000, tiles = {"default_bronze_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -359,9 +360,9 @@ minetest.register_node("maptools:diamondblock", { description = S("Unbreakable Diamond Block"), range = 12, stack_max = 10000, - tiles = {"default_diamond_block.png"}, + tiles = {"default_steel_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, sounds = default.node_sound_stone_defaults(), }) @@ -373,7 +374,7 @@ minetest.register_node("maptools:soil_wet", { stack_max = 10000, tiles = {"farming_soil_wet.png", "farming_soil_wet_side.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, soil = 3, wet = 1, grassland = 1}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, soil = 3, wet = 1, grassland = 1}, sounds = default.node_sound_dirt_defaults(), }) @@ -383,6 +384,6 @@ minetest.register_node("maptools:desert_sand_soil_wet", { stack_max = 10000, drop = "", tiles = {"farming_desert_sand_soil_wet.png", "farming_desert_sand_soil_wet_side.png"}, - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, soil = 3, wet = 1, desert = 1}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, soil = 3, wet = 1, desert = 1}, sounds = default.node_sound_sand_defaults(), }) diff --git a/mods/maptools/init.lua b/mods/maptools/init.lua index c5178fae..dbff209c 100644 --- a/mods/maptools/init.lua +++ b/mods/maptools/init.lua @@ -1,551 +1,32 @@ -MAPTOOLS_CREATIVE = 1 -- Set this to 0 if you want Map Tools nodes and items to appear in the creative inventory. - --- Load translation library if intllib is installed - -local S -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) - else - S = function ( s ) return s end -end - -dofile(minetest.get_modpath("maptools").."/aliases.lua") -dofile(minetest.get_modpath("maptools").."/default_nodes.lua") - ---[[ -Map Tools by Calinou -Licensed under the zlib license for code and CC BY-SA 3.0 for textures, see LICENSE.txt for info. ---]] - --- Redefine cloud so that the admin pickaxe can mine it. - -minetest.register_node(":default:cloud", { - description = S("Cloud"), - tiles = {"default_cloud.png"}, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - sounds = default.node_sound_defaults(), -}) - --- Items - -minetest.register_craft({ - type = "fuel", - recipe = "maptools:infinitefuel", - burntime = 1000000000, -}) - --- Nodes - -minetest.register_node("maptools:black", { - description = S("Black"), - range = 12, - stack_max = 10000, - tiles = {"black.png"}, - drop = "", - post_effect_color = {a=255, r=0, g=0, b=0}, - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - sounds = default.node_sound_stone_defaults(), -}) - -minetest.register_node("maptools:white", { - description = S("White"), - range = 12, - stack_max = 10000, - tiles = {"white.png"}, - drop = "", - post_effect_color = {a=255, r=128, g=128, b=128}, - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - sounds = default.node_sound_stone_defaults(), -}) - -minetest.register_node("maptools:playerclip", { - description = S("Player Clip"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_green.png", - drawtype = "airlike", - paramtype = "light", - pointable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:fake_walkable", { - description = S("Player Clip"), - drawtype = "nodebox", - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_green.png", - drawtype = "airlike", - paramtype = "light", - pointable = false, - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = { - {0, 0, 0, 0, 0, 0}, - }, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:fullclip", { - description = S("Full Clip"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_blue.png", - drawtype = "airlike", - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:fake_walkable_pointable", { - description = S("Player Clip"), - drawtype = "nodebox", - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_green.png", - drawtype = "airlike", - paramtype = "light", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = { - {0, 0, 0, 0, 0, 0}, - }, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:ignore_like", { - description = S("Ignore-like"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_pink.png", - tiles = {"invisible.png"}, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:ignore_like_no_clip", { - description = S("Ignore-like (no clip)"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_purple.png", - tiles = {"invisible.png"}, - paramtype = "light", - walkable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - - -minetest.register_node("maptools:ignore_like_no_point", { - description = S("Ignore-like (no point)"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_purple.png", - tiles = {"invisible.png"}, - paramtype = "light", - pointable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:ignore_like_no_clip_no_point", { - description = S("Ignore-like (no clip, no point)"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_pink.png", - tiles = {"invisible.png"}, - paramtype = "light", - walkable = false, - pointable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:fullclip_face", { - description = S("Full Clip Face"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_white.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - paramtype = "light", - paramtype2 = "facedir", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100}, -}) - -minetest.register_node("maptools:playerclip_bottom", { - description = S("Player Clip Bottom Face"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_orange.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100}, -}) - -minetest.register_node("maptools:playerclip_top", { - description = S("Player Clip Top Face"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_yellow.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, 0.4999, -0.5, 0.5, 0.5, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100}, -}) - -for pusher_num=1,10,1 do -minetest.register_node("maptools:pusher_" .. pusher_num, { - description = S("Pusher (%s)"):format(pusher_num), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_apple.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - paramtype = "light", - paramtype2 = "facedir", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100, bouncy=pusher_num*100}, -}) -end - -minetest.register_node("maptools:lightbulb", { - description = S("Light Bulb"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_mese_crystal_fragment.png", - drawtype = "airlike", - walkable = false, - pointable = false, - light_source = 15, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:nobuild", { - description = S("Build Prevention"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^bones_bones.png", - drawtype = "airlike", - walkable = false, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:nointeract", { - description = S("Interact Prevention"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_scorched_stuff.png", - drawtype = "airlike", - walkable = false, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:climb", { - description = S("Climb Block"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_ladder.png", - drawtype = "airlike", - walkable = false, - climbable = true, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -for damage_num=1,5,1 do -minetest.register_node("maptools:damage_" .. damage_num, { - description = S("Damaging Block (%s)"):format(damage_num), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^farming_cotton_" .. damage_num .. ".png", - drawtype = "airlike", - walkable = false, - pointable = false, - damage_per_second = damage_num, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) -end - -minetest.register_node("maptools:kill", { - description = S("Kill Block"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_black.png", - drawtype = "airlike", - walkable = false, - pointable = false, - damage_per_second = 20, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_node("maptools:smoke", { - description = S("Smoke Block"), - range = 12, - stack_max = 10000, - tiles = {"maptools_smoke.png"}, - drawtype = "allfaces_optional", - walkable = false, - paramtype = "light", - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - post_effect_color = {a=192, r=96, g=96, b=96}, -}) - -minetest.register_node("maptools:ladder", { - description = S("Fake Ladder"), - range = 12, - stack_max = 10000, - drawtype = "signlike", - tiles = {"default_ladder.png"}, - inventory_image = "default_ladder.png", - wield_image = "default_ladder.png", - paramtype = "light", - paramtype2 = "wallmounted", - walkable = false, - sunlight_propagates = true, - selection_box = { - type = "wallmounted", - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - sounds = default.node_sound_wood_defaults(), -}) - -minetest.register_node("maptools:permanent_fire", { - description = S("Permanent Fire"), - range = 12, - stack_max = 10000, - drawtype = "plantlike", - paramtype = "light", - tiles = {{ - name="fire_basic_flame_animated.png", - animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, - }}, - inventory_image = "fire_basic_flame.png", - light_source = 14, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - sunlight_propagates = true, - walkable = false, - damage_per_second = 4, -}) - -minetest.register_node("maptools:fake_fire", { - description = S("Fake Fire"), - range = 12, - stack_max = 10000, - drawtype = "plantlike", - paramtype = "light", - tiles = {{ - name="fire_basic_flame_animated.png", - animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, - }}, - inventory_image = "fire_basic_flame.png", - light_source = 14, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - sunlight_propagates = true, - walkable = false, -}) - -minetest.register_node("maptools:igniter", { - drawtype = "airlike", - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^crosshair.png", - description = S("Igniter"), - paramtype = "light", - inventory_image = "fire_basic_flame.png", - drop = "", - groups = {igniter=2, unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, - sunlight_propagates = true, - pointable = false, - walkable = false, -}) - -minetest.register_node("maptools:superapple", { - description = S("Super Apple"), - range = 12, - stack_max = 99, - drawtype = "nodebox", - visual_scale = 1.0, - tiles = {"maptools_super_apple_top.png","maptools_super_apple_bottom.png","maptools_super_apple_side.png"}, - inventory_image = "maptools_superapple.png", - paramtype = "light", - sunlight_propagates = true, - walkable = false, - node_box = { - type = "fixed", - fixed = { - {-3/16, -7/16, -3/16, 3/16, 1/16, 3/16}, - {-4/16, -6/16, -3/16, 4/16, 0, 3/16}, - {-3/16, -6/16, -4/16, 3/16, 0, 4/16}, - {-1/32, 1/16, -1/32, 1/32, 4/16, 1/32}, - {-1/16, 1.6/16, 0, 1/16, 1.8/16, 1/16}, - {-2/16, 1.4/16, 1/16, 1/16, 1.6/16, 2/16}, - {-2/16, 1.2/16, 2/16, 0, 1.4/16, 3/16}, - {-1.5/16, 1/16, .5/16, 0.5/16, 1.2/16, 2.5/16}, - } - }, - is_ground_content = true, - groups = {fleshy = 3, dig_immediate = 3, not_in_creative_inventory = 0, flammable = 2, leafdecay = 3, leafdecay_drop = 1}, - on_use = minetest.item_eat(20), - sounds = default.node_sound_leaves_defaults(), - after_place_node = function(pos, placer, itemstack) - if placer:is_player() then - minetest.set_node(pos, {name = "maptools:superapple", param2= 1}) - end - end, -}) - --- Items - -minetest.register_craftitem("maptools:copper_coin", { - description = S("Copper Coin"), - inventory_image = "maptools_copper_coin.png", - wield_scale = {x = 0.5, y = 0.5, z = 0.25}, - stack_max = 10000, - groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_craftitem("maptools:silver_coin", { - description = S("Silver Coin"), - inventory_image = "maptools_silver_coin.png", - wield_scale = {x = 0.5, y = 0.5, z = 0.25}, - stack_max = 10000, - groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_craftitem("maptools:gold_coin", { - description = S("Gold Coin"), - inventory_image = "maptools_gold_coin.png", - wield_scale = {x = 0.5, y = 0.5, z = 0.25}, - stack_max = 10000, - groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - -minetest.register_craftitem("maptools:infinitefuel", { - description = S("Infinite Fuel"), - inventory_image = "maptools_infinitefuel.png", - stack_max = 10000, - groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, -}) - --- Tools - -minetest.register_tool("maptools:pick_admin", { - description = S("Admin Pickaxe"), - range = 12, - inventory_image = "maptools_adminpick.png", - groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, - tool_capabilities = { - full_punch_interval = 0.1, - max_drop_level = 3, - groupcaps= { - unbreakable = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - fleshy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - choppy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - bendy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - cracky = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - crumbly = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - snappy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - }, - damage_groups = {fleshy = 1000}, - }, -}) - -minetest.register_tool("maptools:pick_admin_with_drops", { - description = S("Admin Pickaxe with Drops"), - range = 12, - inventory_image = "maptools_adminpick_with_drops.png", - groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, - tool_capabilities = { - full_punch_interval = 0.35, - max_drop_level = 3, - groupcaps = { - unbreakable = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - fleshy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - choppy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - bendy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - cracky = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - crumbly = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - snappy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, - }, - damage_groups = {fleshy = 1000}, - }, -}) - -minetest.register_on_punchnode(function(pos, node, puncher) - if puncher:get_wielded_item():get_name() == "maptools:pick_admin" - and minetest.get_node(pos).name ~= "air" then - minetest.log("action", puncher:get_player_name() .. " digs " .. minetest.get_node(pos).name .. " at " .. minetest.pos_to_string(pos) .. " using an Admin Pickaxe.") - minetest.remove_node(pos) -- The node is removed directly, which means it even works on non-empty containers and group-less nodes. - nodeupdate(pos) -- Run node update actions like falling nodes. - end -end) - -if minetest.setting_getbool("log_mods") then - minetest.log("action", "Carbone: [maptools] loaded.") -end +--[[ +===================================================================== +** Map Tools ** +By Calinou. + +Copyright (c) 2012-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +===================================================================== +--]] + +maptools = {} + +local S +if minetest.get_modpath("intllib") then + S = intllib.Getter() +else + S = function(s) return s end +end +maptools.intllib = S + +local modpath = minetest.get_modpath("maptools") + +dofile(modpath .. "/config.lua") +dofile(modpath .. "/aliases.lua") +dofile(modpath .. "/craftitems.lua") +dofile(modpath .. "/default_nodes.lua") +dofile(modpath .. "/nodes.lua") +dofile(modpath .. "/tools.lua") + +if minetest.setting_getbool("log_mods") then + minetest.log("action", S("[maptools] loaded.")) +end diff --git a/mods/maptools/nodes.lua b/mods/maptools/nodes.lua new file mode 100644 index 00000000..8ceef647 --- /dev/null +++ b/mods/maptools/nodes.lua @@ -0,0 +1,429 @@ +--[[ +Map Tools: node definitions + +Copyright (c) 2012-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = maptools.intllib + +maptools.creative = maptools.config["hide_from_creative_inventory"] + +-- Redefine cloud so that the admin pickaxe can mine it: +minetest.register_node(":default:cloud", { + description = S("Cloud"), + tiles = {"default_cloud.png"}, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + sounds = default.node_sound_defaults(), +}) + +-- Nodes +-- ===== + +minetest.register_node("maptools:black", { + description = S("Black"), + range = 12, + stack_max = 10000, + tiles = {"black.png"}, + drop = "", + post_effect_color = {a=255, r=0, g=0, b=0}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_node("maptools:white", { + description = S("White"), + range = 12, + stack_max = 10000, + tiles = {"white.png"}, + drop = "", + post_effect_color = {a=255, r=128, g=128, b=128}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_node("maptools:playerclip", { + description = S("Player Clip"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_green.png", + drawtype = "airlike", + paramtype = "light", + pointable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:fake_walkable", { + description = S("Player Clip"), + drawtype = "nodebox", + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_green.png", + drawtype = "airlike", + paramtype = "light", + pointable = false, + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = { + {0, 0, 0, 0, 0, 0}, + }, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:fullclip", { + description = S("Full Clip"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_blue.png", + drawtype = "airlike", + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:fake_walkable_pointable", { + description = S("Player Clip"), + drawtype = "nodebox", + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_green.png", + drawtype = "airlike", + paramtype = "light", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = { + {0, 0, 0, 0, 0, 0}, + }, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:ignore_like", { + description = S("Ignore-like"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_pink.png", + tiles = {"invisible.png"}, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:ignore_like_no_clip", { + description = S("Ignore-like (no clip)"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_purple.png", + tiles = {"invisible.png"}, + paramtype = "light", + walkable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + + +minetest.register_node("maptools:ignore_like_no_point", { + description = S("Ignore-like (no point)"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_purple.png", + tiles = {"invisible.png"}, + paramtype = "light", + pointable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:ignore_like_no_clip_no_point", { + description = S("Ignore-like (no clip, no point)"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_pink.png", + tiles = {"invisible.png"}, + paramtype = "light", + walkable = false, + pointable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:fullclip_face", { + description = S("Full Clip Face"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_white.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100}, +}) + +minetest.register_node("maptools:playerclip_bottom", { + description = S("Player Clip Bottom Face"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_orange.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100}, +}) + +minetest.register_node("maptools:playerclip_top", { + description = S("Player Clip Top Face"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_yellow.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, 0.4999, -0.5, 0.5, 0.5, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100}, +}) + +for pusher_num=1,10,1 do +minetest.register_node("maptools:pusher_" .. pusher_num, { + description = S("Pusher (%s)"):format(pusher_num), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_apple.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100, bouncy=pusher_num*100}, +}) +end + +minetest.register_node("maptools:lightbulb", { + description = S("Light Bulb"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_mese_crystal_fragment.png", + drawtype = "airlike", + walkable = false, + pointable = false, + light_source = 15, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:nobuild", { + description = S("Build Prevention"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^bones_bones.png", + drawtype = "airlike", + walkable = false, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:nointeract", { + description = S("Interact Prevention"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_scorched_stuff.png", + drawtype = "airlike", + walkable = false, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:climb", { + description = S("Climb Block"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_ladder.png", + drawtype = "airlike", + walkable = false, + climbable = true, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +for damage_num=1,5,1 do +minetest.register_node("maptools:damage_" .. damage_num, { + description = S("Damaging Block (%s)"):format(damage_num), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^farming_cotton_" .. damage_num .. ".png", + drawtype = "airlike", + walkable = false, + pointable = false, + damage_per_second = damage_num, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) +end + +minetest.register_node("maptools:kill", { + description = S("Kill Block"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_black.png", + drawtype = "airlike", + walkable = false, + pointable = false, + damage_per_second = 20, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, +}) + +minetest.register_node("maptools:smoke", { + description = S("Smoke Block"), + range = 12, + stack_max = 10000, + tiles = {"maptools_smoke.png"}, + drawtype = "allfaces_optional", + walkable = false, + paramtype = "light", + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + post_effect_color = {a=192, r=96, g=96, b=96}, +}) + +minetest.register_node("maptools:ladder", { + description = S("Fake Ladder"), + range = 12, + stack_max = 10000, + drawtype = "signlike", + tiles = {"default_ladder.png"}, + inventory_image = "default_ladder.png", + wield_image = "default_ladder.png", + paramtype = "light", + paramtype2 = "wallmounted", + walkable = false, + sunlight_propagates = true, + selection_box = { + type = "wallmounted", + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + sounds = default.node_sound_wood_defaults(), +}) + +minetest.register_node("maptools:permanent_fire", { + description = S("Permanent Fire"), + range = 12, + stack_max = 10000, + drawtype = "plantlike", + paramtype = "light", + tiles = {{ + name="fire_basic_flame_animated.png", + animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, + }}, + inventory_image = "fire_basic_flame.png", + light_source = 14, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + sunlight_propagates = true, + walkable = false, + damage_per_second = 4, +}) + +minetest.register_node("maptools:fake_fire", { + description = S("Fake Fire"), + range = 12, + stack_max = 10000, + drawtype = "plantlike", + paramtype = "light", + tiles = {{ + name="fire_basic_flame_animated.png", + animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, + }}, + inventory_image = "fire_basic_flame.png", + light_source = 14, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + sunlight_propagates = true, + walkable = false, +}) + +minetest.register_node("maptools:igniter", { + drawtype = "airlike", + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^crosshair.png", + description = S("Igniter"), + paramtype = "light", + inventory_image = "fire_basic_flame.png", + drop = "", + groups = {igniter=2, unbreakable = 1, not_in_creative_inventory = maptools.creative}, + sunlight_propagates = true, + pointable = false, + walkable = false, +}) + +minetest.register_node("maptools:superapple", { + description = S("Super Apple"), + range = 12, + stack_max = 10000, + drawtype = "plantlike", + visual_scale = 1.0, + tiles = {"maptools_superapple.png"}, + inventory_image = "maptools_superapple.png", + paramtype = "light", + sunlight_propagates = true, + selection_box = { + type = "fixed", + fixed = {-0.2, -0.5, -0.2, 0.2, 0, 0.2} + }, + walkable = false, + groups = {fleshy=3, dig_immediate=3, not_in_creative_inventory = maptools.creative}, + on_use = minetest.item_eat(20), + sounds = default.node_sound_defaults(), +}) diff --git a/mods/maptools/textures/maptools_super_apple_bottom.png b/mods/maptools/textures/maptools_super_apple_bottom.png deleted file mode 100644 index 97f61e171c0291015d80fb19c8cbae5a11436b2b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 295 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b z3=G`DAk4@xYmNj^kiEpy*OmPqkEEyw(>0&3oIs&1o-U3d7N?(1G~{Y_5OJA*I(_0% zraVvj6r-M*LXT7jAL4j?;3E=m$^F zGdWW47!ETWa|m1!KkfE!6)`c!=OPMBm3)c^Yz{yDG-u)srsoQ$58M(p@V&6@_HEt+ z60B#8dloaTxmxb?>?#N2rI2Q&TYDPz-rsnjI`?#OZrq-TAG!-(U%TmDeE;>L*!vOJ mfAt<)^VxO5sz=}duVb%TVcO~SWotOl{S2P2elF{r5}E)Rt8^Iv diff --git a/mods/maptools/textures/maptools_super_apple_side.png b/mods/maptools/textures/maptools_super_apple_side.png deleted file mode 100644 index cd4c83153f2abe5c0c2ed349e3c0d676b27a2f80..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 295 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b z3=G`DAk4@xYmNj^kiEpy*OmPqkEE!u^3{~$2|%GOo-U3d7N?(1G~{Y_5OJA*I(_0% zraVvj6r-M*LXT7jAL4j?;3E=m$^F zGdWW47!ETWa|m1!KkfE!6)`c!=OPMBm3)c^Yz{yDG-u)srsoQ$58M(p@V&6@_HEt+ z60B#8dloaTxmxb?>?#N2rI2Q&TYDPz-rsnjI`?#OZrq-TAG!-(U%TmDeE;>L*!vOJ mfAt<)^VxO5sz=}duVb%TVcO~SWotOl{S2P2elF{r5}E)>;dE61 diff --git a/mods/maptools/textures/maptools_super_apple_top.png b/mods/maptools/textures/maptools_super_apple_top.png deleted file mode 100644 index 4d4dbc056e1913768f70134e28a6bf551b87216b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 498 zcmV{Ut&2O5LW0q`a zv=Id$>4dnxgUhon0QI^&*J}AI;MYCiTY+p=^8M`^$0rfegE#=`xRfTB8%?L Date: Thu, 15 Jan 2015 19:12:20 +0100 Subject: [PATCH 09/15] Moreblocks' update - Moreblocks' update to use last version's nodes and features --- mods/moreblocks/{LICENSE.txt => LICENSE.md} | 7 +- mods/moreblocks/README.md | 11 + mods/moreblocks/README.txt | 12 - mods/moreblocks/aliases.lua | 21 +- mods/moreblocks/circular_saw.lua | 10 +- mods/moreblocks/config.lua | 7 + mods/moreblocks/crafting.lua | 7 +- mods/moreblocks/depends.txt | 4 +- mods/moreblocks/init.lua | 23 +- mods/moreblocks/locale/de.txt | 0 mods/moreblocks/locale/es.txt | 0 mods/moreblocks/locale/fr.txt | 0 mods/moreblocks/locale/template.txt | 0 mods/moreblocks/models/moreblocks_slope.obj | 21 + .../models/moreblocks_slope_half.obj | 23 + .../models/moreblocks_slope_half_raised.obj | 26 + .../models/moreblocks_slope_inner.obj | 26 + .../models/moreblocks_slope_inner_half.obj | 28 ++ .../moreblocks_slope_inner_half_raised.obj | 31 ++ .../models/moreblocks_slope_outer.obj | 18 + .../models/moreblocks_slope_outer_cut.obj | 19 + .../moreblocks_slope_outer_cut_half.obj | 20 + ...moreblocks_slope_outer_cut_half_raised.obj | 23 + .../models/moreblocks_slope_outer_half.obj | 22 + .../moreblocks_slope_outer_half_raised.obj | 27 ++ mods/moreblocks/nodes.lua | 14 +- mods/moreblocks/ownership.lua | 6 + mods/moreblocks/redefinitions.lua | 12 + mods/moreblocks/stairsplus/API.md | 3 +- mods/moreblocks/stairsplus/aliases.lua | 8 + mods/moreblocks/stairsplus/conversion.lua | 7 + mods/moreblocks/stairsplus/init.lua | 19 +- mods/moreblocks/stairsplus/microblocks.lua | 15 +- mods/moreblocks/stairsplus/panels.lua | 15 +- mods/moreblocks/stairsplus/registrations.lua | 11 +- mods/moreblocks/stairsplus/slabs.lua | 21 +- mods/moreblocks/stairsplus/slopes.lua | 459 ++++++++++++++++++ mods/moreblocks/stairsplus/stairs.lua | 21 +- mods/moreblocks/textures/default_brick.png | Bin .../textures/default_fence_overlay.png | Bin mods/moreblocks/textures/invisible.png | Bin .../textures/moreblocks_cactus_brick.png | Bin .../textures/moreblocks_cactus_checker.png | Bin .../moreblocks_circle_stone_bricks.png | Bin .../moreblocks_circular_saw_bottom.png | Bin .../textures/moreblocks_circular_saw_side.png | Bin .../textures/moreblocks_circular_saw_top.png | Bin .../textures/moreblocks_clean_glass.png | Bin .../textures/moreblocks_coal_checker.png | Bin .../textures/moreblocks_coal_glass.png | Bin .../moreblocks_coal_glass_stairsplus.png | Bin .../textures/moreblocks_coal_stone.png | Bin .../textures/moreblocks_coal_stone_bricks.png | Bin .../textures/moreblocks_empty_bookshelf.png | Bin .../textures/moreblocks_fence_jungle_wood.png | Bin .../textures/moreblocks_fence_wood.png | Bin mods/moreblocks/textures/moreblocks_glass.png | Bin .../textures/moreblocks_glass_stairsplus.png | Bin .../textures/moreblocks_glow_glass.png | Bin .../moreblocks_glow_glass_stairsplus.png | Bin .../textures/moreblocks_grey_bricks.png | Bin .../textures/moreblocks_iron_checker.png | Bin .../textures/moreblocks_iron_glass.png | Bin .../moreblocks_iron_glass_stairsplus.png | Bin .../textures/moreblocks_iron_stone.png | Bin .../textures/moreblocks_iron_stone_bricks.png | Bin .../textures/moreblocks_junglestick.png | Bin .../moreblocks_obsidian_glass_stairsplus.png | Bin .../textures/moreblocks_plankstone.png | Bin .../textures/moreblocks_plankstone_2.png | Bin mods/moreblocks/textures/moreblocks_rope.png | Bin .../textures/moreblocks_split_stone_tile.png | Bin .../moreblocks_split_stone_tile_alt.png | Bin .../moreblocks_split_stone_tile_top.png | Bin .../textures/moreblocks_stone_tile.png | Bin .../textures/moreblocks_super_glow_glass.png | Bin ...moreblocks_super_glow_glass_stairsplus.png | Bin .../textures/moreblocks_sweeper.png | Bin mods/moreblocks/textures/moreblocks_tar.png | Bin .../textures/moreblocks_trap_glass.png | Bin .../textures/moreblocks_trap_glow_glass.png | Bin .../textures/moreblocks_trap_stone.png | Bin .../moreblocks_trap_super_glow_glass.png | Bin .../textures/moreblocks_tree_stairsplus.png | Bin .../textures/moreblocks_wood_tile.png | Bin .../textures/moreblocks_wood_tile_center.png | Bin .../textures/moreblocks_wood_tile_full.png | Bin .../textures/moreblocks_wood_tile_up.png | Bin 88 files changed, 915 insertions(+), 82 deletions(-) rename mods/moreblocks/{LICENSE.txt => LICENSE.md} (71%) mode change 100755 => 100644 create mode 100644 mods/moreblocks/README.md delete mode 100755 mods/moreblocks/README.txt mode change 100755 => 100644 mods/moreblocks/aliases.lua mode change 100755 => 100644 mods/moreblocks/circular_saw.lua mode change 100755 => 100644 mods/moreblocks/config.lua mode change 100755 => 100644 mods/moreblocks/crafting.lua mode change 100755 => 100644 mods/moreblocks/depends.txt mode change 100755 => 100644 mods/moreblocks/init.lua mode change 100755 => 100644 mods/moreblocks/locale/de.txt mode change 100755 => 100644 mods/moreblocks/locale/es.txt mode change 100755 => 100644 mods/moreblocks/locale/fr.txt mode change 100755 => 100644 mods/moreblocks/locale/template.txt create mode 100644 mods/moreblocks/models/moreblocks_slope.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_half.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_half_raised.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_inner.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_inner_half.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_outer.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_outer_cut.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_outer_half.obj create mode 100644 mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj mode change 100755 => 100644 mods/moreblocks/nodes.lua mode change 100755 => 100644 mods/moreblocks/ownership.lua mode change 100755 => 100644 mods/moreblocks/redefinitions.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/API.md mode change 100755 => 100644 mods/moreblocks/stairsplus/aliases.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/conversion.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/init.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/microblocks.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/panels.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/registrations.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/slabs.lua create mode 100644 mods/moreblocks/stairsplus/slopes.lua mode change 100755 => 100644 mods/moreblocks/stairsplus/stairs.lua mode change 100755 => 100644 mods/moreblocks/textures/default_brick.png mode change 100755 => 100644 mods/moreblocks/textures/default_fence_overlay.png mode change 100755 => 100644 mods/moreblocks/textures/invisible.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_cactus_brick.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_cactus_checker.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_circle_stone_bricks.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_circular_saw_bottom.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_circular_saw_side.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_circular_saw_top.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_clean_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_coal_checker.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_coal_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_coal_glass_stairsplus.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_coal_stone.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_coal_stone_bricks.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_empty_bookshelf.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_fence_jungle_wood.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_fence_wood.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_glass_stairsplus.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_glow_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_glow_glass_stairsplus.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_grey_bricks.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_iron_checker.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_iron_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_iron_glass_stairsplus.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_iron_stone.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_iron_stone_bricks.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_junglestick.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_obsidian_glass_stairsplus.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_plankstone.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_plankstone_2.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_rope.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_split_stone_tile.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_split_stone_tile_alt.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_split_stone_tile_top.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_stone_tile.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_super_glow_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_super_glow_glass_stairsplus.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_sweeper.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_tar.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_trap_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_trap_glow_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_trap_stone.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_trap_super_glow_glass.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_tree_stairsplus.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_wood_tile.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_wood_tile_center.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_wood_tile_full.png mode change 100755 => 100644 mods/moreblocks/textures/moreblocks_wood_tile_up.png diff --git a/mods/moreblocks/LICENSE.txt b/mods/moreblocks/LICENSE.md old mode 100755 new mode 100644 similarity index 71% rename from mods/moreblocks/LICENSE.txt rename to mods/moreblocks/LICENSE.md index 726257de..45c5ff5a --- a/mods/moreblocks/LICENSE.txt +++ b/mods/moreblocks/LICENSE.md @@ -1,8 +1,9 @@ -+---- zlib/libpng license ----+ +zlib license +============ -Copyright (c) 2013-2014 Calinou and contributors +Copyright (c) 2011-2015 Calinou and contributors -This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. +**This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.** Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: diff --git a/mods/moreblocks/README.md b/mods/moreblocks/README.md new file mode 100644 index 00000000..228ce97d --- /dev/null +++ b/mods/moreblocks/README.md @@ -0,0 +1,11 @@ +More Blocks +=========== + +More Blocks for Minetest , a free/libre infinite +world block sandbox game. + +To install, just clone this repository into your "mods" directory. + +More Blocks code is licensed under the zlib license, textures are by Calinou and are licensed under CC BY-SA 3.0 Unported. + +**Forum topic:** diff --git a/mods/moreblocks/README.txt b/mods/moreblocks/README.txt deleted file mode 100755 index aa99eda3..00000000 --- a/mods/moreblocks/README.txt +++ /dev/null @@ -1,12 +0,0 @@ -More Blocks -========== - -More Blocks for Minetest (http://minetest.net), a free and open source infinite -world block sandbox game. - -To install, just clone this repository into your "mods" directory. - -More Blocks code is under the zlib license, textures are under CC BY-SA 3.0 unported. - -Forum topic: http://forum.minetest.net/viewtopic.php?id=509 - diff --git a/mods/moreblocks/aliases.lua b/mods/moreblocks/aliases.lua old mode 100755 new mode 100644 index df820c33..15f7b6b2 --- a/mods/moreblocks/aliases.lua +++ b/mods/moreblocks/aliases.lua @@ -1,24 +1,28 @@ --- More Blocks aliases +--[[ +More Blocks: alias definitions +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +-- More Blocks aliases: minetest.register_alias("sweeper", "moreblocks:sweeper") minetest.register_alias("circular_saw", "moreblocks:circular_saw") minetest.register_alias("jungle_stick", "moreblocks:jungle_stick") --- Old block/item replacement - +-- Old block/item replacement: minetest.register_alias("moreblocks:oerkkiblock", "default:mossycobble") minetest.register_alias("moreblocks:screwdriver", "screwdriver:screwdriver") --- Node and item renaming - +-- Node and item renaming: minetest.register_alias("moreblocks:stone_bricks", "default:stonebrick") minetest.register_alias("moreblocks:stonebrick", "default:stonebrick") minetest.register_alias("moreblocks:junglewood", "default:junglewood") minetest.register_alias("moreblocks:jungle_wood", "default:junglewood") for _, t in pairs(circular_saw.names) do - minetest.register_alias("moreblocks:" ..t[1].. "_jungle_wood" ..t[2], - "moreblocks:" ..t[1].. "_junglewood" ..t[2]) + minetest.register_alias("moreblocks:" .. t[1] .. "_jungle_wood" .. t[2], + "moreblocks:" .. t[1] .. "_junglewood" .. t[2]) end minetest.register_alias("moreblocks:horizontaltree", "moreblocks:horizontal_tree") minetest.register_alias("moreblocks:horizontaljungletree", "moreblocks:horizontal_jungle_tree") @@ -51,8 +55,7 @@ minetest.register_alias("moreblocks:junglestick", "moreblocks:jungle_stick") minetest.register_alias("moreblocks:splitstonesquare","moreblocks:split_stone_tile") minetest.register_alias("moreblocks:allfacestree","moreblocks:all_faces_tree") --- ABM for horizontal trees (fix facedir). - +-- ABM for horizontal trees (fix facedir): local horizontal_tree_convert_facedir = {7, 12, 9, 18} minetest.register_abm({ diff --git a/mods/moreblocks/circular_saw.lua b/mods/moreblocks/circular_saw.lua old mode 100755 new mode 100644 index 2af5972a..98ddecbc --- a/mods/moreblocks/circular_saw.lua +++ b/mods/moreblocks/circular_saw.lua @@ -1,4 +1,12 @@ -local S = moreblocks.gettext +--[[ +More Blocks: circular saw + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = moreblocks.intllib + circular_saw = {} circular_saw.known_stairs = setmetatable({}, { diff --git a/mods/moreblocks/config.lua b/mods/moreblocks/config.lua old mode 100755 new mode 100644 index e5db0861..d646dacd --- a/mods/moreblocks/config.lua +++ b/mods/moreblocks/config.lua @@ -1,3 +1,10 @@ +--[[ +More Blocks: configuration handling + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + moreblocks.config = {} local function getbool_default(setting, default) diff --git a/mods/moreblocks/crafting.lua b/mods/moreblocks/crafting.lua old mode 100755 new mode 100644 index 158d40a5..4429d9ae --- a/mods/moreblocks/crafting.lua +++ b/mods/moreblocks/crafting.lua @@ -1,4 +1,9 @@ --- Crafting +--[[ +More Blocks: crafting recipes + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] minetest.register_craft({ output = "default:stick", diff --git a/mods/moreblocks/depends.txt b/mods/moreblocks/depends.txt old mode 100755 new mode 100644 index 9207dab8..198fe8a6 --- a/mods/moreblocks/depends.txt +++ b/mods/moreblocks/depends.txt @@ -1,2 +1,2 @@ -default -intllib? +default +intllib? diff --git a/mods/moreblocks/init.lua b/mods/moreblocks/init.lua old mode 100755 new mode 100644 index a86a38ea..2919a308 --- a/mods/moreblocks/init.lua +++ b/mods/moreblocks/init.lua @@ -1,20 +1,22 @@ --[[ --- More Blocks (moreblocks) by Calinou --- Licensed under the zlib/ license for code and CC BY-SA 3.0 for textures, see LICENSE.txt for info. +===================================================================== +** More Blocks ** +By Calinou, with the help of ShadowNinja and VanessaE. + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +===================================================================== --]] moreblocks = {} --- Load translation library if intllib is installed - -local S -- Load translation library if intllib is installed: -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) +local S +if minetest.get_modpath("intllib") then + S = intllib.Getter() else S = function(s) return s end end -moreblocks.gettext = S +moreblocks.intllib = S local modpath = minetest.get_modpath("moreblocks") @@ -27,6 +29,5 @@ dofile(modpath .. "/crafting.lua") dofile(modpath .. "/aliases.lua") if minetest.setting_getbool("log_mods") then - print(S("[moreblocks] loaded.")) + minetest.log("action", S("[moreblocks] loaded.")) end - diff --git a/mods/moreblocks/locale/de.txt b/mods/moreblocks/locale/de.txt old mode 100755 new mode 100644 diff --git a/mods/moreblocks/locale/es.txt b/mods/moreblocks/locale/es.txt old mode 100755 new mode 100644 diff --git a/mods/moreblocks/locale/fr.txt b/mods/moreblocks/locale/fr.txt old mode 100755 new mode 100644 diff --git a/mods/moreblocks/locale/template.txt b/mods/moreblocks/locale/template.txt old mode 100755 new mode 100644 diff --git a/mods/moreblocks/models/moreblocks_slope.obj b/mods/moreblocks/models/moreblocks_slope.obj new file mode 100644 index 00000000..05c853b7 --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope.obj @@ -0,0 +1,21 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_slope_onetexture.blend' +# www.blender.org +mtllib slope_test_slope_onetexture.mtl +o Cube_Cube.002 +v 0.500000 0.500000 0.500000 +v -0.500000 0.500000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v -0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 -0.500000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +usemtl None +s off +f 1/1 2/2 3/3 4/4 +f 4/3 3/4 5/1 6/2 +f 2/1 5/3 3/4 +f 1/2 4/3 6/4 +f 2/1 1/2 6/3 5/4 diff --git a/mods/moreblocks/models/moreblocks_slope_half.obj b/mods/moreblocks/models/moreblocks_slope_half.obj new file mode 100644 index 00000000..bc96bb8b --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_half.obj @@ -0,0 +1,23 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_slope_long_fronthalf_onetexture.blend' +# www.blender.org +mtllib slope_test_slope_long_fronthalf_onetexture.mtl +o Cube_Cube.002 +v 0.500000 -0.000000 0.500000 +v -0.500000 -0.000000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v -0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 -0.500000 +vt 1.000000 0.500000 +vt 0.000000 0.500000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +usemtl None +s off +f 1/1 2/2 3/3 4/4 +f 4/3 3/4 5/5 6/6 +f 2/1 5/3 3/4 +f 1/2 4/3 6/4 +f 2/5 1/6 6/3 5/4 diff --git a/mods/moreblocks/models/moreblocks_slope_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_half_raised.obj new file mode 100644 index 00000000..79e0dc01 --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_half_raised.obj @@ -0,0 +1,26 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_slope_long_backhalf_onetexture.blend' +# www.blender.org +mtllib slope_test_slope_long_backhalf_onetexture.mtl +o Cube +v -0.500000 -0.500000 0.500000 +v -0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 0.500000 +v -0.500000 0.500000 0.500000 +v -0.500000 0.000000 -0.500000 +v 0.500000 0.000000 -0.500000 +v 0.500000 0.500000 0.500000 +vt 1.000000 1.000000 +vt 0.000000 0.500000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 1.000000 0.500000 +vt 0.000000 1.000000 +usemtl None +s off +f 5/1 6/2 2/3 1/4 +f 6/5 7/2 3/3 2/4 +f 7/5 8/6 4/3 3/4 +f 8/1 5/6 1/3 4/4 +f 1/4 2/1 3/6 4/3 +f 8/6 7/3 6/4 5/1 diff --git a/mods/moreblocks/models/moreblocks_slope_inner.obj b/mods/moreblocks/models/moreblocks_slope_inner.obj new file mode 100644 index 00000000..68fc1700 --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_inner.obj @@ -0,0 +1,26 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_icorner_onetexture.blend' +# www.blender.org +o Cube_Cube.000 +v 0.500000 0.500000 0.500000 +v -0.500000 0.500000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v -0.500000 -0.500000 -0.500000 +v 0.500000 0.500000 -0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 -0.500000 +v -0.500000 -0.500000 -0.500000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +s off +f 6/1 1/2 7/3 8/4 +f 2/1 5/3 3/4 +f 2/1 1/2 5/4 +f 6/2 8/3 9/4 +f 9/1 8/2 7/3 3/4 +f 3/3 7/4 1/1 2/2 +f 1/1 6/2 9/3 +l 1 4 +l 3 4 diff --git a/mods/moreblocks/models/moreblocks_slope_inner_half.obj b/mods/moreblocks/models/moreblocks_slope_inner_half.obj new file mode 100644 index 00000000..6decaea3 --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_inner_half.obj @@ -0,0 +1,28 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_icorner_half_short_onetexture.blend' +# www.blender.org +mtllib slope_test_icorner_half_short_onetexture.mtl +o Cube_Cube.000 +v 0.500000 -0.000000 0.500000 +v -0.500000 -0.000000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v -0.500000 -0.500000 -0.500000 +v 0.500000 -0.000000 -0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 -0.500000 +v -0.500000 -0.500000 -0.500000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +usemtl None +s off +f 6/1 1/2 7/3 8/4 +f 2/1 5/3 3/4 +f 2/1 1/2 5/4 +f 6/2 8/3 9/4 +f 9/1 8/2 7/3 3/4 +f 3/3 7/4 1/1 2/2 +f 1/1 6/2 9/3 +l 1 4 +l 3 4 diff --git a/mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj new file mode 100644 index 00000000..8aff6cab --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj @@ -0,0 +1,31 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_icorner_half_tall_onetexture.blend' +# www.blender.org +mtllib slope_test_icorner_half_tall_onetexture.mtl +o Cube_Cube.000 +v 0.500000 0.500000 0.500000 +v -0.500000 0.500000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v -0.500000 0.000000 -0.500000 +v 0.500000 0.500000 -0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 -0.500000 +v -0.500000 0.000000 -0.500000 +v -0.500000 -0.500000 -0.500000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 1.000000 0.500000 +vt 0.000000 0.500000 +usemtl None +s off +f 6/1 1/2 7/3 8/4 +f 2/1 1/2 5/4 +f 3/3 7/4 1/1 2/2 +f 1/2 6/3 9/4 +f 3/1 10/2 8/3 7/4 +f 8/3 10/4 5/5 6/2 +f 3/4 2/1 5/6 10/3 +l 1 4 +l 3 4 diff --git a/mods/moreblocks/models/moreblocks_slope_outer.obj b/mods/moreblocks/models/moreblocks_slope_outer.obj new file mode 100644 index 00000000..383c195f --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_outer.obj @@ -0,0 +1,18 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_ocorner_onetexture.blend' +# www.blender.org +o Cube_Cube.002 +v 0.500000 0.500000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v -0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 -0.500000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +s off +f 3/1 2/2 4/3 5/4 +f 1/2 3/3 5/4 +f 1/1 2/3 3/4 +f 1/1 4/3 2/4 +f 1/2 5/3 4/4 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_cut.obj b/mods/moreblocks/models/moreblocks_slope_outer_cut.obj new file mode 100644 index 00000000..4608c69c --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_outer_cut.obj @@ -0,0 +1,19 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_tall_2_onetexture.blend' +# www.blender.org +mtllib slope_test_corner_pyramid_tall_2_onetexture.mtl +o Cube +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 0.500000 0.500000 +vt 1.000000 1.000000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 0.000000 1.000000 +vt 0.500000 1.000000 +usemtl None +s off +f 4/1 1/2 3/3 +f 2/3 4/4 3/2 +f 3/2 1/3 2/4 +f 1/3 4/5 2/2 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj b/mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj new file mode 100644 index 00000000..e4be8825 --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj @@ -0,0 +1,20 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_short_2_onetexture.blend' +# www.blender.org +mtllib slope_test_corner_pyramid_short_2_onetexture.mtl +o Cube +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 0.000000 0.500000 +vt 1.000000 0.500000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 0.000000 0.500000 +vt 0.000000 1.000000 +vt 0.500000 1.000000 +usemtl None +s off +f 4/1 1/2 3/3 +f 2/3 4/4 3/2 +f 3/2 1/3 2/5 +f 1/3 4/6 2/2 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj new file mode 100644 index 00000000..65a3b8ac --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj @@ -0,0 +1,23 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_short_3_onetexture.blend' +# www.blender.org +mtllib slope_test_corner_pyramid_short_3_onetexture.mtl +o Cube_Cube.002 +v -0.500000 -0.000000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 0.500000 0.500000 +v 0.500000 -0.500000 -0.500000 +v 0.500000 -0.000000 -0.500000 +vt 0.000000 0.500000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 1.000000 0.500000 +usemtl None +s off +f 1/1 2/2 3/3 4/4 +f 4/5 3/2 5/3 6/6 +f 2/5 5/3 3/4 +f 1/2 4/3 6/4 +f 2/3 1/6 6/1 5/2 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_half.obj b/mods/moreblocks/models/moreblocks_slope_outer_half.obj new file mode 100644 index 00000000..0c56e26a --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_outer_half.obj @@ -0,0 +1,22 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_short_1_onetexture.blend' +# www.blender.org +mtllib slope_test_corner_pyramid_short_1_onetexture.mtl +o Cube +v -0.500000 -0.500000 0.500000 +v -0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 -0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 0.000000 0.500000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 1.000000 0.500000 +vt 0.000000 0.500000 +usemtl None +s off +f 1/1 2/2 3/3 4/4 +f 5/5 1/3 4/4 +f 3/4 5/6 4/3 +f 2/4 5/2 3/3 +f 1/4 5/1 2/3 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj new file mode 100644 index 00000000..e4fa3d1f --- /dev/null +++ b/mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj @@ -0,0 +1,27 @@ +# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_tall_3_onetexture.blend' +# www.blender.org +mtllib slope_test_corner_pyramid_tall_3_onetexture.mtl +o Cube_Cube.002 +v -0.500000 -0.000000 0.500000 +v -0.500000 -0.500000 0.500000 +v 0.500000 -0.500000 0.500000 +v 0.500000 0.500000 0.500000 +v 0.500000 -0.500000 -0.500000 +v 0.500000 -0.000000 -0.500000 +v -0.500000 -0.500000 -0.500000 +v -0.500000 -0.000000 -0.500000 +vt 0.000000 0.500000 +vt 0.000000 0.000000 +vt 1.000000 0.000000 +vt 1.000000 1.000000 +vt 0.000000 1.000000 +vt 1.000000 0.500000 +usemtl None +s off +f 1/1 2/2 3/3 4/4 +f 4/5 3/2 5/3 6/6 +f 8/3 4/5 6/2 +f 1/6 8/1 7/2 2/3 +f 4/5 8/3 1/4 +f 6/1 5/2 7/3 8/6 +f 5/5 3/2 2/3 7/4 diff --git a/mods/moreblocks/nodes.lua b/mods/moreblocks/nodes.lua old mode 100755 new mode 100644 index 5efda8f8..d3120c9a --- a/mods/moreblocks/nodes.lua +++ b/mods/moreblocks/nodes.lua @@ -1,4 +1,11 @@ -local S = moreblocks.gettext +--[[ +More Blocks: node definitions + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = moreblocks.intllib local sound_wood = default.node_sound_wood_defaults() local sound_stone = default.node_sound_stone_defaults() @@ -116,6 +123,11 @@ local nodes = { groups = {cracky = 2}, sounds = sound_stone, }, + ["cobble_compressed"] = { + description = S("Compressed Cobblestone"), + groups = {cracky = 1}, + sounds = sound_stone, + }, ["plankstone"] = { description = S("Plankstone"), groups = {cracky = 3}, diff --git a/mods/moreblocks/ownership.lua b/mods/moreblocks/ownership.lua old mode 100755 new mode 100644 index 9cd4cb30..1c2431ba --- a/mods/moreblocks/ownership.lua +++ b/mods/moreblocks/ownership.lua @@ -1,3 +1,9 @@ +--[[ +More Blocks: ownership handling + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] local S = moreblocks.gettext diff --git a/mods/moreblocks/redefinitions.lua b/mods/moreblocks/redefinitions.lua old mode 100755 new mode 100644 index 4db169b1..a6498f16 --- a/mods/moreblocks/redefinitions.lua +++ b/mods/moreblocks/redefinitions.lua @@ -1,3 +1,10 @@ +--[[ +More Blocks: redefinitions of default stuff + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + -- Redefinitions of some default crafting recipes: minetest.register_craft({ @@ -71,6 +78,11 @@ minetest.override_item("default:papyrus", { sunlight_propagates = true, }) +minetest.override_item("default:fence_wood", { + paramtype = "light", + sunlight_propagates = true, +}) + minetest.override_item("default:junglegrass", { paramtype = "light", sunlight_propagates = true, diff --git a/mods/moreblocks/stairsplus/API.md b/mods/moreblocks/stairsplus/API.md old mode 100755 new mode 100644 index a98ec81e..2db0f2b3 --- a/mods/moreblocks/stairsplus/API.md +++ b/mods/moreblocks/stairsplus/API.md @@ -1,6 +1,5 @@ API documentation for Stairs+ -================================ -- - - - - - - - - - - - - - - - +============================= * `stairsplus:register_all(modname, subname, recipeitem, fields)` Registers a stair, slab, panel, microblock, and any other types of diff --git a/mods/moreblocks/stairsplus/aliases.lua b/mods/moreblocks/stairsplus/aliases.lua old mode 100755 new mode 100644 index c92df483..c235d342 --- a/mods/moreblocks/stairsplus/aliases.lua +++ b/mods/moreblocks/stairsplus/aliases.lua @@ -1,3 +1,9 @@ +--[[ +More Blocks: alias definitions + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] local function register_stairsplus_alias(modname, origname, newname) minetest.register_alias(modname.. ":slab_" ..origname, "moreblocks:slab_" ..newname) @@ -33,12 +39,14 @@ end register_stairsplus_alias("stairsplus", "stone", "stone") register_stairsplus_alias("stairsplus", "wood", "wood") +register_stairsplus_alias("stairsplus", "pinewood", "pinewood") register_stairsplus_alias("stairsplus", "cobble", "cobble") register_stairsplus_alias("stairsplus", "brick", "brick") register_stairsplus_alias("stairsplus", "sandstone", "sandstone") register_stairsplus_alias("stairsplus", "glass", "glass") register_stairsplus_alias("stairsplus", "tree", "tree") register_stairsplus_alias("stairsplus", "jungletree", "jungletree") +register_stairsplus_alias("stairsplus", "pinetree", "pinetree") register_stairsplus_alias("stairsplus", "desert_stone", "desert_stone") register_stairsplus_alias("stairsplus", "steelblock", "steelblock") register_stairsplus_alias("stairsplus", "mossycobble", "mossycobble") diff --git a/mods/moreblocks/stairsplus/conversion.lua b/mods/moreblocks/stairsplus/conversion.lua old mode 100755 new mode 100644 index fda30c7b..13966b66 --- a/mods/moreblocks/stairsplus/conversion.lua +++ b/mods/moreblocks/stairsplus/conversion.lua @@ -1,3 +1,10 @@ +--[[ +More Blocks: conversion + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + -- Function to convert all stairs/slabs/etc nodes from -- inverted, wall, etc to regular + 6d facedir diff --git a/mods/moreblocks/stairsplus/init.lua b/mods/moreblocks/stairsplus/init.lua old mode 100755 new mode 100644 index ae09b7d3..ffec1b7f --- a/mods/moreblocks/stairsplus/init.lua +++ b/mods/moreblocks/stairsplus/init.lua @@ -1,3 +1,10 @@ +--[[ +More Blocks: Stairs+ + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + -- Nodes will be called :{stair,slab,panel,micro}_ local modpath = minetest.get_modpath("moreblocks").. "/stairsplus" @@ -18,6 +25,7 @@ function stairsplus:register_all(modname, subname, recipeitem, fields) end self:register_stair(modname, subname, recipeitem, fields) self:register_slab (modname, subname, recipeitem, fields) + self:register_slope(modname, subname, recipeitem, fields) self:register_panel(modname, subname, recipeitem, fields) self:register_micro(modname, subname, recipeitem, fields) -- self:register_6dfacedir_conversion(modname, subname) -- Not needed as of Q3 2013, uncomment to fix old maps. @@ -36,8 +44,9 @@ end -- dofile(modpath.. "/aliases.lua") -- Not needed as of Q2 2013, uncomment to fix old maps. -- dofile(modpath.. "/conversion.lua") -- Not needed as of Q2 2013, uncomment to fix old maps. -dofile(modpath.. "/stairs.lua") -dofile(modpath.. "/slabs.lua") -dofile(modpath.. "/panels.lua") -dofile(modpath.. "/microblocks.lua") -dofile(modpath.. "/registrations.lua") +dofile(modpath .. "/stairs.lua") +dofile(modpath .. "/slabs.lua") +dofile(modpath .. "/slopes.lua") +dofile(modpath .. "/panels.lua") +dofile(modpath .. "/microblocks.lua") +dofile(modpath .. "/registrations.lua") diff --git a/mods/moreblocks/stairsplus/microblocks.lua b/mods/moreblocks/stairsplus/microblocks.lua old mode 100755 new mode 100644 index f88ed12e..8d52c4a2 --- a/mods/moreblocks/stairsplus/microblocks.lua +++ b/mods/moreblocks/stairsplus/microblocks.lua @@ -1,10 +1,11 @@ -local S -- Load translation library if intllib is installed: -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) -else - S = function(s) return s end -end +--[[ +More Blocks: microblock definitions + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = moreblocks.intllib -- Node will be called :micro_ diff --git a/mods/moreblocks/stairsplus/panels.lua b/mods/moreblocks/stairsplus/panels.lua old mode 100755 new mode 100644 index 73b283ed..2220fe42 --- a/mods/moreblocks/stairsplus/panels.lua +++ b/mods/moreblocks/stairsplus/panels.lua @@ -1,10 +1,11 @@ -local S -- Load translation library if intllib is installed: -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) -else - S = function(s) return s end -end +--[[ +More Blocks: panel definitions + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = moreblocks.intllib -- Node will be called :panel_ diff --git a/mods/moreblocks/stairsplus/registrations.lua b/mods/moreblocks/stairsplus/registrations.lua old mode 100755 new mode 100644 index cc22d333..7b38b13b --- a/mods/moreblocks/stairsplus/registrations.lua +++ b/mods/moreblocks/stairsplus/registrations.lua @@ -1,3 +1,10 @@ +--[[ +More Blocks: registrations + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + local default_nodes = { -- Default stairs/slabs/panels/microblocks: "stone", "cobble", @@ -10,12 +17,14 @@ local default_nodes = { -- Default stairs/slabs/panels/microblocks: "bronzeblock", "diamondblock", "desert_stone", --- "desert_cobble", + "desert_cobble", "glass", "tree", "wood", "jungletree", "junglewood", + "pinetree", + "pinewood", "obsidian", "obsidian_glass", "stonebrick", diff --git a/mods/moreblocks/stairsplus/slabs.lua b/mods/moreblocks/stairsplus/slabs.lua old mode 100755 new mode 100644 index 9c31745d..68ba5200 --- a/mods/moreblocks/stairsplus/slabs.lua +++ b/mods/moreblocks/stairsplus/slabs.lua @@ -1,10 +1,11 @@ -local S -- Load translation library if intllib is installed: -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) -else - S = function(s) return s end -end +--[[ +More Blocks: slab definitions + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = moreblocks.intllib -- Node will be called :slab_ @@ -75,11 +76,11 @@ function stairsplus:register_slab(modname, subname, recipeitem, fields) end def.description = desc if fields.drop then - def.drop = modname.. ":slab_" ..fields.drop..alternate + def.drop = modname.. ":slab_" .. fields.drop .. alternate end - minetest.register_node(":" ..modname.. ":slab_" ..subname..alternate, def) + minetest.register_node(":" .. modname .. ":slab_" .. subname .. alternate, def) end - minetest.register_alias("stairs:slab_" ..subname, modname.. ":slab_" ..subname) + minetest.register_alias("stairs:slab_" .. subname, modname .. ":slab_" .. subname) -- Some saw-less recipes: diff --git a/mods/moreblocks/stairsplus/slopes.lua b/mods/moreblocks/stairsplus/slopes.lua new file mode 100644 index 00000000..3a169060 --- /dev/null +++ b/mods/moreblocks/stairsplus/slopes.lua @@ -0,0 +1,459 @@ +--[[ +More Blocks: slope definitions + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = moreblocks.intllib + +local box_slope = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, -0.25, 0.5}, + {-0.5, -0.25, -0.25, 0.5, 0, 0.5}, + {-0.5, 0, 0, 0.5, 0.25, 0.5}, + {-0.5, 0.25, 0.25, 0.5, 0.5, 0.5} + } +} + +local box_slope_half = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, + {-0.5, -0.375, -0.25, 0.5, -0.25, 0.5}, + {-0.5, -0.25, 0, 0.5, -0.125, 0.5}, + {-0.5, -0.125, 0.25, 0.5, 0, 0.5}, + } +} + +local box_slope_half_raised = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, 0.125, 0.5}, + {-0.5, 0.125, -0.25, 0.5, 0.25, 0.5}, + {-0.5, 0.25, 0, 0.5, 0.375, 0.5}, + {-0.5, 0.375, 0.25, 0.5, 0.5, 0.5}, + } +} + +--============================================================== + +local box_slope_inner = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, -0.25, 0.5}, + {-0.5, -0.5, -0.25, 0.5, 0, 0.5}, + {-0.5, -0.5, -0.5, 0.25, 0, 0.5}, + {-0.5, 0, -0.5, 0, 0.25, 0.5}, + {-0.5, 0, 0, 0.5, 0.25, 0.5}, + {-0.5, 0.25, 0.25, 0.5, 0.5, 0.5}, + {-0.5, 0.25, -0.5, -0.25, 0.5, 0.5}, + } +} + +local box_slope_inner_half = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, + {-0.5, -0.375, -0.25, 0.5, -0.25, 0.5}, + {-0.5, -0.375, -0.5, 0.25, -0.25, 0.5}, + {-0.5, -0.25, -0.5, 0, -0.125, 0.5}, + {-0.5, -0.25, 0, 0.5, -0.125, 0.5}, + {-0.5, -0.125, 0.25, 0.5, 0, 0.5}, + {-0.5, -0.125, -0.5, -0.25, 0, 0.5}, + } +} + +local box_slope_inner_half_raised = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, 0.125, 0.5}, + {-0.5, 0.125, -0.25, 0.5, 0.25, 0.5}, + {-0.5, 0.125, -0.5, 0.25, 0.25, 0.5}, + {-0.5, 0.25, -0.5, 0, 0.375, 0.5}, + {-0.5, 0.25, 0, 0.5, 0.375, 0.5}, + {-0.5, 0.375, 0.25, 0.5, 0.5, 0.5}, + {-0.5, 0.375, -0.5, -0.25, 0.5, 0.5}, + } +} + +--============================================================== + +local box_slope_outer = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, -0.25, 0.5}, + {-0.5, -0.25, -0.25, 0.25, 0, 0.5}, + {-0.5, 0, 0, 0, 0.25, 0.5}, + {-0.5, 0.25, 0.25, -0.25, 0.5, 0.5} + } +} + +local box_slope_outer_half = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, + {-0.5, -0.375, -0.25, 0.25, -0.25, 0.5}, + {-0.5, -0.25, 0, 0, -0.125, 0.5}, + {-0.5, -0.125, 0.25, -0.25, 0, 0.5} + } +} + +local box_slope_outer_half_raised = { + type = "fixed", + fixed = { + {-0.5, -0.5, -0.5, 0.5, 0.125, 0.5}, + {-0.5, 0.125, -0.25, 0.25, 0.25, 0.5}, + {-0.5, 0.25, 0, 0, 0.375, 0.5}, + {-0.5, 0.375, 0.25, -0.25, 0.5, 0.5} + } +} + +-- Node will be called :slope_ + +function register_slope(modname, subname, recipeitem, groups, images, description, drop, light) + return stairsplus:register_slope(modname, subname, recipeitem, { + groups = groups, + tiles = images, + description = description, + drop = drop, + light_source = light, + sounds = default.node_sound_stone_defaults(), + }) +end + +function stairsplus:register_slope(modname, subname, recipeitem, fields) + local defs = { + [""] = { + mesh = "moreblocks_slope.obj", + collision_box = box_slope, + selection_box = box_slope, + + }, + ["_half"] = { + mesh = "moreblocks_slope_half.obj", + collision_box = box_slope_half, + selection_box = box_slope_half, + }, + ["_half_raised"] = { + mesh = "moreblocks_slope_half_raised.obj", + collision_box = box_slope_half_raised, + selection_box = box_slope_half_raised, + }, + +--============================================================== + + ["_inner"] = { + mesh = "moreblocks_slope_inner.obj", + collision_box = box_slope_inner, + selection_box = box_slope_inner, + }, + ["_inner_half"] = { + mesh = "moreblocks_slope_inner_half.obj", + collision_box = box_slope_inner_half, + selection_box = box_slope_inner_half, + }, + ["_inner_half_raised"] = { + mesh = "moreblocks_slope_inner_half_raised.obj", + collision_box = box_slope_inner_half_raised, + selection_box = box_slope_inner_half_raised, + }, + +--============================================================== + + ["_outer"] = { + mesh = "moreblocks_slope_outer.obj", + collision_box = box_slope_outer, + selection_box = box_slope_outer, + }, + ["_outer_half"] = { + mesh = "moreblocks_slope_outer_half.obj", + collision_box = box_slope_outer_half, + selection_box = box_slope_outer_half, + }, + ["_outer_half_raised"] = { + mesh = "moreblocks_slope_outer_half_raised.obj", + collision_box = box_slope_outer_half_raised, + selection_box = box_slope_outer_half_raised, + }, + +--============================================================== + + ["_outer_cut"] = { + mesh = "moreblocks_slope_outer_cut.obj", + collision_box = box_slope_outer, + selection_box = box_slope_outer, + }, + ["_outer_cut_half"] = { + mesh = "moreblocks_slope_outer_cut_half.obj", + collision_box = box_slope_outer_half, + selection_box = box_slope_outer_half, + }, + ["_outer_cut_half_raised"] = { + mesh = "moreblocks_slope_outer_cut_half_raised.obj", + collision_box = box_slope_outer_half_raised, + selection_box = box_slope_outer_half_raised, + }, + } + + local desc = S("%s Slope"):format(fields.description) + for alternate, def in pairs(defs) do + def.drawtype = "mesh" + def.paramtype = "light" + def.paramtype2 = "facedir" + def.on_place = minetest.rotate_node + for k, v in pairs(fields) do + def[k] = v + end + def.description = desc + if fields.drop then + def.drop = modname.. ":slope_" ..fields.drop..alternate + end + minetest.register_node(":" ..modname.. ":slope_" ..subname..alternate, def) + end + + -- Some saw-less recipes: + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. " 7", + recipe = { + {modname .. ":panel_" .. subname, "", ""}, + {recipeitem, modname .. ":panel_" .. subname, ""}, + {recipeitem, recipeitem, modname .. ":panel_" .. subname}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. " 7", + recipe = { + {"", "", modname .. ":panel_" .. subname}, + {"", modname .. ":panel_" .. subname, recipeitem}, + {modname .. ":panel_" .. subname, recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_half 10", + recipe = { + {modname .. ":panel_" .. subname, "", ""}, + {recipeitem, recipeitem, modname .. ":panel_" .. subname}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_half 10", + recipe = { + {"", "", modname .. ":panel_" .. subname}, + {modname .. ":panel_" .. subname, recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_half_raised 7", + recipe = { + {modname .. ":panel_" .. subname, "", ""}, + {recipeitem, recipeitem, modname .. ":panel_" .. subname}, + {recipeitem, recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_half_raised 7", + recipe = { + {"", "", modname .. ":panel_" .. subname}, + {modname .. ":panel_" .. subname, recipeitem, recipeitem}, + {recipeitem, recipeitem, recipeitem}, + }, + }) + +--===================================================== Inner == + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_inner 7", + recipe = { + {modname .. ":stair_" .. subname .. "_half", "", ""}, + {recipeitem, modname .. ":stair_" .. subname .. "_half", ""}, + {recipeitem, recipeitem, modname .. ":stair_" .. subname .. "_half"}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_inner 7", + recipe = { + {"", "", modname .. ":stair_" .. subname .. "_half"}, + {"", modname .. ":stair_" .. subname .. "_half", recipeitem}, + {modname .. ":stair_" .. subname .. "_half", recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_inner_half 10", + recipe = { + {modname .. ":stair_" .. subname .. "_half", "", ""}, + {recipeitem, recipeitem, modname .. ":stair_" .. subname .. "_half"}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_inner_half 10", + recipe = { + {"", "", modname .. ":stair_" .. subname .. "_half"}, + {modname .. ":stair_" .. subname .. "_half", recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_inner_half_raised 7", + recipe = { + {modname .. ":stair_" .. subname .. "_half", "", ""}, + {recipeitem, recipeitem, modname .. ":stair_" .. subname .. "_half"}, + {recipeitem, recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_inner_half_raised 7", + recipe = { + {"", "", modname .. ":stair_" .. subname .. "_half"}, + {modname .. ":stair_" .. subname .. "_half", recipeitem, recipeitem}, + {recipeitem, recipeitem, recipeitem}, + }, + }) + +--===================================================== Outer == + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_outer 7", + recipe = { + {modname .. ":micro_" .. subname, "", ""}, + {recipeitem, modname .. ":micro_" .. subname, ""}, + {recipeitem, recipeitem, modname .. ":micro_" .. subname}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_outer 7", + recipe = { + {"", "", modname .. ":micro_" .. subname}, + {"", modname .. ":micro_" .. subname, recipeitem}, + {modname .. ":micro_" .. subname, recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_outer_half 10", + recipe = { + {modname .. ":micro_" .. subname, "", ""}, + {recipeitem, recipeitem, modname .. ":micro_" .. subname}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_outer_half 10", + recipe = { + {"", "", modname .. ":micro_" .. subname}, + {modname .. ":micro_" .. subname, recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_outer_half_raised 7", + recipe = { + {modname .. ":micro_" .. subname, "", ""}, + {recipeitem, recipeitem, modname .. ":micro_" .. subname}, + {recipeitem, recipeitem, recipeitem}, + }, + }) + + minetest.register_craft({ + output = modname .. ":slope_" .. subname .. "_outer_half_raised 7", + recipe = { + {"", "", modname .. ":micro_" .. subname}, + {modname .. ":micro_" .. subname, recipeitem, recipeitem}, + {recipeitem, recipeitem, recipeitem}, + }, + }) + +--================================================= Shapeless == + + minetest.register_craft({ + type = "shapeless", + output = recipeitem, + recipe = {modname .. ":slope_" .. subname, modname .. ":slope_" .. subname}, + }) + + minetest.register_craft({ + type = "shapeless", + output = recipeitem, + recipe = {modname .. ":slope_" .. subname .. "_outer_cut", modname .. ":slope_" .. subname .. "_outer_cut"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = recipeitem, + recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half_raised"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = recipeitem, + recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half", + modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slab_" .. subname, + recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_half_raised", + recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half", + modname .. ":slope_" .. subname .. "_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_half_raised", + recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_inner_half_raised", + recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_inner_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_outer_half_raised", + recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_outer_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_outer_cut_half_raised", + recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_outer_cut_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_outer_cut", + recipe = {modname .. ":slope_" .. subname .. "_outer"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_outer_cut_half", + recipe = {modname .. ":slope_" .. subname .. "_outer_half"}, + }) + + minetest.register_craft({ + type = "shapeless", + output = modname .. ":slope_" .. subname .. "_outer_cut_half_raised", + recipe = {modname .. ":slope_" .. subname .. "_outer_half_raised"}, + }) +end diff --git a/mods/moreblocks/stairsplus/stairs.lua b/mods/moreblocks/stairsplus/stairs.lua old mode 100755 new mode 100644 index a4f54e39..a93cda08 --- a/mods/moreblocks/stairsplus/stairs.lua +++ b/mods/moreblocks/stairsplus/stairs.lua @@ -1,10 +1,11 @@ -local S -- Load translation library if intllib is installed: -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) -else - S = function(s) return s end -end +--[[ +More Blocks: stair definitions + +Copyright (c) 2011-2015 Calinou and contributors. +Licensed under the zlib license. See LICENSE.md for more information. +--]] + +local S = moreblocks.intllib -- Node will be called :stair_ @@ -116,11 +117,11 @@ function stairsplus:register_stair(modname, subname, recipeitem, fields) end def.description = desc if fields.drop then - def.drop = modname.. ":stair_" ..fields.drop..alternate + def.drop = modname .. ":stair_" .. fields.drop .. alternate end - minetest.register_node(":" ..modname.. ":stair_" ..subname..alternate, def) + minetest.register_node(":" .. modname .. ":stair_" .. subname .. alternate, def) end - minetest.register_alias(":stairs:stair_" ..subname, modname.. ":stair_" ..subname) + minetest.register_alias("stairs:stair_" .. subname, modname .. ":stair_" .. subname) -- Some saw-less recipes: diff --git a/mods/moreblocks/textures/default_brick.png b/mods/moreblocks/textures/default_brick.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/default_fence_overlay.png b/mods/moreblocks/textures/default_fence_overlay.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/invisible.png b/mods/moreblocks/textures/invisible.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_cactus_brick.png b/mods/moreblocks/textures/moreblocks_cactus_brick.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_cactus_checker.png b/mods/moreblocks/textures/moreblocks_cactus_checker.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_circle_stone_bricks.png b/mods/moreblocks/textures/moreblocks_circle_stone_bricks.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_circular_saw_bottom.png b/mods/moreblocks/textures/moreblocks_circular_saw_bottom.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_circular_saw_side.png b/mods/moreblocks/textures/moreblocks_circular_saw_side.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_circular_saw_top.png b/mods/moreblocks/textures/moreblocks_circular_saw_top.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_clean_glass.png b/mods/moreblocks/textures/moreblocks_clean_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_coal_checker.png b/mods/moreblocks/textures/moreblocks_coal_checker.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_coal_glass.png b/mods/moreblocks/textures/moreblocks_coal_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_coal_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_coal_glass_stairsplus.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_coal_stone.png b/mods/moreblocks/textures/moreblocks_coal_stone.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_coal_stone_bricks.png b/mods/moreblocks/textures/moreblocks_coal_stone_bricks.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_empty_bookshelf.png b/mods/moreblocks/textures/moreblocks_empty_bookshelf.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_fence_jungle_wood.png b/mods/moreblocks/textures/moreblocks_fence_jungle_wood.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_fence_wood.png b/mods/moreblocks/textures/moreblocks_fence_wood.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_glass.png b/mods/moreblocks/textures/moreblocks_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_glass_stairsplus.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_glow_glass.png b/mods/moreblocks/textures/moreblocks_glow_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_glow_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_glow_glass_stairsplus.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_grey_bricks.png b/mods/moreblocks/textures/moreblocks_grey_bricks.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_iron_checker.png b/mods/moreblocks/textures/moreblocks_iron_checker.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_iron_glass.png b/mods/moreblocks/textures/moreblocks_iron_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_iron_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_iron_glass_stairsplus.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_iron_stone.png b/mods/moreblocks/textures/moreblocks_iron_stone.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_iron_stone_bricks.png b/mods/moreblocks/textures/moreblocks_iron_stone_bricks.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_junglestick.png b/mods/moreblocks/textures/moreblocks_junglestick.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_obsidian_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_obsidian_glass_stairsplus.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_plankstone.png b/mods/moreblocks/textures/moreblocks_plankstone.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_plankstone_2.png b/mods/moreblocks/textures/moreblocks_plankstone_2.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_rope.png b/mods/moreblocks/textures/moreblocks_rope.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_split_stone_tile.png b/mods/moreblocks/textures/moreblocks_split_stone_tile.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_split_stone_tile_alt.png b/mods/moreblocks/textures/moreblocks_split_stone_tile_alt.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_split_stone_tile_top.png b/mods/moreblocks/textures/moreblocks_split_stone_tile_top.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_stone_tile.png b/mods/moreblocks/textures/moreblocks_stone_tile.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_super_glow_glass.png b/mods/moreblocks/textures/moreblocks_super_glow_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_super_glow_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_super_glow_glass_stairsplus.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_sweeper.png b/mods/moreblocks/textures/moreblocks_sweeper.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_tar.png b/mods/moreblocks/textures/moreblocks_tar.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_trap_glass.png b/mods/moreblocks/textures/moreblocks_trap_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_trap_glow_glass.png b/mods/moreblocks/textures/moreblocks_trap_glow_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_trap_stone.png b/mods/moreblocks/textures/moreblocks_trap_stone.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_trap_super_glow_glass.png b/mods/moreblocks/textures/moreblocks_trap_super_glow_glass.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_tree_stairsplus.png b/mods/moreblocks/textures/moreblocks_tree_stairsplus.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile.png b/mods/moreblocks/textures/moreblocks_wood_tile.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile_center.png b/mods/moreblocks/textures/moreblocks_wood_tile_center.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile_full.png b/mods/moreblocks/textures/moreblocks_wood_tile_full.png old mode 100755 new mode 100644 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile_up.png b/mods/moreblocks/textures/moreblocks_wood_tile_up.png old mode 100755 new mode 100644 From d7eeffa5b18289017d04aa52d3f7b8ca9815c7a2 Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 19:57:57 +0100 Subject: [PATCH 10/15] Sent last global variables' patchs - There is, from now on, no more known global variables error in the repository! (not 100% guaranteed) --- mods/chesttools/init.lua | 2 +- mods/fences/init.lua | 3 ++- mods/snow/src/nodes.lua | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/mods/chesttools/init.lua b/mods/chesttools/init.lua index e2dcb6b2..fa219361 100755 --- a/mods/chesttools/init.lua +++ b/mods/chesttools/init.lua @@ -58,7 +58,7 @@ chesttools.may_use = function( pos, player ) local meta = minetest.get_meta( pos ); local owner = meta:get_string( 'owner' ) -- the owner can access the chest - if( onwer == name or owner == "" ) then + if( owner == name or owner == "" ) then return true; end -- the shared function only kicks in if the area is protected diff --git a/mods/fences/init.lua b/mods/fences/init.lua index 82c8da9e..8ab786c5 100755 --- a/mods/fences/init.lua +++ b/mods/fences/init.lua @@ -71,6 +71,7 @@ end local p0 = {-2/16, -1/2, -2/16, 2/16, 1/2, 2/16} local p1 = {-2/16, 1/2, -2/16, -2/16, 1/2+8/16, -2/16} local p2 = {-2/16, 1/2, 2/16, -2/16, 1/2+8/16, 2/16} +local p3 = {0, 0, 0, 0, 0, 0} local p4 = {2/16, 1/2, -2/16, 2/16, 1/2+8/16, -2/16} local p5 = {2/16, 1/2, 2/16, 2/16, 1/2+8/16, 2/16} @@ -532,7 +533,7 @@ minetest.register_node("fences:fence_wood_13", { --right(2)+top(11)=13 type = "fixed", fixed = { p0,p1,p2,p3,p4,p5, - z2,z22,x1,x12, + z2,z22,x1,x22, bz1,bz11,bx1,bx11, } }, diff --git a/mods/snow/src/nodes.lua b/mods/snow/src/nodes.lua index cd6d02f8..a6113c20 100755 --- a/mods/snow/src/nodes.lua +++ b/mods/snow/src/nodes.lua @@ -66,7 +66,7 @@ end --Christmas easter egg minetest.register_on_mapgen_init( function() - if skins then + if minetest.get_modpath("skins") ~= nil then skins.add("character_snow_man") end end From 9cc798c461686d371e9e89c66b6b205e205be30e Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 21:06:57 +0100 Subject: [PATCH 11/15] Reverted moreblocks and maptools updates --- mods/maptools/{LICENSE.md => LICENSE.txt} | 7 +- mods/maptools/NODES.md | 45 -- mods/maptools/README.md | 11 - mods/maptools/README.txt | 22 + mods/maptools/_README.txt | 53 ++ mods/maptools/aliases.lua | 9 +- mods/maptools/config.lua | 29 - mods/maptools/craftitems.lua | 47 -- mods/maptools/default_nodes.lua | 87 ++- mods/maptools/init.lua | 583 +++++++++++++++++- mods/maptools/nodes.lua | 429 ------------- .../textures/maptools_super_apple_bottom.png | Bin 0 -> 295 bytes .../textures/maptools_super_apple_side.png | Bin 0 -> 295 bytes .../textures/maptools_super_apple_top.png | Bin 0 -> 498 bytes mods/maptools/tools.lua | 61 -- mods/moreblocks/{LICENSE.md => LICENSE.txt} | 7 +- mods/moreblocks/README.md | 11 - mods/moreblocks/README.txt | 12 + mods/moreblocks/aliases.lua | 21 +- mods/moreblocks/circular_saw.lua | 10 +- mods/moreblocks/config.lua | 7 - mods/moreblocks/crafting.lua | 7 +- mods/moreblocks/depends.txt | 4 +- mods/moreblocks/init.lua | 23 +- mods/moreblocks/locale/de.txt | 0 mods/moreblocks/locale/es.txt | 0 mods/moreblocks/locale/fr.txt | 0 mods/moreblocks/locale/template.txt | 0 mods/moreblocks/models/moreblocks_slope.obj | 21 - .../models/moreblocks_slope_half.obj | 23 - .../models/moreblocks_slope_half_raised.obj | 26 - .../models/moreblocks_slope_inner.obj | 26 - .../models/moreblocks_slope_inner_half.obj | 28 - .../moreblocks_slope_inner_half_raised.obj | 31 - .../models/moreblocks_slope_outer.obj | 18 - .../models/moreblocks_slope_outer_cut.obj | 19 - .../moreblocks_slope_outer_cut_half.obj | 20 - ...moreblocks_slope_outer_cut_half_raised.obj | 23 - .../models/moreblocks_slope_outer_half.obj | 22 - .../moreblocks_slope_outer_half_raised.obj | 27 - mods/moreblocks/nodes.lua | 14 +- mods/moreblocks/ownership.lua | 6 - mods/moreblocks/redefinitions.lua | 12 - mods/moreblocks/stairsplus/API.md | 3 +- mods/moreblocks/stairsplus/aliases.lua | 8 - mods/moreblocks/stairsplus/conversion.lua | 7 - mods/moreblocks/stairsplus/init.lua | 19 +- mods/moreblocks/stairsplus/microblocks.lua | 15 +- mods/moreblocks/stairsplus/panels.lua | 15 +- mods/moreblocks/stairsplus/registrations.lua | 11 +- mods/moreblocks/stairsplus/slabs.lua | 21 +- mods/moreblocks/stairsplus/slopes.lua | 459 -------------- mods/moreblocks/stairsplus/stairs.lua | 21 +- mods/moreblocks/textures/default_brick.png | Bin .../textures/default_fence_overlay.png | Bin mods/moreblocks/textures/invisible.png | Bin .../textures/moreblocks_cactus_brick.png | Bin .../textures/moreblocks_cactus_checker.png | Bin .../moreblocks_circle_stone_bricks.png | Bin .../moreblocks_circular_saw_bottom.png | Bin .../textures/moreblocks_circular_saw_side.png | Bin .../textures/moreblocks_circular_saw_top.png | Bin .../textures/moreblocks_clean_glass.png | Bin .../textures/moreblocks_coal_checker.png | Bin .../textures/moreblocks_coal_glass.png | Bin .../moreblocks_coal_glass_stairsplus.png | Bin .../textures/moreblocks_coal_stone.png | Bin .../textures/moreblocks_coal_stone_bricks.png | Bin .../textures/moreblocks_empty_bookshelf.png | Bin .../textures/moreblocks_fence_jungle_wood.png | Bin .../textures/moreblocks_fence_wood.png | Bin mods/moreblocks/textures/moreblocks_glass.png | Bin .../textures/moreblocks_glass_stairsplus.png | Bin .../textures/moreblocks_glow_glass.png | Bin .../moreblocks_glow_glass_stairsplus.png | Bin .../textures/moreblocks_grey_bricks.png | Bin .../textures/moreblocks_iron_checker.png | Bin .../textures/moreblocks_iron_glass.png | Bin .../moreblocks_iron_glass_stairsplus.png | Bin .../textures/moreblocks_iron_stone.png | Bin .../textures/moreblocks_iron_stone_bricks.png | Bin .../textures/moreblocks_junglestick.png | Bin .../moreblocks_obsidian_glass_stairsplus.png | Bin .../textures/moreblocks_plankstone.png | Bin .../textures/moreblocks_plankstone_2.png | Bin mods/moreblocks/textures/moreblocks_rope.png | Bin .../textures/moreblocks_split_stone_tile.png | Bin .../moreblocks_split_stone_tile_alt.png | Bin .../moreblocks_split_stone_tile_top.png | Bin .../textures/moreblocks_stone_tile.png | Bin .../textures/moreblocks_super_glow_glass.png | Bin ...moreblocks_super_glow_glass_stairsplus.png | Bin .../textures/moreblocks_sweeper.png | Bin mods/moreblocks/textures/moreblocks_tar.png | Bin .../textures/moreblocks_trap_glass.png | Bin .../textures/moreblocks_trap_glow_glass.png | Bin .../textures/moreblocks_trap_stone.png | Bin .../moreblocks_trap_super_glow_glass.png | Bin .../textures/moreblocks_tree_stairsplus.png | Bin .../textures/moreblocks_wood_tile.png | Bin .../textures/moreblocks_wood_tile_center.png | Bin .../textures/moreblocks_wood_tile_full.png | Bin .../textures/moreblocks_wood_tile_up.png | Bin 103 files changed, 756 insertions(+), 1624 deletions(-) rename mods/maptools/{LICENSE.md => LICENSE.txt} (71%) delete mode 100644 mods/maptools/NODES.md delete mode 100644 mods/maptools/README.md create mode 100644 mods/maptools/README.txt create mode 100644 mods/maptools/_README.txt delete mode 100644 mods/maptools/config.lua delete mode 100644 mods/maptools/craftitems.lua delete mode 100644 mods/maptools/nodes.lua create mode 100644 mods/maptools/textures/maptools_super_apple_bottom.png create mode 100644 mods/maptools/textures/maptools_super_apple_side.png create mode 100644 mods/maptools/textures/maptools_super_apple_top.png delete mode 100644 mods/maptools/tools.lua rename mods/moreblocks/{LICENSE.md => LICENSE.txt} (71%) mode change 100644 => 100755 delete mode 100644 mods/moreblocks/README.md create mode 100755 mods/moreblocks/README.txt mode change 100644 => 100755 mods/moreblocks/aliases.lua mode change 100644 => 100755 mods/moreblocks/circular_saw.lua mode change 100644 => 100755 mods/moreblocks/config.lua mode change 100644 => 100755 mods/moreblocks/crafting.lua mode change 100644 => 100755 mods/moreblocks/depends.txt mode change 100644 => 100755 mods/moreblocks/init.lua mode change 100644 => 100755 mods/moreblocks/locale/de.txt mode change 100644 => 100755 mods/moreblocks/locale/es.txt mode change 100644 => 100755 mods/moreblocks/locale/fr.txt mode change 100644 => 100755 mods/moreblocks/locale/template.txt delete mode 100644 mods/moreblocks/models/moreblocks_slope.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_half.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_half_raised.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_inner.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_inner_half.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_outer.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_outer_cut.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_outer_half.obj delete mode 100644 mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj mode change 100644 => 100755 mods/moreblocks/nodes.lua mode change 100644 => 100755 mods/moreblocks/ownership.lua mode change 100644 => 100755 mods/moreblocks/redefinitions.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/API.md mode change 100644 => 100755 mods/moreblocks/stairsplus/aliases.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/conversion.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/init.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/microblocks.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/panels.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/registrations.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/slabs.lua delete mode 100644 mods/moreblocks/stairsplus/slopes.lua mode change 100644 => 100755 mods/moreblocks/stairsplus/stairs.lua mode change 100644 => 100755 mods/moreblocks/textures/default_brick.png mode change 100644 => 100755 mods/moreblocks/textures/default_fence_overlay.png mode change 100644 => 100755 mods/moreblocks/textures/invisible.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_cactus_brick.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_cactus_checker.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_circle_stone_bricks.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_circular_saw_bottom.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_circular_saw_side.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_circular_saw_top.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_clean_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_coal_checker.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_coal_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_coal_glass_stairsplus.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_coal_stone.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_coal_stone_bricks.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_empty_bookshelf.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_fence_jungle_wood.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_fence_wood.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_glass_stairsplus.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_glow_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_glow_glass_stairsplus.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_grey_bricks.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_iron_checker.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_iron_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_iron_glass_stairsplus.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_iron_stone.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_iron_stone_bricks.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_junglestick.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_obsidian_glass_stairsplus.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_plankstone.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_plankstone_2.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_rope.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_split_stone_tile.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_split_stone_tile_alt.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_split_stone_tile_top.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_stone_tile.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_super_glow_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_super_glow_glass_stairsplus.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_sweeper.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_tar.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_trap_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_trap_glow_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_trap_stone.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_trap_super_glow_glass.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_tree_stairsplus.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_wood_tile.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_wood_tile_center.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_wood_tile_full.png mode change 100644 => 100755 mods/moreblocks/textures/moreblocks_wood_tile_up.png diff --git a/mods/maptools/LICENSE.md b/mods/maptools/LICENSE.txt similarity index 71% rename from mods/maptools/LICENSE.md rename to mods/maptools/LICENSE.txt index ca48e3a1..f42bd647 100644 --- a/mods/maptools/LICENSE.md +++ b/mods/maptools/LICENSE.txt @@ -1,9 +1,8 @@ -zlib license -============ ++---- zlib/libpng license ----+ -Copyright (c) 2012-2015 Calinou and contributors +Copyright (c) 2013 Calinou -**This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.** +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: diff --git a/mods/maptools/NODES.md b/mods/maptools/NODES.md deleted file mode 100644 index f5ce3cc3..00000000 --- a/mods/maptools/NODES.md +++ /dev/null @@ -1,45 +0,0 @@ -Item names for spawning the items using /give or /giveme -======================================================== - -Items ------ - -* `admin_pick:` magenta pickaxe, infinite durability, mines everything including unbreakable blocks instantly. No drops. Don't put this pickaxe in the hands of a griefer, of course. - -* `admin_pick_with_drops:` same as admin pickaxe, but drops stuff. - -* `infinite_fuel:` fuel lasting for a (near)-infinite time. Don't worry about the "near" * it lasts for about 50 in-real-life years. - -* `super_apple:` a yellow apple which heals 20 HP. - -* `copper_coin,` -* `silver_coin,` -* `gold_coin:` these have nothing to do with the More Ores mod; they can be used as a currency for trading, or as an universal currency for mods that add shops. - -Blocks ------- - -**[!]** denotes an unpointable, unbreakable block; be very careful with them, they cannot be removed by hand (they can only be removed with WorldEdit or similar). - - -* `(block)_u` : unbreakable, non-flammable, non-falling, non-decaying blocks, most common blocks have their unbreakable form (examples: maptools:stone or maptools:wood for unbreakable stone/wood). Examples: `stone_u`, `wood_u`, `glass_u`, … - -* `full_grass:` unbreakable block with the grass texture on all sides. - -* `player_clip:` **[!]** invisible block, not pointable. - -* `full_clip:` invisible block, pointable. Also available as a thin face: full_clip_face. - -* `smoke_block:` some smoke (does not harm players or entities). - -* `no_build:` **[!]** very basic building prevention. - -* `no_interact:` prevents interacting through the block (opening chests, furnaces, attacking entities, …). - -* `damage_(1…5):` **[!]** damaging blocks. The damage is in half hearts and ranges from 1 to 5 (0.5 to 2.5 hearts damage every second). - -* `kill:` **[!]** instant kill (deals 10 heart damage) blocks. - -* `light_block:` **[!]** invisible non-solid block, prevents light from passing through. - -* `light_bulb:` **[!]** invisible non-solid block, emitting a good amount of light. diff --git a/mods/maptools/README.md b/mods/maptools/README.md deleted file mode 100644 index 3a428b7e..00000000 --- a/mods/maptools/README.md +++ /dev/null @@ -1,11 +0,0 @@ -Map Tools -========= - -Map Tools for Minetest , a free/libre infinite -world block sandbox game. - -To install, just clone this repository into your "mods" directory. - -Map Tools code is licensed under the zlib license, textures are by Calinou and are licensed under CC BY-SA 3.0 Unported. - -**Forum topic:** diff --git a/mods/maptools/README.txt b/mods/maptools/README.txt new file mode 100644 index 00000000..4c155813 --- /dev/null +++ b/mods/maptools/README.txt @@ -0,0 +1,22 @@ +Calinou's Minetest Mods +===================== + +Calinou's Mods for Minetest [http://minetest.net], a free and opensource Minecraft-like game. + +This Git repository is mostly made for servers; it allows easy updating. + +To install, just clone this repository somewhere, then copy the "calinou_mods" folder in the "mods/minetest" folder of Minetest's installation folder. + + + +Misc stuff +===================== + +All these mods' source codes, except More Ores are under the zlib/libpng license. More Ores is under the GNU GPLv3; the mods' textures are under the CC BY-SA 3.0 Unported. + +Mods' forum threads: +More Blocks: http://minetest.net/forum/viewtopic.php?id=509 +More Ores: http://minetest.net/forum/viewtopic.php?id=549 +Map Tools: http://minetest.net/forum/viewtopic.php?id=1882 +Doors+: http://minetest.net/forum/viewtopic.php?id=2059 +Stairs+: http://minetest.net/forum/viewtopic.php?id=2092 diff --git a/mods/maptools/_README.txt b/mods/maptools/_README.txt new file mode 100644 index 00000000..cfbe0b2e --- /dev/null +++ b/mods/maptools/_README.txt @@ -0,0 +1,53 @@ +*** Item names for spawning the items using /give or /giveme *** + +Items: + +- admin_pick +Purple pickaxe, infinite durability, mines everything including unbreakable blocks instantly. Don't put this pickaxe in the hands of a griefer, of course. :) + +- infinitefuel +Fuel lasting for a (near)-infinite time. Don't worry about the "near" - it lasts for about 50 in-real-life years. + +- superapple +An apple which heals all 10 hearts. + +- copper_coin +- silver_coin +- gold_coin +These have nothing to do with the More Ores mod; they can be used as a currency for trading, or as an universal currency for mods that add shops. + +Blocks: +A /!\ denotes an unpointable, unbreakable block; be very careful with them, they cannot be removed by hand (they can only be removed with WorldEdit). + +- (insert block name here)_u -- example: stone_u +Unbreakable, non-flammable, non-falling, non-decaying blocks, most common blocks have their unbreakable form (examples: maptools:stone or maptools:wood for unbreakable stone/wood). + +- fullgrass +Unbrakable block with the "grass" texture on all sides. + +- playerclip +/!\ Invisible block, not pointable. + +- fullclip +Invisible block, pointable. + +- smoke_block +Some smoke (does not harm players or entities). + +- nobuild +/!\ Very basic building prevention. + +- nointeract +Prevents interacting through the block (interacting as in opening chests, furnaces, attacking entities...). + +- damage_(insert damage in half hearts here) +/!\ Damaging blocks. The damage is in half hearts and ranges from 1 to 5 (0.5 to 2.5 hearts damage every second). + +- killblock +/!\ Instant kill (deals 10 heart damage) blocks. + +- lightblock +/!\ Invisible non-solid block, prevents light from passing through. + +- lightbulb +/!\ Invisible non-solid block, emitting a good amount of light. diff --git a/mods/maptools/aliases.lua b/mods/maptools/aliases.lua index f1f0cc57..8742f44e 100644 --- a/mods/maptools/aliases.lua +++ b/mods/maptools/aliases.lua @@ -1,9 +1,4 @@ ---[[ -Map Tools: alias definitions - -Copyright (c) 2012-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] +-- Aliases minetest.register_alias("adminpick", "maptools:pick_admin") minetest.register_alias("adminpickaxe", "maptools:pick_admin") @@ -74,6 +69,8 @@ minetest.register_alias("fake_fire", "maptools:fake_fire") minetest.register_alias("ffire", "maptools:fake_fire") minetest.register_alias("igniter", "maptools:igniter") +-- Unbreakable block aliases + minetest.register_alias("stone_u", "maptools:stone") minetest.register_alias("tree_u", "maptools:tree") minetest.register_alias("cobble_u", "maptools:cobble") diff --git a/mods/maptools/config.lua b/mods/maptools/config.lua deleted file mode 100644 index 63f1a260..00000000 --- a/mods/maptools/config.lua +++ /dev/null @@ -1,29 +0,0 @@ ---[[ -Map Tools: configuration handling - -Copyright (c) 2012-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -maptools.config = {} - -local function getbool_default(setting, default) - local value = minetest.setting_getbool(setting) - if value == nil then - value = default - end - return value -end - -local function setting(settingtype, name, default) - if settingtype == "bool" then - maptools.config[name] = - getbool_default("maptools." .. name, default) - else - maptools.config[name] = - minetest.setting_get("maptools." .. name) or default - end -end - --- Show Map Tools stuff in creative inventory (1 or 0): -setting("integer", "hide_from_creative_inventory", 1) diff --git a/mods/maptools/craftitems.lua b/mods/maptools/craftitems.lua deleted file mode 100644 index c311aa95..00000000 --- a/mods/maptools/craftitems.lua +++ /dev/null @@ -1,47 +0,0 @@ ---[[ -Map Tools: item definitions - -Copyright (c) 2012-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = maptools.intllib - -maptools.creative = maptools.config["hide_from_creative_inventory"] - -minetest.register_craftitem("maptools:copper_coin", { - description = S("Copper Coin"), - inventory_image = "maptools_copper_coin.png", - wield_scale = {x = 0.5, y = 0.5, z = 0.25}, - stack_max = 10000, - groups = {not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_craftitem("maptools:silver_coin", { - description = S("Silver Coin"), - inventory_image = "maptools_silver_coin.png", - wield_scale = {x = 0.5, y = 0.5, z = 0.25}, - stack_max = 10000, - groups = {not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_craftitem("maptools:gold_coin", { - description = S("Gold Coin"), - inventory_image = "maptools_gold_coin.png", - wield_scale = {x = 0.5, y = 0.5, z = 0.25}, - stack_max = 10000, - groups = {not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_craftitem("maptools:infinitefuel", { - description = S("Infinite Fuel"), - inventory_image = "maptools_infinitefuel.png", - stack_max = 10000, - groups = {not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_craft({ - type = "fuel", - recipe = "maptools:infinitefuel", - burntime = 1000000000, -}) diff --git a/mods/maptools/default_nodes.lua b/mods/maptools/default_nodes.lua index 3ac0caf5..83d0df02 100644 --- a/mods/maptools/default_nodes.lua +++ b/mods/maptools/default_nodes.lua @@ -1,13 +1,10 @@ ---[[ -Map Tools: unbreakable default nodes - -Copyright (c) 2012-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = maptools.intllib - -maptools.creative = maptools.config["hide_from_creative_inventory"] +local S +if (minetest.get_modpath("intllib")) then + dofile(minetest.get_modpath("intllib").."/intllib.lua") + S = intllib.Getter(minetest.get_current_modname()) + else + S = function ( s ) return s end +end minetest.register_node("maptools:stone", { description = S("Unbreakable Stone"), @@ -15,7 +12,7 @@ minetest.register_node("maptools:stone", { stack_max = 10000, tiles = {"default_stone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -25,7 +22,7 @@ minetest.register_node("maptools:stonebrick", { stack_max = 10000, tiles = {"default_stone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -35,7 +32,7 @@ minetest.register_node("maptools:tree", { stack_max = 10000, tiles = {"default_tree_top.png", "default_tree_top.png", "default_tree.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -46,7 +43,7 @@ minetest.register_node("maptools:jungletree", { stack_max = 10000, tiles = {"default_jungletree_top.png", "default_jungletree_top.png", "default_jungletree.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -57,7 +54,7 @@ minetest.register_node("maptools:cactus", { stack_max = 10000, tiles = {"default_cactus_top.png", "default_cactus_top.png", "default_cactus_side.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_wood_defaults(), on_place = minetest.rotate_node }) @@ -78,7 +75,7 @@ minetest.register_node("maptools:papyrus", { type = "fixed", fixed = {-0.375, -0.5, -0.375, 0.375, 0.5, 0.375} }, - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_leaves_defaults(), }) @@ -88,7 +85,7 @@ minetest.register_node("maptools:dirt", { stack_max = 10000, tiles = {"default_dirt.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_dirt_defaults(), }) @@ -98,7 +95,7 @@ minetest.register_node("maptools:wood", { stack_max = 10000, tiles = {"default_wood.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_wood_defaults(), }) @@ -108,7 +105,7 @@ minetest.register_node("maptools:junglewood", { stack_max = 10000, tiles = {"default_junglewood.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_wood_defaults(), }) @@ -121,7 +118,7 @@ minetest.register_node("maptools:glass", { paramtype = "light", sunlight_propagates = true, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_glass_defaults(), }) @@ -133,7 +130,7 @@ minetest.register_node("maptools:leaves", { tiles = {"default_leaves.png"}, paramtype = "light", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_leaves_defaults(), }) @@ -143,7 +140,7 @@ minetest.register_node("maptools:sand", { stack_max = 10000, tiles = {"default_sand.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_sand_defaults(), }) @@ -153,7 +150,7 @@ minetest.register_node("maptools:gravel", { stack_max = 10000, tiles = {"default_gravel.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_gravel_footstep", gain=0.35}, dug = {name="default_gravel_footstep", gain=0.6}, @@ -166,7 +163,7 @@ minetest.register_node("maptools:clay", { stack_max = 10000, tiles = {"default_clay.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_dirt_defaults(), }) @@ -176,7 +173,7 @@ minetest.register_node("maptools:desert_sand", { stack_max = 10000, tiles = {"default_desert_sand.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_sand_defaults(), }) @@ -186,7 +183,7 @@ minetest.register_node("maptools:sandstone", { stack_max = 10000, tiles = {"default_sandstone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -196,7 +193,7 @@ minetest.register_node("maptools:sandstone_brick", { stack_max = 10000, tiles = {"default_sandstone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -206,7 +203,7 @@ minetest.register_node("maptools:desert_stone", { stack_max = 10000, tiles = {"default_desert_stone.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -216,7 +213,7 @@ minetest.register_node("maptools:desert_cobble", { stack_max = 10000, tiles = {"default_desert_cobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -226,7 +223,7 @@ minetest.register_node("maptools:desert_stonebrick", { stack_max = 10000, tiles = {"default_desert_stone_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -237,7 +234,7 @@ minetest.register_node("maptools:grass", { tiles = {"default_grass.png", "default_dirt.png", "default_dirt.png^default_grass_side.png"}, paramtype2 = "facedir", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_grass_footstep", gain = 0.4}, }), @@ -249,7 +246,7 @@ minetest.register_node("maptools:fullgrass", { stack_max = 10000, tiles = {"default_grass.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_dirt_defaults({ footstep = {name="default_grass_footstep", gain=0.4}, }), @@ -270,7 +267,7 @@ for slab_num = 1,3,1 do paramtype = "light", paramtype2 = "facedir", drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_dirt_defaults({footstep = {name="default_grass_footstep", gain = 0.4}}), }) end @@ -281,7 +278,7 @@ minetest.register_node("maptools:cobble", { stack_max = 10000, tiles = {"default_cobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -291,7 +288,7 @@ minetest.register_node("maptools:mossycobble", { stack_max = 10000, tiles = {"default_mossycobble.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -301,7 +298,7 @@ minetest.register_node("maptools:brick", { stack_max = 10000, tiles = {"default_brick.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -311,7 +308,7 @@ minetest.register_node("maptools:coalblock", { stack_max = 10000, tiles = {"default_coal_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -322,7 +319,7 @@ minetest.register_node("maptools:steelblock", { stack_max = 10000, tiles = {"default_steel_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -332,7 +329,7 @@ minetest.register_node("maptools:goldblock", { stack_max = 10000, tiles = {"default_gold_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -342,7 +339,7 @@ minetest.register_node("maptools:copperblock", { stack_max = 10000, tiles = {"default_copper_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -352,7 +349,7 @@ minetest.register_node("maptools:bronzeblock", { stack_max = 10000, tiles = {"default_bronze_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -360,9 +357,9 @@ minetest.register_node("maptools:diamondblock", { description = S("Unbreakable Diamond Block"), range = 12, stack_max = 10000, - tiles = {"default_steel_block.png"}, + tiles = {"default_diamond_block.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative}, sounds = default.node_sound_stone_defaults(), }) @@ -374,7 +371,7 @@ minetest.register_node("maptools:soil_wet", { stack_max = 10000, tiles = {"farming_soil_wet.png", "farming_soil_wet_side.png"}, drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, soil = 3, wet = 1, grassland = 1}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative, soil = 3, wet = 1, grassland = 1}, sounds = default.node_sound_dirt_defaults(), }) @@ -384,6 +381,6 @@ minetest.register_node("maptools:desert_sand_soil_wet", { stack_max = 10000, drop = "", tiles = {"farming_desert_sand_soil_wet.png", "farming_desert_sand_soil_wet_side.png"}, - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, soil = 3, wet = 1, desert = 1}, + groups = {unbreakable = 1, not_in_creative_inventory = maptools_creative, soil = 3, wet = 1, desert = 1}, sounds = default.node_sound_sand_defaults(), }) diff --git a/mods/maptools/init.lua b/mods/maptools/init.lua index dbff209c..c5178fae 100644 --- a/mods/maptools/init.lua +++ b/mods/maptools/init.lua @@ -1,32 +1,551 @@ ---[[ -===================================================================== -** Map Tools ** -By Calinou. - -Copyright (c) 2012-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. -===================================================================== ---]] - -maptools = {} - -local S -if minetest.get_modpath("intllib") then - S = intllib.Getter() -else - S = function(s) return s end -end -maptools.intllib = S - -local modpath = minetest.get_modpath("maptools") - -dofile(modpath .. "/config.lua") -dofile(modpath .. "/aliases.lua") -dofile(modpath .. "/craftitems.lua") -dofile(modpath .. "/default_nodes.lua") -dofile(modpath .. "/nodes.lua") -dofile(modpath .. "/tools.lua") - -if minetest.setting_getbool("log_mods") then - minetest.log("action", S("[maptools] loaded.")) -end +MAPTOOLS_CREATIVE = 1 -- Set this to 0 if you want Map Tools nodes and items to appear in the creative inventory. + +-- Load translation library if intllib is installed + +local S +if (minetest.get_modpath("intllib")) then + dofile(minetest.get_modpath("intllib").."/intllib.lua") + S = intllib.Getter(minetest.get_current_modname()) + else + S = function ( s ) return s end +end + +dofile(minetest.get_modpath("maptools").."/aliases.lua") +dofile(minetest.get_modpath("maptools").."/default_nodes.lua") + +--[[ +Map Tools by Calinou +Licensed under the zlib license for code and CC BY-SA 3.0 for textures, see LICENSE.txt for info. +--]] + +-- Redefine cloud so that the admin pickaxe can mine it. + +minetest.register_node(":default:cloud", { + description = S("Cloud"), + tiles = {"default_cloud.png"}, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + sounds = default.node_sound_defaults(), +}) + +-- Items + +minetest.register_craft({ + type = "fuel", + recipe = "maptools:infinitefuel", + burntime = 1000000000, +}) + +-- Nodes + +minetest.register_node("maptools:black", { + description = S("Black"), + range = 12, + stack_max = 10000, + tiles = {"black.png"}, + drop = "", + post_effect_color = {a=255, r=0, g=0, b=0}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_node("maptools:white", { + description = S("White"), + range = 12, + stack_max = 10000, + tiles = {"white.png"}, + drop = "", + post_effect_color = {a=255, r=128, g=128, b=128}, + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_node("maptools:playerclip", { + description = S("Player Clip"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_green.png", + drawtype = "airlike", + paramtype = "light", + pointable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:fake_walkable", { + description = S("Player Clip"), + drawtype = "nodebox", + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_green.png", + drawtype = "airlike", + paramtype = "light", + pointable = false, + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = { + {0, 0, 0, 0, 0, 0}, + }, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:fullclip", { + description = S("Full Clip"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_blue.png", + drawtype = "airlike", + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:fake_walkable_pointable", { + description = S("Player Clip"), + drawtype = "nodebox", + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_green.png", + drawtype = "airlike", + paramtype = "light", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = { + {0, 0, 0, 0, 0, 0}, + }, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:ignore_like", { + description = S("Ignore-like"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_pink.png", + tiles = {"invisible.png"}, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:ignore_like_no_clip", { + description = S("Ignore-like (no clip)"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_purple.png", + tiles = {"invisible.png"}, + paramtype = "light", + walkable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + + +minetest.register_node("maptools:ignore_like_no_point", { + description = S("Ignore-like (no point)"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_purple.png", + tiles = {"invisible.png"}, + paramtype = "light", + pointable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:ignore_like_no_clip_no_point", { + description = S("Ignore-like (no clip, no point)"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_pink.png", + tiles = {"invisible.png"}, + paramtype = "light", + walkable = false, + pointable = false, + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:fullclip_face", { + description = S("Full Clip Face"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_white.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100}, +}) + +minetest.register_node("maptools:playerclip_bottom", { + description = S("Player Clip Bottom Face"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_orange.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100}, +}) + +minetest.register_node("maptools:playerclip_top", { + description = S("Player Clip Top Face"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_yellow.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, 0.4999, -0.5, 0.5, 0.5, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100}, +}) + +for pusher_num=1,10,1 do +minetest.register_node("maptools:pusher_" .. pusher_num, { + description = S("Pusher (%s)"):format(pusher_num), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_apple.png", + drawtype = "nodebox", + tiles = {"invisible.png"}, + paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE, fall_damage_add_percent=-100, bouncy=pusher_num*100}, +}) +end + +minetest.register_node("maptools:lightbulb", { + description = S("Light Bulb"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_mese_crystal_fragment.png", + drawtype = "airlike", + walkable = false, + pointable = false, + light_source = 15, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:nobuild", { + description = S("Build Prevention"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^bones_bones.png", + drawtype = "airlike", + walkable = false, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:nointeract", { + description = S("Interact Prevention"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_scorched_stuff.png", + drawtype = "airlike", + walkable = false, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:climb", { + description = S("Climb Block"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^default_ladder.png", + drawtype = "airlike", + walkable = false, + climbable = true, + pointable = false, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +for damage_num=1,5,1 do +minetest.register_node("maptools:damage_" .. damage_num, { + description = S("Damaging Block (%s)"):format(damage_num), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^farming_cotton_" .. damage_num .. ".png", + drawtype = "airlike", + walkable = false, + pointable = false, + damage_per_second = damage_num, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) +end + +minetest.register_node("maptools:kill", { + description = S("Kill Block"), + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^dye_black.png", + drawtype = "airlike", + walkable = false, + pointable = false, + damage_per_second = 20, + paramtype = "light", + sunlight_propagates = true, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_node("maptools:smoke", { + description = S("Smoke Block"), + range = 12, + stack_max = 10000, + tiles = {"maptools_smoke.png"}, + drawtype = "allfaces_optional", + walkable = false, + paramtype = "light", + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + post_effect_color = {a=192, r=96, g=96, b=96}, +}) + +minetest.register_node("maptools:ladder", { + description = S("Fake Ladder"), + range = 12, + stack_max = 10000, + drawtype = "signlike", + tiles = {"default_ladder.png"}, + inventory_image = "default_ladder.png", + wield_image = "default_ladder.png", + paramtype = "light", + paramtype2 = "wallmounted", + walkable = false, + sunlight_propagates = true, + selection_box = { + type = "wallmounted", + }, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + sounds = default.node_sound_wood_defaults(), +}) + +minetest.register_node("maptools:permanent_fire", { + description = S("Permanent Fire"), + range = 12, + stack_max = 10000, + drawtype = "plantlike", + paramtype = "light", + tiles = {{ + name="fire_basic_flame_animated.png", + animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, + }}, + inventory_image = "fire_basic_flame.png", + light_source = 14, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + sunlight_propagates = true, + walkable = false, + damage_per_second = 4, +}) + +minetest.register_node("maptools:fake_fire", { + description = S("Fake Fire"), + range = 12, + stack_max = 10000, + drawtype = "plantlike", + paramtype = "light", + tiles = {{ + name="fire_basic_flame_animated.png", + animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, + }}, + inventory_image = "fire_basic_flame.png", + light_source = 14, + drop = "", + groups = {unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + sunlight_propagates = true, + walkable = false, +}) + +minetest.register_node("maptools:igniter", { + drawtype = "airlike", + range = 12, + stack_max = 10000, + inventory_image = "default_steel_block.png^crosshair.png", + description = S("Igniter"), + paramtype = "light", + inventory_image = "fire_basic_flame.png", + drop = "", + groups = {igniter=2, unbreakable = 1, not_in_creative_inventory = MAPTOOLS_CREATIVE}, + sunlight_propagates = true, + pointable = false, + walkable = false, +}) + +minetest.register_node("maptools:superapple", { + description = S("Super Apple"), + range = 12, + stack_max = 99, + drawtype = "nodebox", + visual_scale = 1.0, + tiles = {"maptools_super_apple_top.png","maptools_super_apple_bottom.png","maptools_super_apple_side.png"}, + inventory_image = "maptools_superapple.png", + paramtype = "light", + sunlight_propagates = true, + walkable = false, + node_box = { + type = "fixed", + fixed = { + {-3/16, -7/16, -3/16, 3/16, 1/16, 3/16}, + {-4/16, -6/16, -3/16, 4/16, 0, 3/16}, + {-3/16, -6/16, -4/16, 3/16, 0, 4/16}, + {-1/32, 1/16, -1/32, 1/32, 4/16, 1/32}, + {-1/16, 1.6/16, 0, 1/16, 1.8/16, 1/16}, + {-2/16, 1.4/16, 1/16, 1/16, 1.6/16, 2/16}, + {-2/16, 1.2/16, 2/16, 0, 1.4/16, 3/16}, + {-1.5/16, 1/16, .5/16, 0.5/16, 1.2/16, 2.5/16}, + } + }, + is_ground_content = true, + groups = {fleshy = 3, dig_immediate = 3, not_in_creative_inventory = 0, flammable = 2, leafdecay = 3, leafdecay_drop = 1}, + on_use = minetest.item_eat(20), + sounds = default.node_sound_leaves_defaults(), + after_place_node = function(pos, placer, itemstack) + if placer:is_player() then + minetest.set_node(pos, {name = "maptools:superapple", param2= 1}) + end + end, +}) + +-- Items + +minetest.register_craftitem("maptools:copper_coin", { + description = S("Copper Coin"), + inventory_image = "maptools_copper_coin.png", + wield_scale = {x = 0.5, y = 0.5, z = 0.25}, + stack_max = 10000, + groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_craftitem("maptools:silver_coin", { + description = S("Silver Coin"), + inventory_image = "maptools_silver_coin.png", + wield_scale = {x = 0.5, y = 0.5, z = 0.25}, + stack_max = 10000, + groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_craftitem("maptools:gold_coin", { + description = S("Gold Coin"), + inventory_image = "maptools_gold_coin.png", + wield_scale = {x = 0.5, y = 0.5, z = 0.25}, + stack_max = 10000, + groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +minetest.register_craftitem("maptools:infinitefuel", { + description = S("Infinite Fuel"), + inventory_image = "maptools_infinitefuel.png", + stack_max = 10000, + groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, +}) + +-- Tools + +minetest.register_tool("maptools:pick_admin", { + description = S("Admin Pickaxe"), + range = 12, + inventory_image = "maptools_adminpick.png", + groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, + tool_capabilities = { + full_punch_interval = 0.1, + max_drop_level = 3, + groupcaps= { + unbreakable = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + fleshy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + choppy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + bendy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + cracky = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + crumbly = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + snappy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + }, + damage_groups = {fleshy = 1000}, + }, +}) + +minetest.register_tool("maptools:pick_admin_with_drops", { + description = S("Admin Pickaxe with Drops"), + range = 12, + inventory_image = "maptools_adminpick_with_drops.png", + groups = {not_in_creative_inventory = MAPTOOLS_CREATIVE}, + tool_capabilities = { + full_punch_interval = 0.35, + max_drop_level = 3, + groupcaps = { + unbreakable = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + fleshy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + choppy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + bendy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + cracky = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + crumbly = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + snappy = {times={[1] = 0, [2] = 0, [3] = 0}, uses = 0, maxlevel = 3}, + }, + damage_groups = {fleshy = 1000}, + }, +}) + +minetest.register_on_punchnode(function(pos, node, puncher) + if puncher:get_wielded_item():get_name() == "maptools:pick_admin" + and minetest.get_node(pos).name ~= "air" then + minetest.log("action", puncher:get_player_name() .. " digs " .. minetest.get_node(pos).name .. " at " .. minetest.pos_to_string(pos) .. " using an Admin Pickaxe.") + minetest.remove_node(pos) -- The node is removed directly, which means it even works on non-empty containers and group-less nodes. + nodeupdate(pos) -- Run node update actions like falling nodes. + end +end) + +if minetest.setting_getbool("log_mods") then + minetest.log("action", "Carbone: [maptools] loaded.") +end diff --git a/mods/maptools/nodes.lua b/mods/maptools/nodes.lua deleted file mode 100644 index 8ceef647..00000000 --- a/mods/maptools/nodes.lua +++ /dev/null @@ -1,429 +0,0 @@ ---[[ -Map Tools: node definitions - -Copyright (c) 2012-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = maptools.intllib - -maptools.creative = maptools.config["hide_from_creative_inventory"] - --- Redefine cloud so that the admin pickaxe can mine it: -minetest.register_node(":default:cloud", { - description = S("Cloud"), - tiles = {"default_cloud.png"}, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, - sounds = default.node_sound_defaults(), -}) - --- Nodes --- ===== - -minetest.register_node("maptools:black", { - description = S("Black"), - range = 12, - stack_max = 10000, - tiles = {"black.png"}, - drop = "", - post_effect_color = {a=255, r=0, g=0, b=0}, - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, - sounds = default.node_sound_stone_defaults(), -}) - -minetest.register_node("maptools:white", { - description = S("White"), - range = 12, - stack_max = 10000, - tiles = {"white.png"}, - drop = "", - post_effect_color = {a=255, r=128, g=128, b=128}, - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, - sounds = default.node_sound_stone_defaults(), -}) - -minetest.register_node("maptools:playerclip", { - description = S("Player Clip"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_green.png", - drawtype = "airlike", - paramtype = "light", - pointable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:fake_walkable", { - description = S("Player Clip"), - drawtype = "nodebox", - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_green.png", - drawtype = "airlike", - paramtype = "light", - pointable = false, - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = { - {0, 0, 0, 0, 0, 0}, - }, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:fullclip", { - description = S("Full Clip"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_blue.png", - drawtype = "airlike", - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:fake_walkable_pointable", { - description = S("Player Clip"), - drawtype = "nodebox", - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_green.png", - drawtype = "airlike", - paramtype = "light", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = { - {0, 0, 0, 0, 0, 0}, - }, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:ignore_like", { - description = S("Ignore-like"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_pink.png", - tiles = {"invisible.png"}, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:ignore_like_no_clip", { - description = S("Ignore-like (no clip)"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_purple.png", - tiles = {"invisible.png"}, - paramtype = "light", - walkable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - - -minetest.register_node("maptools:ignore_like_no_point", { - description = S("Ignore-like (no point)"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_purple.png", - tiles = {"invisible.png"}, - paramtype = "light", - pointable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:ignore_like_no_clip_no_point", { - description = S("Ignore-like (no clip, no point)"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_pink.png", - tiles = {"invisible.png"}, - paramtype = "light", - walkable = false, - pointable = false, - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:fullclip_face", { - description = S("Full Clip Face"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_white.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - paramtype = "light", - paramtype2 = "facedir", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100}, -}) - -minetest.register_node("maptools:playerclip_bottom", { - description = S("Player Clip Bottom Face"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_orange.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100}, -}) - -minetest.register_node("maptools:playerclip_top", { - description = S("Player Clip Top Face"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_yellow.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, 0.4999, -0.5, 0.5, 0.5, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100}, -}) - -for pusher_num=1,10,1 do -minetest.register_node("maptools:pusher_" .. pusher_num, { - description = S("Pusher (%s)"):format(pusher_num), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_apple.png", - drawtype = "nodebox", - tiles = {"invisible.png"}, - paramtype = "light", - paramtype2 = "facedir", - sunlight_propagates = true, - node_box = { - type = "fixed", - fixed = {-0.5, -0.5, -0.5, 0.5, -0.4999, 0.5}, - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative, fall_damage_add_percent=-100, bouncy=pusher_num*100}, -}) -end - -minetest.register_node("maptools:lightbulb", { - description = S("Light Bulb"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_mese_crystal_fragment.png", - drawtype = "airlike", - walkable = false, - pointable = false, - light_source = 15, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:nobuild", { - description = S("Build Prevention"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^bones_bones.png", - drawtype = "airlike", - walkable = false, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:nointeract", { - description = S("Interact Prevention"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_scorched_stuff.png", - drawtype = "airlike", - walkable = false, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:climb", { - description = S("Climb Block"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^default_ladder.png", - drawtype = "airlike", - walkable = false, - climbable = true, - pointable = false, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -for damage_num=1,5,1 do -minetest.register_node("maptools:damage_" .. damage_num, { - description = S("Damaging Block (%s)"):format(damage_num), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^farming_cotton_" .. damage_num .. ".png", - drawtype = "airlike", - walkable = false, - pointable = false, - damage_per_second = damage_num, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) -end - -minetest.register_node("maptools:kill", { - description = S("Kill Block"), - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^dye_black.png", - drawtype = "airlike", - walkable = false, - pointable = false, - damage_per_second = 20, - paramtype = "light", - sunlight_propagates = true, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, -}) - -minetest.register_node("maptools:smoke", { - description = S("Smoke Block"), - range = 12, - stack_max = 10000, - tiles = {"maptools_smoke.png"}, - drawtype = "allfaces_optional", - walkable = false, - paramtype = "light", - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, - post_effect_color = {a=192, r=96, g=96, b=96}, -}) - -minetest.register_node("maptools:ladder", { - description = S("Fake Ladder"), - range = 12, - stack_max = 10000, - drawtype = "signlike", - tiles = {"default_ladder.png"}, - inventory_image = "default_ladder.png", - wield_image = "default_ladder.png", - paramtype = "light", - paramtype2 = "wallmounted", - walkable = false, - sunlight_propagates = true, - selection_box = { - type = "wallmounted", - }, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, - sounds = default.node_sound_wood_defaults(), -}) - -minetest.register_node("maptools:permanent_fire", { - description = S("Permanent Fire"), - range = 12, - stack_max = 10000, - drawtype = "plantlike", - paramtype = "light", - tiles = {{ - name="fire_basic_flame_animated.png", - animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, - }}, - inventory_image = "fire_basic_flame.png", - light_source = 14, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, - sunlight_propagates = true, - walkable = false, - damage_per_second = 4, -}) - -minetest.register_node("maptools:fake_fire", { - description = S("Fake Fire"), - range = 12, - stack_max = 10000, - drawtype = "plantlike", - paramtype = "light", - tiles = {{ - name="fire_basic_flame_animated.png", - animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=1}, - }}, - inventory_image = "fire_basic_flame.png", - light_source = 14, - drop = "", - groups = {unbreakable = 1, not_in_creative_inventory = maptools.creative}, - sunlight_propagates = true, - walkable = false, -}) - -minetest.register_node("maptools:igniter", { - drawtype = "airlike", - range = 12, - stack_max = 10000, - inventory_image = "default_steel_block.png^crosshair.png", - description = S("Igniter"), - paramtype = "light", - inventory_image = "fire_basic_flame.png", - drop = "", - groups = {igniter=2, unbreakable = 1, not_in_creative_inventory = maptools.creative}, - sunlight_propagates = true, - pointable = false, - walkable = false, -}) - -minetest.register_node("maptools:superapple", { - description = S("Super Apple"), - range = 12, - stack_max = 10000, - drawtype = "plantlike", - visual_scale = 1.0, - tiles = {"maptools_superapple.png"}, - inventory_image = "maptools_superapple.png", - paramtype = "light", - sunlight_propagates = true, - selection_box = { - type = "fixed", - fixed = {-0.2, -0.5, -0.2, 0.2, 0, 0.2} - }, - walkable = false, - groups = {fleshy=3, dig_immediate=3, not_in_creative_inventory = maptools.creative}, - on_use = minetest.item_eat(20), - sounds = default.node_sound_defaults(), -}) diff --git a/mods/maptools/textures/maptools_super_apple_bottom.png b/mods/maptools/textures/maptools_super_apple_bottom.png new file mode 100644 index 0000000000000000000000000000000000000000..97f61e171c0291015d80fb19c8cbae5a11436b2b GIT binary patch literal 295 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b z3=G`DAk4@xYmNj^kiEpy*OmPqkEEyw(>0&3oIs&1o-U3d7N?(1G~{Y_5OJA*I(_0% zraVvj6r-M*LXT7jAL4j?;3E=m$^F zGdWW47!ETWa|m1!KkfE!6)`c!=OPMBm3)c^Yz{yDG-u)srsoQ$58M(p@V&6@_HEt+ z60B#8dloaTxmxb?>?#N2rI2Q&TYDPz-rsnjI`?#OZrq-TAG!-(U%TmDeE;>L*!vOJ mfAt<)^VxO5sz=}duVb%TVcO~SWotOl{S2P2elF{r5}E)Rt8^Iv literal 0 HcmV?d00001 diff --git a/mods/maptools/textures/maptools_super_apple_side.png b/mods/maptools/textures/maptools_super_apple_side.png new file mode 100644 index 0000000000000000000000000000000000000000..cd4c83153f2abe5c0c2ed349e3c0d676b27a2f80 GIT binary patch literal 295 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b z3=G`DAk4@xYmNj^kiEpy*OmPqkEE!u^3{~$2|%GOo-U3d7N?(1G~{Y_5OJA*I(_0% zraVvj6r-M*LXT7jAL4j?;3E=m$^F zGdWW47!ETWa|m1!KkfE!6)`c!=OPMBm3)c^Yz{yDG-u)srsoQ$58M(p@V&6@_HEt+ z60B#8dloaTxmxb?>?#N2rI2Q&TYDPz-rsnjI`?#OZrq-TAG!-(U%TmDeE;>L*!vOJ mfAt<)^VxO5sz=}duVb%TVcO~SWotOl{S2P2elF{r5}E)>;dE61 literal 0 HcmV?d00001 diff --git a/mods/maptools/textures/maptools_super_apple_top.png b/mods/maptools/textures/maptools_super_apple_top.png new file mode 100644 index 0000000000000000000000000000000000000000..4d4dbc056e1913768f70134e28a6bf551b87216b GIT binary patch literal 498 zcmV{Ut&2O5LW0q`a zv=Id$>4dnxgUhon0QI^&*J}AI;MYCiTY+p=^8M`^$0rfegE#=`xRfTB8%?L, a free/libre infinite -world block sandbox game. - -To install, just clone this repository into your "mods" directory. - -More Blocks code is licensed under the zlib license, textures are by Calinou and are licensed under CC BY-SA 3.0 Unported. - -**Forum topic:** diff --git a/mods/moreblocks/README.txt b/mods/moreblocks/README.txt new file mode 100755 index 00000000..aa99eda3 --- /dev/null +++ b/mods/moreblocks/README.txt @@ -0,0 +1,12 @@ +More Blocks +========== + +More Blocks for Minetest (http://minetest.net), a free and open source infinite +world block sandbox game. + +To install, just clone this repository into your "mods" directory. + +More Blocks code is under the zlib license, textures are under CC BY-SA 3.0 unported. + +Forum topic: http://forum.minetest.net/viewtopic.php?id=509 + diff --git a/mods/moreblocks/aliases.lua b/mods/moreblocks/aliases.lua old mode 100644 new mode 100755 index 15f7b6b2..df820c33 --- a/mods/moreblocks/aliases.lua +++ b/mods/moreblocks/aliases.lua @@ -1,28 +1,24 @@ ---[[ -More Blocks: alias definitions +-- More Blocks aliases -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - --- More Blocks aliases: minetest.register_alias("sweeper", "moreblocks:sweeper") minetest.register_alias("circular_saw", "moreblocks:circular_saw") minetest.register_alias("jungle_stick", "moreblocks:jungle_stick") --- Old block/item replacement: +-- Old block/item replacement + minetest.register_alias("moreblocks:oerkkiblock", "default:mossycobble") minetest.register_alias("moreblocks:screwdriver", "screwdriver:screwdriver") --- Node and item renaming: +-- Node and item renaming + minetest.register_alias("moreblocks:stone_bricks", "default:stonebrick") minetest.register_alias("moreblocks:stonebrick", "default:stonebrick") minetest.register_alias("moreblocks:junglewood", "default:junglewood") minetest.register_alias("moreblocks:jungle_wood", "default:junglewood") for _, t in pairs(circular_saw.names) do - minetest.register_alias("moreblocks:" .. t[1] .. "_jungle_wood" .. t[2], - "moreblocks:" .. t[1] .. "_junglewood" .. t[2]) + minetest.register_alias("moreblocks:" ..t[1].. "_jungle_wood" ..t[2], + "moreblocks:" ..t[1].. "_junglewood" ..t[2]) end minetest.register_alias("moreblocks:horizontaltree", "moreblocks:horizontal_tree") minetest.register_alias("moreblocks:horizontaljungletree", "moreblocks:horizontal_jungle_tree") @@ -55,7 +51,8 @@ minetest.register_alias("moreblocks:junglestick", "moreblocks:jungle_stick") minetest.register_alias("moreblocks:splitstonesquare","moreblocks:split_stone_tile") minetest.register_alias("moreblocks:allfacestree","moreblocks:all_faces_tree") --- ABM for horizontal trees (fix facedir): +-- ABM for horizontal trees (fix facedir). + local horizontal_tree_convert_facedir = {7, 12, 9, 18} minetest.register_abm({ diff --git a/mods/moreblocks/circular_saw.lua b/mods/moreblocks/circular_saw.lua old mode 100644 new mode 100755 index 98ddecbc..2af5972a --- a/mods/moreblocks/circular_saw.lua +++ b/mods/moreblocks/circular_saw.lua @@ -1,12 +1,4 @@ ---[[ -More Blocks: circular saw - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = moreblocks.intllib - +local S = moreblocks.gettext circular_saw = {} circular_saw.known_stairs = setmetatable({}, { diff --git a/mods/moreblocks/config.lua b/mods/moreblocks/config.lua old mode 100644 new mode 100755 index d646dacd..e5db0861 --- a/mods/moreblocks/config.lua +++ b/mods/moreblocks/config.lua @@ -1,10 +1,3 @@ ---[[ -More Blocks: configuration handling - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - moreblocks.config = {} local function getbool_default(setting, default) diff --git a/mods/moreblocks/crafting.lua b/mods/moreblocks/crafting.lua old mode 100644 new mode 100755 index 4429d9ae..158d40a5 --- a/mods/moreblocks/crafting.lua +++ b/mods/moreblocks/crafting.lua @@ -1,9 +1,4 @@ ---[[ -More Blocks: crafting recipes - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] +-- Crafting minetest.register_craft({ output = "default:stick", diff --git a/mods/moreblocks/depends.txt b/mods/moreblocks/depends.txt old mode 100644 new mode 100755 index 198fe8a6..9207dab8 --- a/mods/moreblocks/depends.txt +++ b/mods/moreblocks/depends.txt @@ -1,2 +1,2 @@ -default -intllib? +default +intllib? diff --git a/mods/moreblocks/init.lua b/mods/moreblocks/init.lua old mode 100644 new mode 100755 index 2919a308..a86a38ea --- a/mods/moreblocks/init.lua +++ b/mods/moreblocks/init.lua @@ -1,22 +1,20 @@ --[[ -===================================================================== -** More Blocks ** -By Calinou, with the help of ShadowNinja and VanessaE. - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. -===================================================================== +-- More Blocks (moreblocks) by Calinou +-- Licensed under the zlib/ license for code and CC BY-SA 3.0 for textures, see LICENSE.txt for info. --]] moreblocks = {} -local S -if minetest.get_modpath("intllib") then - S = intllib.Getter() +-- Load translation library if intllib is installed + +local S -- Load translation library if intllib is installed: +if (minetest.get_modpath("intllib")) then + dofile(minetest.get_modpath("intllib").."/intllib.lua") + S = intllib.Getter(minetest.get_current_modname()) else S = function(s) return s end end -moreblocks.intllib = S +moreblocks.gettext = S local modpath = minetest.get_modpath("moreblocks") @@ -29,5 +27,6 @@ dofile(modpath .. "/crafting.lua") dofile(modpath .. "/aliases.lua") if minetest.setting_getbool("log_mods") then - minetest.log("action", S("[moreblocks] loaded.")) + print(S("[moreblocks] loaded.")) end + diff --git a/mods/moreblocks/locale/de.txt b/mods/moreblocks/locale/de.txt old mode 100644 new mode 100755 diff --git a/mods/moreblocks/locale/es.txt b/mods/moreblocks/locale/es.txt old mode 100644 new mode 100755 diff --git a/mods/moreblocks/locale/fr.txt b/mods/moreblocks/locale/fr.txt old mode 100644 new mode 100755 diff --git a/mods/moreblocks/locale/template.txt b/mods/moreblocks/locale/template.txt old mode 100644 new mode 100755 diff --git a/mods/moreblocks/models/moreblocks_slope.obj b/mods/moreblocks/models/moreblocks_slope.obj deleted file mode 100644 index 05c853b7..00000000 --- a/mods/moreblocks/models/moreblocks_slope.obj +++ /dev/null @@ -1,21 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_slope_onetexture.blend' -# www.blender.org -mtllib slope_test_slope_onetexture.mtl -o Cube_Cube.002 -v 0.500000 0.500000 0.500000 -v -0.500000 0.500000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v -0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 -0.500000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -usemtl None -s off -f 1/1 2/2 3/3 4/4 -f 4/3 3/4 5/1 6/2 -f 2/1 5/3 3/4 -f 1/2 4/3 6/4 -f 2/1 1/2 6/3 5/4 diff --git a/mods/moreblocks/models/moreblocks_slope_half.obj b/mods/moreblocks/models/moreblocks_slope_half.obj deleted file mode 100644 index bc96bb8b..00000000 --- a/mods/moreblocks/models/moreblocks_slope_half.obj +++ /dev/null @@ -1,23 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_slope_long_fronthalf_onetexture.blend' -# www.blender.org -mtllib slope_test_slope_long_fronthalf_onetexture.mtl -o Cube_Cube.002 -v 0.500000 -0.000000 0.500000 -v -0.500000 -0.000000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v -0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 -0.500000 -vt 1.000000 0.500000 -vt 0.000000 0.500000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -usemtl None -s off -f 1/1 2/2 3/3 4/4 -f 4/3 3/4 5/5 6/6 -f 2/1 5/3 3/4 -f 1/2 4/3 6/4 -f 2/5 1/6 6/3 5/4 diff --git a/mods/moreblocks/models/moreblocks_slope_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_half_raised.obj deleted file mode 100644 index 79e0dc01..00000000 --- a/mods/moreblocks/models/moreblocks_slope_half_raised.obj +++ /dev/null @@ -1,26 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_slope_long_backhalf_onetexture.blend' -# www.blender.org -mtllib slope_test_slope_long_backhalf_onetexture.mtl -o Cube -v -0.500000 -0.500000 0.500000 -v -0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 0.500000 -v -0.500000 0.500000 0.500000 -v -0.500000 0.000000 -0.500000 -v 0.500000 0.000000 -0.500000 -v 0.500000 0.500000 0.500000 -vt 1.000000 1.000000 -vt 0.000000 0.500000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 1.000000 0.500000 -vt 0.000000 1.000000 -usemtl None -s off -f 5/1 6/2 2/3 1/4 -f 6/5 7/2 3/3 2/4 -f 7/5 8/6 4/3 3/4 -f 8/1 5/6 1/3 4/4 -f 1/4 2/1 3/6 4/3 -f 8/6 7/3 6/4 5/1 diff --git a/mods/moreblocks/models/moreblocks_slope_inner.obj b/mods/moreblocks/models/moreblocks_slope_inner.obj deleted file mode 100644 index 68fc1700..00000000 --- a/mods/moreblocks/models/moreblocks_slope_inner.obj +++ /dev/null @@ -1,26 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_icorner_onetexture.blend' -# www.blender.org -o Cube_Cube.000 -v 0.500000 0.500000 0.500000 -v -0.500000 0.500000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v -0.500000 -0.500000 -0.500000 -v 0.500000 0.500000 -0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 -0.500000 -v -0.500000 -0.500000 -0.500000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -s off -f 6/1 1/2 7/3 8/4 -f 2/1 5/3 3/4 -f 2/1 1/2 5/4 -f 6/2 8/3 9/4 -f 9/1 8/2 7/3 3/4 -f 3/3 7/4 1/1 2/2 -f 1/1 6/2 9/3 -l 1 4 -l 3 4 diff --git a/mods/moreblocks/models/moreblocks_slope_inner_half.obj b/mods/moreblocks/models/moreblocks_slope_inner_half.obj deleted file mode 100644 index 6decaea3..00000000 --- a/mods/moreblocks/models/moreblocks_slope_inner_half.obj +++ /dev/null @@ -1,28 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_icorner_half_short_onetexture.blend' -# www.blender.org -mtllib slope_test_icorner_half_short_onetexture.mtl -o Cube_Cube.000 -v 0.500000 -0.000000 0.500000 -v -0.500000 -0.000000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v -0.500000 -0.500000 -0.500000 -v 0.500000 -0.000000 -0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 -0.500000 -v -0.500000 -0.500000 -0.500000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -usemtl None -s off -f 6/1 1/2 7/3 8/4 -f 2/1 5/3 3/4 -f 2/1 1/2 5/4 -f 6/2 8/3 9/4 -f 9/1 8/2 7/3 3/4 -f 3/3 7/4 1/1 2/2 -f 1/1 6/2 9/3 -l 1 4 -l 3 4 diff --git a/mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj deleted file mode 100644 index 8aff6cab..00000000 --- a/mods/moreblocks/models/moreblocks_slope_inner_half_raised.obj +++ /dev/null @@ -1,31 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_icorner_half_tall_onetexture.blend' -# www.blender.org -mtllib slope_test_icorner_half_tall_onetexture.mtl -o Cube_Cube.000 -v 0.500000 0.500000 0.500000 -v -0.500000 0.500000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v -0.500000 0.000000 -0.500000 -v 0.500000 0.500000 -0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 -0.500000 -v -0.500000 0.000000 -0.500000 -v -0.500000 -0.500000 -0.500000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 1.000000 0.500000 -vt 0.000000 0.500000 -usemtl None -s off -f 6/1 1/2 7/3 8/4 -f 2/1 1/2 5/4 -f 3/3 7/4 1/1 2/2 -f 1/2 6/3 9/4 -f 3/1 10/2 8/3 7/4 -f 8/3 10/4 5/5 6/2 -f 3/4 2/1 5/6 10/3 -l 1 4 -l 3 4 diff --git a/mods/moreblocks/models/moreblocks_slope_outer.obj b/mods/moreblocks/models/moreblocks_slope_outer.obj deleted file mode 100644 index 383c195f..00000000 --- a/mods/moreblocks/models/moreblocks_slope_outer.obj +++ /dev/null @@ -1,18 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_ocorner_onetexture.blend' -# www.blender.org -o Cube_Cube.002 -v 0.500000 0.500000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v -0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 -0.500000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -s off -f 3/1 2/2 4/3 5/4 -f 1/2 3/3 5/4 -f 1/1 2/3 3/4 -f 1/1 4/3 2/4 -f 1/2 5/3 4/4 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_cut.obj b/mods/moreblocks/models/moreblocks_slope_outer_cut.obj deleted file mode 100644 index 4608c69c..00000000 --- a/mods/moreblocks/models/moreblocks_slope_outer_cut.obj +++ /dev/null @@ -1,19 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_tall_2_onetexture.blend' -# www.blender.org -mtllib slope_test_corner_pyramid_tall_2_onetexture.mtl -o Cube -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 0.500000 0.500000 -vt 1.000000 1.000000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 0.000000 1.000000 -vt 0.500000 1.000000 -usemtl None -s off -f 4/1 1/2 3/3 -f 2/3 4/4 3/2 -f 3/2 1/3 2/4 -f 1/3 4/5 2/2 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj b/mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj deleted file mode 100644 index e4be8825..00000000 --- a/mods/moreblocks/models/moreblocks_slope_outer_cut_half.obj +++ /dev/null @@ -1,20 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_short_2_onetexture.blend' -# www.blender.org -mtllib slope_test_corner_pyramid_short_2_onetexture.mtl -o Cube -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 0.000000 0.500000 -vt 1.000000 0.500000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 0.000000 0.500000 -vt 0.000000 1.000000 -vt 0.500000 1.000000 -usemtl None -s off -f 4/1 1/2 3/3 -f 2/3 4/4 3/2 -f 3/2 1/3 2/5 -f 1/3 4/6 2/2 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj deleted file mode 100644 index 65a3b8ac..00000000 --- a/mods/moreblocks/models/moreblocks_slope_outer_cut_half_raised.obj +++ /dev/null @@ -1,23 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_short_3_onetexture.blend' -# www.blender.org -mtllib slope_test_corner_pyramid_short_3_onetexture.mtl -o Cube_Cube.002 -v -0.500000 -0.000000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 0.500000 0.500000 -v 0.500000 -0.500000 -0.500000 -v 0.500000 -0.000000 -0.500000 -vt 0.000000 0.500000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 1.000000 0.500000 -usemtl None -s off -f 1/1 2/2 3/3 4/4 -f 4/5 3/2 5/3 6/6 -f 2/5 5/3 3/4 -f 1/2 4/3 6/4 -f 2/3 1/6 6/1 5/2 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_half.obj b/mods/moreblocks/models/moreblocks_slope_outer_half.obj deleted file mode 100644 index 0c56e26a..00000000 --- a/mods/moreblocks/models/moreblocks_slope_outer_half.obj +++ /dev/null @@ -1,22 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_short_1_onetexture.blend' -# www.blender.org -mtllib slope_test_corner_pyramid_short_1_onetexture.mtl -o Cube -v -0.500000 -0.500000 0.500000 -v -0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 -0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 0.000000 0.500000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 1.000000 0.500000 -vt 0.000000 0.500000 -usemtl None -s off -f 1/1 2/2 3/3 4/4 -f 5/5 1/3 4/4 -f 3/4 5/6 4/3 -f 2/4 5/2 3/3 -f 1/4 5/1 2/3 diff --git a/mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj b/mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj deleted file mode 100644 index e4fa3d1f..00000000 --- a/mods/moreblocks/models/moreblocks_slope_outer_half_raised.obj +++ /dev/null @@ -1,27 +0,0 @@ -# Blender v2.69 (sub 0) OBJ File: 'slope_test_corner_pyramid_tall_3_onetexture.blend' -# www.blender.org -mtllib slope_test_corner_pyramid_tall_3_onetexture.mtl -o Cube_Cube.002 -v -0.500000 -0.000000 0.500000 -v -0.500000 -0.500000 0.500000 -v 0.500000 -0.500000 0.500000 -v 0.500000 0.500000 0.500000 -v 0.500000 -0.500000 -0.500000 -v 0.500000 -0.000000 -0.500000 -v -0.500000 -0.500000 -0.500000 -v -0.500000 -0.000000 -0.500000 -vt 0.000000 0.500000 -vt 0.000000 0.000000 -vt 1.000000 0.000000 -vt 1.000000 1.000000 -vt 0.000000 1.000000 -vt 1.000000 0.500000 -usemtl None -s off -f 1/1 2/2 3/3 4/4 -f 4/5 3/2 5/3 6/6 -f 8/3 4/5 6/2 -f 1/6 8/1 7/2 2/3 -f 4/5 8/3 1/4 -f 6/1 5/2 7/3 8/6 -f 5/5 3/2 2/3 7/4 diff --git a/mods/moreblocks/nodes.lua b/mods/moreblocks/nodes.lua old mode 100644 new mode 100755 index d3120c9a..5efda8f8 --- a/mods/moreblocks/nodes.lua +++ b/mods/moreblocks/nodes.lua @@ -1,11 +1,4 @@ ---[[ -More Blocks: node definitions - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = moreblocks.intllib +local S = moreblocks.gettext local sound_wood = default.node_sound_wood_defaults() local sound_stone = default.node_sound_stone_defaults() @@ -123,11 +116,6 @@ local nodes = { groups = {cracky = 2}, sounds = sound_stone, }, - ["cobble_compressed"] = { - description = S("Compressed Cobblestone"), - groups = {cracky = 1}, - sounds = sound_stone, - }, ["plankstone"] = { description = S("Plankstone"), groups = {cracky = 3}, diff --git a/mods/moreblocks/ownership.lua b/mods/moreblocks/ownership.lua old mode 100644 new mode 100755 index 1c2431ba..9cd4cb30 --- a/mods/moreblocks/ownership.lua +++ b/mods/moreblocks/ownership.lua @@ -1,9 +1,3 @@ ---[[ -More Blocks: ownership handling - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] local S = moreblocks.gettext diff --git a/mods/moreblocks/redefinitions.lua b/mods/moreblocks/redefinitions.lua old mode 100644 new mode 100755 index a6498f16..4db169b1 --- a/mods/moreblocks/redefinitions.lua +++ b/mods/moreblocks/redefinitions.lua @@ -1,10 +1,3 @@ ---[[ -More Blocks: redefinitions of default stuff - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -- Redefinitions of some default crafting recipes: minetest.register_craft({ @@ -78,11 +71,6 @@ minetest.override_item("default:papyrus", { sunlight_propagates = true, }) -minetest.override_item("default:fence_wood", { - paramtype = "light", - sunlight_propagates = true, -}) - minetest.override_item("default:junglegrass", { paramtype = "light", sunlight_propagates = true, diff --git a/mods/moreblocks/stairsplus/API.md b/mods/moreblocks/stairsplus/API.md old mode 100644 new mode 100755 index 2db0f2b3..a98ec81e --- a/mods/moreblocks/stairsplus/API.md +++ b/mods/moreblocks/stairsplus/API.md @@ -1,5 +1,6 @@ API documentation for Stairs+ -============================= +================================ +- - - - - - - - - - - - - - - - * `stairsplus:register_all(modname, subname, recipeitem, fields)` Registers a stair, slab, panel, microblock, and any other types of diff --git a/mods/moreblocks/stairsplus/aliases.lua b/mods/moreblocks/stairsplus/aliases.lua old mode 100644 new mode 100755 index c235d342..c92df483 --- a/mods/moreblocks/stairsplus/aliases.lua +++ b/mods/moreblocks/stairsplus/aliases.lua @@ -1,9 +1,3 @@ ---[[ -More Blocks: alias definitions - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] local function register_stairsplus_alias(modname, origname, newname) minetest.register_alias(modname.. ":slab_" ..origname, "moreblocks:slab_" ..newname) @@ -39,14 +33,12 @@ end register_stairsplus_alias("stairsplus", "stone", "stone") register_stairsplus_alias("stairsplus", "wood", "wood") -register_stairsplus_alias("stairsplus", "pinewood", "pinewood") register_stairsplus_alias("stairsplus", "cobble", "cobble") register_stairsplus_alias("stairsplus", "brick", "brick") register_stairsplus_alias("stairsplus", "sandstone", "sandstone") register_stairsplus_alias("stairsplus", "glass", "glass") register_stairsplus_alias("stairsplus", "tree", "tree") register_stairsplus_alias("stairsplus", "jungletree", "jungletree") -register_stairsplus_alias("stairsplus", "pinetree", "pinetree") register_stairsplus_alias("stairsplus", "desert_stone", "desert_stone") register_stairsplus_alias("stairsplus", "steelblock", "steelblock") register_stairsplus_alias("stairsplus", "mossycobble", "mossycobble") diff --git a/mods/moreblocks/stairsplus/conversion.lua b/mods/moreblocks/stairsplus/conversion.lua old mode 100644 new mode 100755 index 13966b66..fda30c7b --- a/mods/moreblocks/stairsplus/conversion.lua +++ b/mods/moreblocks/stairsplus/conversion.lua @@ -1,10 +1,3 @@ ---[[ -More Blocks: conversion - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -- Function to convert all stairs/slabs/etc nodes from -- inverted, wall, etc to regular + 6d facedir diff --git a/mods/moreblocks/stairsplus/init.lua b/mods/moreblocks/stairsplus/init.lua old mode 100644 new mode 100755 index ffec1b7f..ae09b7d3 --- a/mods/moreblocks/stairsplus/init.lua +++ b/mods/moreblocks/stairsplus/init.lua @@ -1,10 +1,3 @@ ---[[ -More Blocks: Stairs+ - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -- Nodes will be called :{stair,slab,panel,micro}_ local modpath = minetest.get_modpath("moreblocks").. "/stairsplus" @@ -25,7 +18,6 @@ function stairsplus:register_all(modname, subname, recipeitem, fields) end self:register_stair(modname, subname, recipeitem, fields) self:register_slab (modname, subname, recipeitem, fields) - self:register_slope(modname, subname, recipeitem, fields) self:register_panel(modname, subname, recipeitem, fields) self:register_micro(modname, subname, recipeitem, fields) -- self:register_6dfacedir_conversion(modname, subname) -- Not needed as of Q3 2013, uncomment to fix old maps. @@ -44,9 +36,8 @@ end -- dofile(modpath.. "/aliases.lua") -- Not needed as of Q2 2013, uncomment to fix old maps. -- dofile(modpath.. "/conversion.lua") -- Not needed as of Q2 2013, uncomment to fix old maps. -dofile(modpath .. "/stairs.lua") -dofile(modpath .. "/slabs.lua") -dofile(modpath .. "/slopes.lua") -dofile(modpath .. "/panels.lua") -dofile(modpath .. "/microblocks.lua") -dofile(modpath .. "/registrations.lua") +dofile(modpath.. "/stairs.lua") +dofile(modpath.. "/slabs.lua") +dofile(modpath.. "/panels.lua") +dofile(modpath.. "/microblocks.lua") +dofile(modpath.. "/registrations.lua") diff --git a/mods/moreblocks/stairsplus/microblocks.lua b/mods/moreblocks/stairsplus/microblocks.lua old mode 100644 new mode 100755 index 8d52c4a2..f88ed12e --- a/mods/moreblocks/stairsplus/microblocks.lua +++ b/mods/moreblocks/stairsplus/microblocks.lua @@ -1,11 +1,10 @@ ---[[ -More Blocks: microblock definitions - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = moreblocks.intllib +local S -- Load translation library if intllib is installed: +if (minetest.get_modpath("intllib")) then + dofile(minetest.get_modpath("intllib").."/intllib.lua") + S = intllib.Getter(minetest.get_current_modname()) +else + S = function(s) return s end +end -- Node will be called :micro_ diff --git a/mods/moreblocks/stairsplus/panels.lua b/mods/moreblocks/stairsplus/panels.lua old mode 100644 new mode 100755 index 2220fe42..73b283ed --- a/mods/moreblocks/stairsplus/panels.lua +++ b/mods/moreblocks/stairsplus/panels.lua @@ -1,11 +1,10 @@ ---[[ -More Blocks: panel definitions - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = moreblocks.intllib +local S -- Load translation library if intllib is installed: +if (minetest.get_modpath("intllib")) then + dofile(minetest.get_modpath("intllib").."/intllib.lua") + S = intllib.Getter(minetest.get_current_modname()) +else + S = function(s) return s end +end -- Node will be called :panel_ diff --git a/mods/moreblocks/stairsplus/registrations.lua b/mods/moreblocks/stairsplus/registrations.lua old mode 100644 new mode 100755 index 7b38b13b..cc22d333 --- a/mods/moreblocks/stairsplus/registrations.lua +++ b/mods/moreblocks/stairsplus/registrations.lua @@ -1,10 +1,3 @@ ---[[ -More Blocks: registrations - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - local default_nodes = { -- Default stairs/slabs/panels/microblocks: "stone", "cobble", @@ -17,14 +10,12 @@ local default_nodes = { -- Default stairs/slabs/panels/microblocks: "bronzeblock", "diamondblock", "desert_stone", - "desert_cobble", +-- "desert_cobble", "glass", "tree", "wood", "jungletree", "junglewood", - "pinetree", - "pinewood", "obsidian", "obsidian_glass", "stonebrick", diff --git a/mods/moreblocks/stairsplus/slabs.lua b/mods/moreblocks/stairsplus/slabs.lua old mode 100644 new mode 100755 index 68ba5200..9c31745d --- a/mods/moreblocks/stairsplus/slabs.lua +++ b/mods/moreblocks/stairsplus/slabs.lua @@ -1,11 +1,10 @@ ---[[ -More Blocks: slab definitions - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = moreblocks.intllib +local S -- Load translation library if intllib is installed: +if (minetest.get_modpath("intllib")) then + dofile(minetest.get_modpath("intllib").."/intllib.lua") + S = intllib.Getter(minetest.get_current_modname()) +else + S = function(s) return s end +end -- Node will be called :slab_ @@ -76,11 +75,11 @@ function stairsplus:register_slab(modname, subname, recipeitem, fields) end def.description = desc if fields.drop then - def.drop = modname.. ":slab_" .. fields.drop .. alternate + def.drop = modname.. ":slab_" ..fields.drop..alternate end - minetest.register_node(":" .. modname .. ":slab_" .. subname .. alternate, def) + minetest.register_node(":" ..modname.. ":slab_" ..subname..alternate, def) end - minetest.register_alias("stairs:slab_" .. subname, modname .. ":slab_" .. subname) + minetest.register_alias("stairs:slab_" ..subname, modname.. ":slab_" ..subname) -- Some saw-less recipes: diff --git a/mods/moreblocks/stairsplus/slopes.lua b/mods/moreblocks/stairsplus/slopes.lua deleted file mode 100644 index 3a169060..00000000 --- a/mods/moreblocks/stairsplus/slopes.lua +++ /dev/null @@ -1,459 +0,0 @@ ---[[ -More Blocks: slope definitions - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = moreblocks.intllib - -local box_slope = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, -0.25, 0.5}, - {-0.5, -0.25, -0.25, 0.5, 0, 0.5}, - {-0.5, 0, 0, 0.5, 0.25, 0.5}, - {-0.5, 0.25, 0.25, 0.5, 0.5, 0.5} - } -} - -local box_slope_half = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, - {-0.5, -0.375, -0.25, 0.5, -0.25, 0.5}, - {-0.5, -0.25, 0, 0.5, -0.125, 0.5}, - {-0.5, -0.125, 0.25, 0.5, 0, 0.5}, - } -} - -local box_slope_half_raised = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, 0.125, 0.5}, - {-0.5, 0.125, -0.25, 0.5, 0.25, 0.5}, - {-0.5, 0.25, 0, 0.5, 0.375, 0.5}, - {-0.5, 0.375, 0.25, 0.5, 0.5, 0.5}, - } -} - ---============================================================== - -local box_slope_inner = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, -0.25, 0.5}, - {-0.5, -0.5, -0.25, 0.5, 0, 0.5}, - {-0.5, -0.5, -0.5, 0.25, 0, 0.5}, - {-0.5, 0, -0.5, 0, 0.25, 0.5}, - {-0.5, 0, 0, 0.5, 0.25, 0.5}, - {-0.5, 0.25, 0.25, 0.5, 0.5, 0.5}, - {-0.5, 0.25, -0.5, -0.25, 0.5, 0.5}, - } -} - -local box_slope_inner_half = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, - {-0.5, -0.375, -0.25, 0.5, -0.25, 0.5}, - {-0.5, -0.375, -0.5, 0.25, -0.25, 0.5}, - {-0.5, -0.25, -0.5, 0, -0.125, 0.5}, - {-0.5, -0.25, 0, 0.5, -0.125, 0.5}, - {-0.5, -0.125, 0.25, 0.5, 0, 0.5}, - {-0.5, -0.125, -0.5, -0.25, 0, 0.5}, - } -} - -local box_slope_inner_half_raised = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, 0.125, 0.5}, - {-0.5, 0.125, -0.25, 0.5, 0.25, 0.5}, - {-0.5, 0.125, -0.5, 0.25, 0.25, 0.5}, - {-0.5, 0.25, -0.5, 0, 0.375, 0.5}, - {-0.5, 0.25, 0, 0.5, 0.375, 0.5}, - {-0.5, 0.375, 0.25, 0.5, 0.5, 0.5}, - {-0.5, 0.375, -0.5, -0.25, 0.5, 0.5}, - } -} - ---============================================================== - -local box_slope_outer = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, -0.25, 0.5}, - {-0.5, -0.25, -0.25, 0.25, 0, 0.5}, - {-0.5, 0, 0, 0, 0.25, 0.5}, - {-0.5, 0.25, 0.25, -0.25, 0.5, 0.5} - } -} - -local box_slope_outer_half = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, - {-0.5, -0.375, -0.25, 0.25, -0.25, 0.5}, - {-0.5, -0.25, 0, 0, -0.125, 0.5}, - {-0.5, -0.125, 0.25, -0.25, 0, 0.5} - } -} - -local box_slope_outer_half_raised = { - type = "fixed", - fixed = { - {-0.5, -0.5, -0.5, 0.5, 0.125, 0.5}, - {-0.5, 0.125, -0.25, 0.25, 0.25, 0.5}, - {-0.5, 0.25, 0, 0, 0.375, 0.5}, - {-0.5, 0.375, 0.25, -0.25, 0.5, 0.5} - } -} - --- Node will be called :slope_ - -function register_slope(modname, subname, recipeitem, groups, images, description, drop, light) - return stairsplus:register_slope(modname, subname, recipeitem, { - groups = groups, - tiles = images, - description = description, - drop = drop, - light_source = light, - sounds = default.node_sound_stone_defaults(), - }) -end - -function stairsplus:register_slope(modname, subname, recipeitem, fields) - local defs = { - [""] = { - mesh = "moreblocks_slope.obj", - collision_box = box_slope, - selection_box = box_slope, - - }, - ["_half"] = { - mesh = "moreblocks_slope_half.obj", - collision_box = box_slope_half, - selection_box = box_slope_half, - }, - ["_half_raised"] = { - mesh = "moreblocks_slope_half_raised.obj", - collision_box = box_slope_half_raised, - selection_box = box_slope_half_raised, - }, - ---============================================================== - - ["_inner"] = { - mesh = "moreblocks_slope_inner.obj", - collision_box = box_slope_inner, - selection_box = box_slope_inner, - }, - ["_inner_half"] = { - mesh = "moreblocks_slope_inner_half.obj", - collision_box = box_slope_inner_half, - selection_box = box_slope_inner_half, - }, - ["_inner_half_raised"] = { - mesh = "moreblocks_slope_inner_half_raised.obj", - collision_box = box_slope_inner_half_raised, - selection_box = box_slope_inner_half_raised, - }, - ---============================================================== - - ["_outer"] = { - mesh = "moreblocks_slope_outer.obj", - collision_box = box_slope_outer, - selection_box = box_slope_outer, - }, - ["_outer_half"] = { - mesh = "moreblocks_slope_outer_half.obj", - collision_box = box_slope_outer_half, - selection_box = box_slope_outer_half, - }, - ["_outer_half_raised"] = { - mesh = "moreblocks_slope_outer_half_raised.obj", - collision_box = box_slope_outer_half_raised, - selection_box = box_slope_outer_half_raised, - }, - ---============================================================== - - ["_outer_cut"] = { - mesh = "moreblocks_slope_outer_cut.obj", - collision_box = box_slope_outer, - selection_box = box_slope_outer, - }, - ["_outer_cut_half"] = { - mesh = "moreblocks_slope_outer_cut_half.obj", - collision_box = box_slope_outer_half, - selection_box = box_slope_outer_half, - }, - ["_outer_cut_half_raised"] = { - mesh = "moreblocks_slope_outer_cut_half_raised.obj", - collision_box = box_slope_outer_half_raised, - selection_box = box_slope_outer_half_raised, - }, - } - - local desc = S("%s Slope"):format(fields.description) - for alternate, def in pairs(defs) do - def.drawtype = "mesh" - def.paramtype = "light" - def.paramtype2 = "facedir" - def.on_place = minetest.rotate_node - for k, v in pairs(fields) do - def[k] = v - end - def.description = desc - if fields.drop then - def.drop = modname.. ":slope_" ..fields.drop..alternate - end - minetest.register_node(":" ..modname.. ":slope_" ..subname..alternate, def) - end - - -- Some saw-less recipes: - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. " 7", - recipe = { - {modname .. ":panel_" .. subname, "", ""}, - {recipeitem, modname .. ":panel_" .. subname, ""}, - {recipeitem, recipeitem, modname .. ":panel_" .. subname}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. " 7", - recipe = { - {"", "", modname .. ":panel_" .. subname}, - {"", modname .. ":panel_" .. subname, recipeitem}, - {modname .. ":panel_" .. subname, recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_half 10", - recipe = { - {modname .. ":panel_" .. subname, "", ""}, - {recipeitem, recipeitem, modname .. ":panel_" .. subname}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_half 10", - recipe = { - {"", "", modname .. ":panel_" .. subname}, - {modname .. ":panel_" .. subname, recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_half_raised 7", - recipe = { - {modname .. ":panel_" .. subname, "", ""}, - {recipeitem, recipeitem, modname .. ":panel_" .. subname}, - {recipeitem, recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_half_raised 7", - recipe = { - {"", "", modname .. ":panel_" .. subname}, - {modname .. ":panel_" .. subname, recipeitem, recipeitem}, - {recipeitem, recipeitem, recipeitem}, - }, - }) - ---===================================================== Inner == - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_inner 7", - recipe = { - {modname .. ":stair_" .. subname .. "_half", "", ""}, - {recipeitem, modname .. ":stair_" .. subname .. "_half", ""}, - {recipeitem, recipeitem, modname .. ":stair_" .. subname .. "_half"}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_inner 7", - recipe = { - {"", "", modname .. ":stair_" .. subname .. "_half"}, - {"", modname .. ":stair_" .. subname .. "_half", recipeitem}, - {modname .. ":stair_" .. subname .. "_half", recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_inner_half 10", - recipe = { - {modname .. ":stair_" .. subname .. "_half", "", ""}, - {recipeitem, recipeitem, modname .. ":stair_" .. subname .. "_half"}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_inner_half 10", - recipe = { - {"", "", modname .. ":stair_" .. subname .. "_half"}, - {modname .. ":stair_" .. subname .. "_half", recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_inner_half_raised 7", - recipe = { - {modname .. ":stair_" .. subname .. "_half", "", ""}, - {recipeitem, recipeitem, modname .. ":stair_" .. subname .. "_half"}, - {recipeitem, recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_inner_half_raised 7", - recipe = { - {"", "", modname .. ":stair_" .. subname .. "_half"}, - {modname .. ":stair_" .. subname .. "_half", recipeitem, recipeitem}, - {recipeitem, recipeitem, recipeitem}, - }, - }) - ---===================================================== Outer == - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_outer 7", - recipe = { - {modname .. ":micro_" .. subname, "", ""}, - {recipeitem, modname .. ":micro_" .. subname, ""}, - {recipeitem, recipeitem, modname .. ":micro_" .. subname}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_outer 7", - recipe = { - {"", "", modname .. ":micro_" .. subname}, - {"", modname .. ":micro_" .. subname, recipeitem}, - {modname .. ":micro_" .. subname, recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_outer_half 10", - recipe = { - {modname .. ":micro_" .. subname, "", ""}, - {recipeitem, recipeitem, modname .. ":micro_" .. subname}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_outer_half 10", - recipe = { - {"", "", modname .. ":micro_" .. subname}, - {modname .. ":micro_" .. subname, recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_outer_half_raised 7", - recipe = { - {modname .. ":micro_" .. subname, "", ""}, - {recipeitem, recipeitem, modname .. ":micro_" .. subname}, - {recipeitem, recipeitem, recipeitem}, - }, - }) - - minetest.register_craft({ - output = modname .. ":slope_" .. subname .. "_outer_half_raised 7", - recipe = { - {"", "", modname .. ":micro_" .. subname}, - {modname .. ":micro_" .. subname, recipeitem, recipeitem}, - {recipeitem, recipeitem, recipeitem}, - }, - }) - ---================================================= Shapeless == - - minetest.register_craft({ - type = "shapeless", - output = recipeitem, - recipe = {modname .. ":slope_" .. subname, modname .. ":slope_" .. subname}, - }) - - minetest.register_craft({ - type = "shapeless", - output = recipeitem, - recipe = {modname .. ":slope_" .. subname .. "_outer_cut", modname .. ":slope_" .. subname .. "_outer_cut"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = recipeitem, - recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half_raised"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = recipeitem, - recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half", - modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slab_" .. subname, - recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_half_raised", - recipe = {modname .. ":slope_" .. subname .. "_half", modname .. ":slope_" .. subname .. "_half", - modname .. ":slope_" .. subname .. "_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_half_raised", - recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_inner_half_raised", - recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_inner_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_outer_half_raised", - recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_outer_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_outer_cut_half_raised", - recipe = {modname .. ":slab_" .. subname, modname .. ":slope_" .. subname .. "_outer_cut_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_outer_cut", - recipe = {modname .. ":slope_" .. subname .. "_outer"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_outer_cut_half", - recipe = {modname .. ":slope_" .. subname .. "_outer_half"}, - }) - - minetest.register_craft({ - type = "shapeless", - output = modname .. ":slope_" .. subname .. "_outer_cut_half_raised", - recipe = {modname .. ":slope_" .. subname .. "_outer_half_raised"}, - }) -end diff --git a/mods/moreblocks/stairsplus/stairs.lua b/mods/moreblocks/stairsplus/stairs.lua old mode 100644 new mode 100755 index a93cda08..a4f54e39 --- a/mods/moreblocks/stairsplus/stairs.lua +++ b/mods/moreblocks/stairsplus/stairs.lua @@ -1,11 +1,10 @@ ---[[ -More Blocks: stair definitions - -Copyright (c) 2011-2015 Calinou and contributors. -Licensed under the zlib license. See LICENSE.md for more information. ---]] - -local S = moreblocks.intllib +local S -- Load translation library if intllib is installed: +if (minetest.get_modpath("intllib")) then + dofile(minetest.get_modpath("intllib").."/intllib.lua") + S = intllib.Getter(minetest.get_current_modname()) +else + S = function(s) return s end +end -- Node will be called :stair_ @@ -117,11 +116,11 @@ function stairsplus:register_stair(modname, subname, recipeitem, fields) end def.description = desc if fields.drop then - def.drop = modname .. ":stair_" .. fields.drop .. alternate + def.drop = modname.. ":stair_" ..fields.drop..alternate end - minetest.register_node(":" .. modname .. ":stair_" .. subname .. alternate, def) + minetest.register_node(":" ..modname.. ":stair_" ..subname..alternate, def) end - minetest.register_alias("stairs:stair_" .. subname, modname .. ":stair_" .. subname) + minetest.register_alias(":stairs:stair_" ..subname, modname.. ":stair_" ..subname) -- Some saw-less recipes: diff --git a/mods/moreblocks/textures/default_brick.png b/mods/moreblocks/textures/default_brick.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/default_fence_overlay.png b/mods/moreblocks/textures/default_fence_overlay.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/invisible.png b/mods/moreblocks/textures/invisible.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_cactus_brick.png b/mods/moreblocks/textures/moreblocks_cactus_brick.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_cactus_checker.png b/mods/moreblocks/textures/moreblocks_cactus_checker.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_circle_stone_bricks.png b/mods/moreblocks/textures/moreblocks_circle_stone_bricks.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_circular_saw_bottom.png b/mods/moreblocks/textures/moreblocks_circular_saw_bottom.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_circular_saw_side.png b/mods/moreblocks/textures/moreblocks_circular_saw_side.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_circular_saw_top.png b/mods/moreblocks/textures/moreblocks_circular_saw_top.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_clean_glass.png b/mods/moreblocks/textures/moreblocks_clean_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_coal_checker.png b/mods/moreblocks/textures/moreblocks_coal_checker.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_coal_glass.png b/mods/moreblocks/textures/moreblocks_coal_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_coal_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_coal_glass_stairsplus.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_coal_stone.png b/mods/moreblocks/textures/moreblocks_coal_stone.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_coal_stone_bricks.png b/mods/moreblocks/textures/moreblocks_coal_stone_bricks.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_empty_bookshelf.png b/mods/moreblocks/textures/moreblocks_empty_bookshelf.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_fence_jungle_wood.png b/mods/moreblocks/textures/moreblocks_fence_jungle_wood.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_fence_wood.png b/mods/moreblocks/textures/moreblocks_fence_wood.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_glass.png b/mods/moreblocks/textures/moreblocks_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_glass_stairsplus.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_glow_glass.png b/mods/moreblocks/textures/moreblocks_glow_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_glow_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_glow_glass_stairsplus.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_grey_bricks.png b/mods/moreblocks/textures/moreblocks_grey_bricks.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_iron_checker.png b/mods/moreblocks/textures/moreblocks_iron_checker.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_iron_glass.png b/mods/moreblocks/textures/moreblocks_iron_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_iron_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_iron_glass_stairsplus.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_iron_stone.png b/mods/moreblocks/textures/moreblocks_iron_stone.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_iron_stone_bricks.png b/mods/moreblocks/textures/moreblocks_iron_stone_bricks.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_junglestick.png b/mods/moreblocks/textures/moreblocks_junglestick.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_obsidian_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_obsidian_glass_stairsplus.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_plankstone.png b/mods/moreblocks/textures/moreblocks_plankstone.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_plankstone_2.png b/mods/moreblocks/textures/moreblocks_plankstone_2.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_rope.png b/mods/moreblocks/textures/moreblocks_rope.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_split_stone_tile.png b/mods/moreblocks/textures/moreblocks_split_stone_tile.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_split_stone_tile_alt.png b/mods/moreblocks/textures/moreblocks_split_stone_tile_alt.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_split_stone_tile_top.png b/mods/moreblocks/textures/moreblocks_split_stone_tile_top.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_stone_tile.png b/mods/moreblocks/textures/moreblocks_stone_tile.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_super_glow_glass.png b/mods/moreblocks/textures/moreblocks_super_glow_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_super_glow_glass_stairsplus.png b/mods/moreblocks/textures/moreblocks_super_glow_glass_stairsplus.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_sweeper.png b/mods/moreblocks/textures/moreblocks_sweeper.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_tar.png b/mods/moreblocks/textures/moreblocks_tar.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_trap_glass.png b/mods/moreblocks/textures/moreblocks_trap_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_trap_glow_glass.png b/mods/moreblocks/textures/moreblocks_trap_glow_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_trap_stone.png b/mods/moreblocks/textures/moreblocks_trap_stone.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_trap_super_glow_glass.png b/mods/moreblocks/textures/moreblocks_trap_super_glow_glass.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_tree_stairsplus.png b/mods/moreblocks/textures/moreblocks_tree_stairsplus.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile.png b/mods/moreblocks/textures/moreblocks_wood_tile.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile_center.png b/mods/moreblocks/textures/moreblocks_wood_tile_center.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile_full.png b/mods/moreblocks/textures/moreblocks_wood_tile_full.png old mode 100644 new mode 100755 diff --git a/mods/moreblocks/textures/moreblocks_wood_tile_up.png b/mods/moreblocks/textures/moreblocks_wood_tile_up.png old mode 100644 new mode 100755 From a2591f025c138c8fee55e602c6c507760446975a Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 21:08:54 +0100 Subject: [PATCH 12/15] Removed global variables' errors file --- global_to_solve.txt | 82 --------------------------------------------- 1 file changed, 82 deletions(-) delete mode 100644 global_to_solve.txt diff --git a/global_to_solve.txt b/global_to_solve.txt deleted file mode 100644 index e1386f70..00000000 --- a/global_to_solve.txt +++ /dev/null @@ -1,82 +0,0 @@ -14:41:30: WARNING: Undeclared global variable "intllib" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/awards/init.lua:8 -14:41:30: WARNING: Undeclared global variable "worldedit" accessed at ...eFun/worldmods/WorldEdit/worldedit_infinity/init.lua:1 -14:41:30: WARNING: Undeclared global variable "check_set" accessed at ...eFun/worldmods/WorldEdit/worldedit_commands/init.lua:830 -14:41:30: WARNING: Undeclared global variable "check_set" accessed at ...eFun/worldmods/WorldEdit/worldedit_commands/init.lua:841 -14:41:30: WARNING: Undeclared global variable "intllib" accessed at .../NodesJustWannaHaveFun/worldmods/moreblocks/init.lua:11 -14:41:30: WARNING: Undeclared global variable "intllib" accessed at ...naHaveFun/worldmods/moreblocks/stairsplus/stairs.lua:2 -14:41:30: WARNING: Undeclared global variable "intllib" accessed at ...nnaHaveFun/worldmods/moreblocks/stairsplus/slabs.lua:2 -14:41:30: WARNING: Undeclared global variable "intllib" accessed at ...naHaveFun/worldmods/moreblocks/stairsplus/panels.lua:2 -14:41:30: WARNING: Undeclared global variable "intllib" accessed at ...eFun/worldmods/moreblocks/stairsplus/microblocks.lua:2 -14:41:30: ERROR[main]: Assignment to undeclared global "v" inside a function at ...ds/NodesJustWannaHaveFun/worldmods/snow/src/util.lua:51. -14:41:30: ERROR[main]: Assignment to undeclared global "i" inside a function at ...ds/NodesJustWannaHaveFun/worldmods/snow/src/util.lua:51. -14:41:30: WARNING: Undeclared global variable "skins" accessed at ...s/NodesJustWannaHaveFun/worldmods/snow/src/nodes.lua:69 -14:41:30: WARNING: Undeclared global variable "HUD" accessed at ...ds/NodesJustWannaHaveFun/worldmods/snow/src/sled.lua:71 -14:41:30: WARNING: Undeclared global variable "drop" accessed at ...esJustWannaHaveFun/worldmods/snow/src/stairsplus.lua:276 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:15 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:25 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:35 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:46 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:57 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:78 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:88 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:98 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:108 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:121 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:133 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:143 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:153 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:166 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:176 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:186 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:196 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:206 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:216 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:226 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:237 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:249 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:270 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:281 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:291 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:301 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:311 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:322 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:332 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:342 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:352 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:362 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:374 -14:41:30: WARNING: Undeclared global variable "maptools_creative" accessed at ...ustWannaHaveFun/worldmods/maptools/default_nodes.lua:384 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:109 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:141 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:169 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:197 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:225 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:253 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:282 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:310 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:338 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:366 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:394 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:422 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:450 -14:41:30: WARNING: Undeclared global variable "x21" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:451 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:478 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:506 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:534 -14:41:30: WARNING: Undeclared global variable "p3" accessed at ...rlds/NodesJustWannaHaveFun/worldmods/fences/init.lua:661 -14:41:30: WARNING: Undeclared global variable "convert_base" accessed at ...ustWannaHaveFun/worldmods/mesecons/mesecons/util.lua:104 -14:41:31: WARNING: Undeclared global variable "handle_timer" accessed at ...n/worldmods/mesecons/mesecons_luacontroller/init.lua:562 -14:41:31: WARNING: Undeclared global variable "selectionbox" accessed at ...n/worldmods/mesecons/mesecons_luacontroller/init.lua:603 -14:41:31: WARNING: Undeclared global variable "cp" accessed at ...dmods/homedecor_modpack/fake_fire/modfiles/nodes.lua:36 -14:41:31: WARNING: Undeclared global variable "cp" accessed at ...dmods/homedecor_modpack/fake_fire/modfiles/nodes.lua:82 -14:41:31: WARNING: Undeclared global variable "cp" accessed at ...dmods/homedecor_modpack/fake_fire/modfiles/nodes.lua:128 -14:41:31: WARNING: Undeclared global variable "cp" accessed at ...dmods/homedecor_modpack/fake_fire/modfiles/nodes.lua:174 -14:41:31: WARNING: Undeclared global variable "cp" accessed at ...dmods/homedecor_modpack/fake_fire/modfiles/nodes.lua:356 -14:41:31: WARNING: Undeclared global variable "intllib" accessed at ...JustWannaHaveFun/worldmods/unified_inventory/api.lua:2 -14:41:31: WARNING: Undeclared global variable "intllib" accessed at ...annaHaveFun/worldmods/unified_inventory/internal.lua:2 -14:41:31: WARNING: Undeclared global variable "intllib" accessed at ...annaHaveFun/worldmods/unified_inventory/register.lua:2 -14:41:31: WARNING: Undeclared global variable "intllib" accessed at ...ustWannaHaveFun/worldmods/unified_inventory/bags.lua:7 -14:41:31: WARNING: Undeclared global variable "inventory_plus" accessed at ...stWannaHaveFun/worldmods/3d_armor/3d_armor/armor.lua:40 -14:41:31: WARNING: Undeclared global variable "intllib" accessed at .../worlds/NodesJustWannaHaveFun/worldmods/food/api.lua:11 -14:41:31: ERROR[main]: Assignment to undeclared global "mod" inside a function at .../worlds/NodesJustWannaHaveFun/worldmods/food/api.lua:44. -14:41:31: ERROR[main]: Assignment to undeclared global "g" inside a function at .../worlds/NodesJustWannaHaveFun/worldmods/food/api.lua:63. From ae4295babc17d810682927222be4d39096b58529 Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 21:16:00 +0100 Subject: [PATCH 13/15] Made superapples harder to craft - Changed craft recipe for default:superapple, now using : "default:apple","default:mese","default:mese" --- minetestforfun_game/mods/default/crafting.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/minetestforfun_game/mods/default/crafting.lua b/minetestforfun_game/mods/default/crafting.lua index d6e4081f..84a7232d 100644 --- a/minetestforfun_game/mods/default/crafting.lua +++ b/minetestforfun_game/mods/default/crafting.lua @@ -630,7 +630,7 @@ minetest.register_craft({ minetest.register_craft({ output = "maptools:superapple", type = "shapeless", - recipe = {"default:apple", "default:mese_crystal_fragment", "default:mese_crystal_fragment"}, + recipe = {"default:apple", "default:mese", "default:mese"}, }) minetest.register_craft({ From 42885ee458b0a1613ced21068f52e0125f7071ef Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 22:45:27 +0100 Subject: [PATCH 14/15] More global vars --- mods/ambience_modpack/ambience/init.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mods/ambience_modpack/ambience/init.lua b/mods/ambience_modpack/ambience/init.lua index 3a14d97d..64545c8a 100755 --- a/mods/ambience_modpack/ambience/init.lua +++ b/mods/ambience_modpack/ambience/init.lua @@ -252,14 +252,14 @@ end local atleast_nodes_in_grid = function(pos, search_distance, height, node_name, threshold) counter = counter +1 -- minetest.chat_send_all("counter: (" .. counter .. ")") - minp = {x=pos.x-search_distance,y=height, z=pos.z+20} - maxp = {x=pos.x+search_distance,y=height, z=pos.z+20} - nodes = minetest.find_nodes_in_area(minp, maxp, node_name) + local minp = {x=pos.x-search_distance,y=height, z=pos.z+20} + local maxp = {x=pos.x+search_distance,y=height, z=pos.z+20} + local nodes = minetest.find_nodes_in_area(minp, maxp, node_name) -- minetest.chat_send_all("z+Found (" .. node_name .. ": " .. #nodes .. ")") if #nodes >= threshold then return true end - totalnodes = #nodes + local totalnodes = #nodes minp = {x=pos.x-search_distance,y=height, z=pos.z-20} maxp = {x=pos.x+search_distance,y=height, z=pos.z-20} nodes = minetest.find_nodes_in_area(minp, maxp, node_name) From c75b3780ca02e234843356be9d45192d95c35fb6 Mon Sep 17 00:00:00 2001 From: LeMagnesium Date: Thu, 15 Jan 2015 23:27:03 +0100 Subject: [PATCH 15/15] Loads of fixs --- mods/builtin_falling/func.lua | 2 +- mods/sea/clams/init.lua | 2 +- mods/snow/src/mapgen_v6.lua | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/mods/builtin_falling/func.lua b/mods/builtin_falling/func.lua index 5d2a714e..32b0b80e 100755 --- a/mods/builtin_falling/func.lua +++ b/mods/builtin_falling/func.lua @@ -169,7 +169,7 @@ function add_protected_bukket_liquid(nameofbukket,liquidsourcename) return end -- Check if pointing to a buildable node - n = minetest.get_node(pointed_thing.under) + local n = minetest.get_node(pointed_thing.under) if is_protected_area(pointed_thing.under, 7 ,user:get_player_name()) then minetest.chat_send_player(user:get_player_name(),"You cant place here - Too short of a protected area.") diff --git a/mods/sea/clams/init.lua b/mods/sea/clams/init.lua index d9e6a13d..c6f88f75 100755 --- a/mods/sea/clams/init.lua +++ b/mods/sea/clams/init.lua @@ -127,7 +127,7 @@ minetest.register_entity("clams:whiteshell", { self.phase = 0 end self.object:setsprite({x=0, y=self.phase}) - phasearmor = { + local phasearmor = { [0]={fleshy=0}, [1]={fleshy=30}, [2]={fleshy=70} diff --git a/mods/snow/src/mapgen_v6.lua b/mods/snow/src/mapgen_v6.lua index 414fddc2..9f9453ed 100755 --- a/mods/snow/src/mapgen_v6.lua +++ b/mods/snow/src/mapgen_v6.lua @@ -106,7 +106,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local plain = biome == 2 -- spawns not much local alpine = biome == 3 -- rocky terrain -- Water biomes - biome2 = pr:next(1, 5) + local biome2 = pr:next(1, 5) local cool = biome == 1 -- only spawns ice on edge of water local icebergs = biome == 2 local icesheet = biome == 3