diff --git a/.stignore b/.stignore index 6b8710a..3978a0f 100644 --- a/.stignore +++ b/.stignore @@ -1 +1,2 @@ .git +.gitignore diff --git a/mods/anvils/description.txt b/mods/anvils/description.txt deleted file mode 100644 index bd94ba5..0000000 --- a/mods/anvils/description.txt +++ /dev/null @@ -1,5 +0,0 @@ -Mod provide anvil that can repair tools (like at MC) - -Created by Wuzzy - -Adapted by JonyQ and Jozet \ No newline at end of file diff --git a/mods/anvils/mod.conf b/mods/anvils/mod.conf index 11c80d3..ec2751c 100644 --- a/mods/anvils/mod.conf +++ b/mods/anvils/mod.conf @@ -1,3 +1,4 @@ name = anvils depends = default, farming optional_depends = screwdriver +description = Mod provide anvil that can repair tools (like at MC) diff --git a/mods/creative/depends.txt b/mods/creative/depends.txt deleted file mode 100644 index 975e652..0000000 --- a/mods/creative/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default -sfinv diff --git a/mods/creative/mod.conf b/mods/creative/mod.conf new file mode 100644 index 0000000..9be50a7 --- /dev/null +++ b/mods/creative/mod.conf @@ -0,0 +1,2 @@ +name = creative +depends = default, sfinv diff --git a/mods/default/torch.lua b/mods/default/torch.lua index c06dee8..6b365c3 100644 --- a/mods/default/torch.lua +++ b/mods/default/torch.lua @@ -29,6 +29,7 @@ minetest.register_node("default:torch", { name = "default_torch_on_floor_animated.png", animation = {type = "vertical_frames", aspect_w = 16, aspect_h = 16, length = 3.3} }}, + use_texture_alpha = 'clip', paramtype = "light", paramtype2 = "wallmounted", sunlight_propagates = true, @@ -81,6 +82,7 @@ minetest.register_node("default:torch_wall", { name = "default_torch_on_floor_animated.png", animation = {type = "vertical_frames", aspect_w = 16, aspect_h = 16, length = 3.3} }}, + use_texture_alpha = 'clip', paramtype = "light", paramtype2 = "wallmounted", sunlight_propagates = true, @@ -105,6 +107,7 @@ minetest.register_node("default:torch_ceiling", { name = "default_torch_on_floor_animated.png", animation = {type = "vertical_frames", aspect_w = 16, aspect_h = 16, length = 3.3} }}, + use_texture_alpha = 'clip', paramtype = "light", paramtype2 = "wallmounted", sunlight_propagates = true, diff --git a/mods/doc_modpack/doc/depends.txt b/mods/doc_modpack/doc/depends.txt deleted file mode 100644 index c6040df..0000000 --- a/mods/doc_modpack/doc/depends.txt +++ /dev/null @@ -1,4 +0,0 @@ -intllib? -unified_inventory? -sfinv_buttons? -central_message? diff --git a/mods/doc_modpack/doc/description.txt b/mods/doc_modpack/doc/description.txt deleted file mode 100644 index 808a218..0000000 --- a/mods/doc_modpack/doc/description.txt +++ /dev/null @@ -1 +0,0 @@ -A simple in-game documentation system which enables mods to add help entries based on templates. diff --git a/mods/doc_modpack/doc/mod.conf b/mods/doc_modpack/doc/mod.conf index 5e2f430..41caf68 100644 --- a/mods/doc_modpack/doc/mod.conf +++ b/mods/doc_modpack/doc/mod.conf @@ -1 +1,3 @@ name = doc +optional_depends = intllib, unified_inventory, sfinv_buttons, central_message +description = A simple in-game documentation system which enables mods to add help entries based on templates. diff --git a/mods/doc_modpack/doc_basics/depends.txt b/mods/doc_modpack/doc_basics/depends.txt deleted file mode 100644 index 31aa390..0000000 --- a/mods/doc_modpack/doc_basics/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -doc -intllib? diff --git a/mods/doc_modpack/doc_basics/description.txt b/mods/doc_modpack/doc_basics/description.txt deleted file mode 100644 index f86a1b5..0000000 --- a/mods/doc_modpack/doc_basics/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds some help texts explaining how to use Minetest. diff --git a/mods/doc_modpack/doc_basics/mod.conf b/mods/doc_modpack/doc_basics/mod.conf index 8138f7d..fc3b3cf 100644 --- a/mods/doc_modpack/doc_basics/mod.conf +++ b/mods/doc_modpack/doc_basics/mod.conf @@ -1 +1,4 @@ name = doc_basics +depends = doc +optional_depends = intllib +description = Adds some help texts explaining how to use Minetest. diff --git a/mods/doc_modpack/doc_encyclopedia/depends.txt b/mods/doc_modpack/doc_encyclopedia/depends.txt deleted file mode 100644 index c8f3ef6..0000000 --- a/mods/doc_modpack/doc_encyclopedia/depends.txt +++ /dev/null @@ -1,3 +0,0 @@ -doc -intllib? -default? diff --git a/mods/doc_modpack/doc_encyclopedia/description.txt b/mods/doc_modpack/doc_encyclopedia/description.txt deleted file mode 100644 index 4227bd1..0000000 --- a/mods/doc_modpack/doc_encyclopedia/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds an encyclopedia item which allows you to access the help. diff --git a/mods/doc_modpack/doc_encyclopedia/mod.conf b/mods/doc_modpack/doc_encyclopedia/mod.conf index 318d238..9b537bb 100644 --- a/mods/doc_modpack/doc_encyclopedia/mod.conf +++ b/mods/doc_modpack/doc_encyclopedia/mod.conf @@ -1 +1,4 @@ name = doc_encyclopedia +depends = doc +optional_depends = intllib, default +description = Adds an encyclopedia item which allows you to access the help. diff --git a/mods/doc_modpack/doc_identifier/depends.txt b/mods/doc_modpack/doc_identifier/depends.txt deleted file mode 100644 index b5ad06b..0000000 --- a/mods/doc_modpack/doc_identifier/depends.txt +++ /dev/null @@ -1,5 +0,0 @@ -doc -doc_items -doc_basics? -default? -intllib? diff --git a/mods/doc_modpack/doc_identifier/description.txt b/mods/doc_modpack/doc_identifier/description.txt deleted file mode 100644 index 8294c74..0000000 --- a/mods/doc_modpack/doc_identifier/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds a tool which shows help entries about almost anything which it punches. diff --git a/mods/doc_modpack/doc_identifier/mod.conf b/mods/doc_modpack/doc_identifier/mod.conf index df963a0..a44b188 100644 --- a/mods/doc_modpack/doc_identifier/mod.conf +++ b/mods/doc_modpack/doc_identifier/mod.conf @@ -1 +1,4 @@ name = doc_identifier +depends = doc, doc_items +optional_depends = doc_basics, default, intllib +description = Adds a tool which shows help entries about almost anything which it punches. diff --git a/mods/doc_modpack/doc_items/depends.txt b/mods/doc_modpack/doc_items/depends.txt deleted file mode 100644 index 31aa390..0000000 --- a/mods/doc_modpack/doc_items/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -doc -intllib? diff --git a/mods/doc_modpack/doc_items/description.txt b/mods/doc_modpack/doc_items/description.txt deleted file mode 100644 index 7291077..0000000 --- a/mods/doc_modpack/doc_items/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds automatically generated help texts for items. diff --git a/mods/doc_modpack/doc_items/mod.conf b/mods/doc_modpack/doc_items/mod.conf index 74fa80d..2ac2f3b 100644 --- a/mods/doc_modpack/doc_items/mod.conf +++ b/mods/doc_modpack/doc_items/mod.conf @@ -1 +1,4 @@ name = doc_items +depends = doc +optional_depends = intllib +description = Adds automatically generated help texts for items. diff --git a/mods/doors/init.lua b/mods/doors/init.lua index 2048a64..7f89990 100644 --- a/mods/doors/init.lua +++ b/mods/doors/init.lua @@ -455,6 +455,7 @@ end doors.register("door_wood", { tiles = {{ name = "doors_door_wood.png", backface_culling = true }}, + use_texture_alpha = 'clip', description = S("Wooden Door"), inventory_image = "doors_item_wood.png", groups = {node = 1, choppy = 2, oddly_breakable_by_hand = 2, flammable = 2}, @@ -467,6 +468,7 @@ doors.register("door_wood", { doors.register("door_steel", { tiles = {{name = "doors_door_steel.png", backface_culling = true}}, + use_texture_alpha = 'clip', description = S("Steel Door"), inventory_image = "doors_item_steel.png", protected = true, @@ -483,6 +485,7 @@ doors.register("door_steel", { doors.register("door_glass", { tiles = {"doors_door_glass.png"}, + use_texture_alpha = 'clip', description = S("Glass Door"), inventory_image = "doors_item_glass.png", groups = {node = 1, cracky=3, oddly_breakable_by_hand=3}, @@ -498,6 +501,7 @@ doors.register("door_glass", { doors.register("door_obsidian_glass", { tiles = {"doors_door_obsidian_glass.png"}, + use_texture_alpha = 'clip', description = S("Obsidian Glass Door"), inventory_image = "doors_item_obsidian_glass.png", groups = {node = 1, cracky=3}, @@ -690,6 +694,7 @@ doors.register_trapdoor("doors:trapdoor", { wield_image = "doors_trapdoor.png", tile_front = "doors_trapdoor.png", tile_side = "doors_trapdoor_side.png", + use_texture_alpha = 'clip', groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2, door = 1}, }) @@ -699,6 +704,7 @@ doors.register_trapdoor("doors:trapdoor_steel", { wield_image = "doors_trapdoor_steel.png", tile_front = "doors_trapdoor_steel.png", tile_side = "doors_trapdoor_steel_side.png", + use_texture_alpha = 'clip', protected = true, sounds = default.node_sound_metal_defaults(), sound_open = "doors_steel_door_open", diff --git a/mods/earthbuild/depends.txt b/mods/earthbuild/depends.txt deleted file mode 100644 index b5a9630..0000000 --- a/mods/earthbuild/depends.txt +++ /dev/null @@ -1,6 +0,0 @@ -default -stairs -walls -fire -beds -doors diff --git a/mods/earthbuild/description.txt b/mods/earthbuild/description.txt deleted file mode 100644 index 5667b82..0000000 --- a/mods/earthbuild/description.txt +++ /dev/null @@ -1,7 +0,0 @@ -Earthbuild - -by Dokimi - -Adds traditional dirt and vegetation based construction methods and technologies, which do not require the use of stone or mining. - -Aims to reflect building styles that have been in use since neolithic times, and are still common in areas with little stone or resources. \ No newline at end of file diff --git a/mods/earthbuild/mod.conf b/mods/earthbuild/mod.conf index 0c6b4d5..2ead420 100644 --- a/mods/earthbuild/mod.conf +++ b/mods/earthbuild/mod.conf @@ -3,3 +3,4 @@ description = Adds traditional dirt and vegetation based construction methods an release = 1.0.1 title = Earthbuild name = earthbuild +depends = default, stairs, walls, fire, beds, doors diff --git a/mods/epic_trees/depends.txt b/mods/epic_trees/depends.txt deleted file mode 100644 index 331d858..0000000 --- a/mods/epic_trees/depends.txt +++ /dev/null @@ -1 +0,0 @@ -default \ No newline at end of file diff --git a/mods/epic_trees/mod.conf b/mods/epic_trees/mod.conf new file mode 100644 index 0000000..e25aa3e --- /dev/null +++ b/mods/epic_trees/mod.conf @@ -0,0 +1,2 @@ +name = epic_trees +depends = default diff --git a/mods/extra_doors/depends.txt b/mods/extra_doors/depends.txt deleted file mode 100644 index 678b31b..0000000 --- a/mods/extra_doors/depends.txt +++ /dev/null @@ -1 +0,0 @@ -doors diff --git a/mods/extra_doors/description.txt b/mods/extra_doors/description.txt deleted file mode 100644 index 1622783..0000000 --- a/mods/extra_doors/description.txt +++ /dev/null @@ -1 +0,0 @@ -Extra Doors adds a set of 18 new doors to Minetest including castle, dungeon, barn, cottage, and multi-panel styles. diff --git a/mods/extra_doors/init.lua b/mods/extra_doors/init.lua index ea4b1ce..766c9da 100644 --- a/mods/extra_doors/init.lua +++ b/mods/extra_doors/init.lua @@ -24,6 +24,7 @@ doors.register( "door_woodpanel1", { doors.register( "door_woodglass1", { -- Cambridge Style (2 panel) tiles = { { name = "doors_door_woodglass1.png", backface_culling = true } }, + use_texture_alpha = 'clip', description = "Wooden Single-Lite Door", inventory_image = "doors_item_woodglass1.png", groups = { choppy = 2, oddly_breakable_by_hand = 2, flammable = 2 }, @@ -37,6 +38,7 @@ doors.register( "door_woodglass1", { doors.register( "door_woodglass2", { -- Atherton Style (4 panel) tiles = { { name = "doors_door_woodglass2.png", backface_culling = true } }, + use_texture_alpha = 'clip', description = "Wooden Double-Lite Door", inventory_image = "doors_item_woodglass2.png", groups = { choppy = 2, oddly_breakable_by_hand = 2, flammable = 2 }, @@ -61,6 +63,7 @@ doors.register( "door_japanese", { doors.register( "door_french", { tiles = { { name = "doors_door_french.png", backface_culling = true } }, + use_texture_alpha = 'clip', description = "French Door", inventory_image = "doors_item_french.png", groups = { choppy = 2, oddly_breakable_by_hand = 2, flammable = 2 }, @@ -85,6 +88,7 @@ doors.register( "door_cottage1", { doors.register( "door_cottage2", { tiles = { { name = "doors_door_cottage2.png", backface_culling = true } }, + use_texture_alpha = 'clip', description = "Cottage Exterior Door", inventory_image = "doors_item_cottage2.png", groups = { choppy = 2, oddly_breakable_by_hand = 2, flammable = 2 }, @@ -185,6 +189,7 @@ doors.register("door_dungeon1", { doors.register( "door_dungeon2", { tiles = { { name = "doors_door_dungeon2.png", backface_culling = true } }, + use_texture_alpha = 'clip', description = "Dungeon Exterior Door", inventory_image = "doors_item_dungeon2.png", protected = true, @@ -217,6 +222,7 @@ doors.register( "door_steelpanel1", { doors.register( "door_steelglass1", { tiles = { { name = "doors_door_steelglass1.png", backface_culling = true } }, + use_texture_alpha = 'clip', description = "Steel Single-Lite Door", inventory_image = "doors_item_steelglass1.png", protected = true, @@ -233,6 +239,7 @@ doors.register( "door_steelglass1", { doors.register( "door_steelglass2", { tiles = { { name = "doors_door_steelglass2.png", backface_culling = true } }, + use_texture_alpha = 'clip', description = "Steel Double-Lite Door", inventory_image = "doors_item_steelglass2.png", protected = true, diff --git a/mods/extra_doors/mod.conf b/mods/extra_doors/mod.conf index 5fa5a75..eed7f67 100644 --- a/mods/extra_doors/mod.conf +++ b/mods/extra_doors/mod.conf @@ -2,3 +2,5 @@ name = extra_doors title = Extra Doors author = sorcerykid license = LGPL-3.0 +depends = doors +description = Extra Doors adds a set of 18 new doors to Minetest including castle, dungeon, barn, cottage, and multi-panel styles. diff --git a/mods/farming/depends.txt b/mods/farming/depends.txt deleted file mode 100644 index 650885b..0000000 --- a/mods/farming/depends.txt +++ /dev/null @@ -1,5 +0,0 @@ -default -stairs? -intllib? -lucky_block? -toolranks? diff --git a/mods/farming/description.txt b/mods/farming/description.txt deleted file mode 100644 index 58bdc81..0000000 --- a/mods/farming/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds many plants and food to Minetest \ No newline at end of file diff --git a/mods/farming/mod.conf b/mods/farming/mod.conf index 0c21967..a20401e 100644 --- a/mods/farming/mod.conf +++ b/mods/farming/mod.conf @@ -1,2 +1,4 @@ name = farming depends = flowers +optional_depends = stairs, intllib, lucky_block, toolranks +description = Adds many plants and food to Minetest diff --git a/mods/filler/description.txt b/mods/filler/description.txt deleted file mode 100644 index 82181a7..0000000 --- a/mods/filler/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds a Filling Tool which can fill areas. diff --git a/mods/filler/mod.conf b/mods/filler/mod.conf index b15a6af..8fff925 100644 --- a/mods/filler/mod.conf +++ b/mods/filler/mod.conf @@ -1,2 +1,3 @@ name = filler depends = default +description = Adds a Filling Tool which can fill areas. diff --git a/mods/furniture/decor.lua b/mods/furniture/decor.lua index 13a2b00..64e8488 100644 --- a/mods/furniture/decor.lua +++ b/mods/furniture/decor.lua @@ -54,7 +54,7 @@ function furniture.curtain_removal(pos, node, digger) local nodename = node.name local fdir = node.param2 if fdir >= 3 then - return + minetest.remove_node(pos) end local posr = {x = pos.x + fdir_table[fdir+1][1], y=pos.y, z = pos.z + fdir_table[fdir+1][2]} local posl = {x = pos.x - fdir_table[fdir+1][1], y=pos.y, z = pos.z - fdir_table[fdir+1][2]} diff --git a/mods/furniture/misc.lua b/mods/furniture/misc.lua index 197c1a8..fcc5f33 100644 --- a/mods/furniture/misc.lua +++ b/mods/furniture/misc.lua @@ -42,7 +42,7 @@ minetest.register_node('furniture:railing_corner', { {.5625, -.5, -.5, .4375, .4375, .5625}} }, groups = {oddly_breakable_by_hand = 2, choppy=3}, - after_place_node = function(pos) + after_place_node = function(pos, placer) if placer:get_player_control().sneak then local node = minetest.get_node(pos) local new_pos = {x = pos.x, y = pos.y+1, z = pos.z} diff --git a/mods/hopper/depends.txt b/mods/hopper/depends.txt deleted file mode 100644 index 79d95ba..0000000 --- a/mods/hopper/depends.txt +++ /dev/null @@ -1,6 +0,0 @@ -default? -lucky_block? -doc? -intllib? -protector? -wine? \ No newline at end of file diff --git a/mods/hopper/description.txt b/mods/hopper/description.txt deleted file mode 100644 index 88aacc6..0000000 --- a/mods/hopper/description.txt +++ /dev/null @@ -1,3 +0,0 @@ -Adds hoppers to transport items between chests/furnace etc. - -Forum: https://forum.minetest.net/viewtopic.php?f=9&t=20058 \ No newline at end of file diff --git a/mods/hopper/mod.conf b/mods/hopper/mod.conf index aa82692..0aef069 100644 --- a/mods/hopper/mod.conf +++ b/mods/hopper/mod.conf @@ -1 +1,3 @@ -name = hopper \ No newline at end of file +name = hopper +optional_depends = default, lucky_block, doc, intllib, protector, wine +description = Adds hoppers to transport items between chests/furnace etc. diff --git a/mods/itemframes/init.lua b/mods/itemframes/init.lua index 32a67d3..ea80796 100644 --- a/mods/itemframes/init.lua +++ b/mods/itemframes/init.lua @@ -1,6 +1,6 @@ screwdriver = screwdriver or {} local tmp = {} -local max_objs = tonumber(minetest.setting_get("max_objects_per_block")) or 49 +local max_objs = tonumber(minetest.settings:get("max_objects_per_block")) or 49 -- item entity diff --git a/mods/lumberjack/depends.txt b/mods/lumberjack/depends.txt deleted file mode 100644 index d56d964..0000000 --- a/mods/lumberjack/depends.txt +++ /dev/null @@ -1,4 +0,0 @@ -default -moretrees? - - diff --git a/mods/lumberjack/description.txt b/mods/lumberjack/description.txt deleted file mode 100644 index b0a9eb5..0000000 --- a/mods/lumberjack/description.txt +++ /dev/null @@ -1,2 +0,0 @@ -This mod allows to dig the bottom of the tree and the whole tree is moved into the inventory. - diff --git a/mods/lumberjack/mod.conf b/mods/lumberjack/mod.conf index 24c6cdd..a06f234 100644 --- a/mods/lumberjack/mod.conf +++ b/mods/lumberjack/mod.conf @@ -1 +1,4 @@ -name=lumberjack +name = lumberjack +depends = default +optional_depends = moretrees +description = This mod allows to dig the bottom of the tree and the whole tree is moved into the inventory. diff --git a/mods/mailbox/depends.txt b/mods/mailbox/depends.txt deleted file mode 100644 index 4ad96d5..0000000 --- a/mods/mailbox/depends.txt +++ /dev/null @@ -1 +0,0 @@ -default diff --git a/mods/mailbox/mod.conf b/mods/mailbox/mod.conf new file mode 100644 index 0000000..f4ac470 --- /dev/null +++ b/mods/mailbox/mod.conf @@ -0,0 +1,2 @@ +name = mailbox +depends = default diff --git a/mods/minetest-3d_armor/3d_armor/depends.txt b/mods/minetest-3d_armor/3d_armor/depends.txt deleted file mode 100644 index a33755d..0000000 --- a/mods/minetest-3d_armor/3d_armor/depends.txt +++ /dev/null @@ -1,8 +0,0 @@ -default -player_monoids? -armor_monoid? -pova? -fire? -ethereal? -bakedclay? -intllib? diff --git a/mods/minetest-3d_armor/3d_armor/description.txt b/mods/minetest-3d_armor/3d_armor/description.txt deleted file mode 100644 index b0a9b0a..0000000 --- a/mods/minetest-3d_armor/3d_armor/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds craftable armor that is visible to other players. diff --git a/mods/minetest-3d_armor/3d_armor/mod.conf b/mods/minetest-3d_armor/3d_armor/mod.conf new file mode 100644 index 0000000..56f7973 --- /dev/null +++ b/mods/minetest-3d_armor/3d_armor/mod.conf @@ -0,0 +1,4 @@ +name = 3d_armor +depends = default +optional_depends = player_monoids, armor_monoid, pova, fire, ethereal, bakedclay, intllib +description = Adds craftable armor that is visible to other players. diff --git a/mods/minetest-3d_armor/3d_armor_stand/depends.txt b/mods/minetest-3d_armor/3d_armor_stand/depends.txt deleted file mode 100644 index fdbb290..0000000 --- a/mods/minetest-3d_armor/3d_armor_stand/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -3d_armor - diff --git a/mods/minetest-3d_armor/3d_armor_stand/mod.conf b/mods/minetest-3d_armor/3d_armor_stand/mod.conf new file mode 100644 index 0000000..d1f1a4e --- /dev/null +++ b/mods/minetest-3d_armor/3d_armor_stand/mod.conf @@ -0,0 +1,2 @@ +name = 3d_armor_stand +depends = 3d_armor diff --git a/mods/minetest-3d_armor/3d_armor_ui/depends.txt b/mods/minetest-3d_armor/3d_armor_ui/depends.txt deleted file mode 100644 index cf4ccf9..0000000 --- a/mods/minetest-3d_armor/3d_armor_ui/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -3d_armor -unified_inventory? diff --git a/mods/minetest-3d_armor/3d_armor_ui/description.txt b/mods/minetest-3d_armor/3d_armor_ui/description.txt deleted file mode 100644 index 873f876..0000000 --- a/mods/minetest-3d_armor/3d_armor_ui/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds 3d_armor page to the unified inventory diff --git a/mods/minetest-3d_armor/3d_armor_ui/mod.conf b/mods/minetest-3d_armor/3d_armor_ui/mod.conf new file mode 100644 index 0000000..184e686 --- /dev/null +++ b/mods/minetest-3d_armor/3d_armor_ui/mod.conf @@ -0,0 +1,4 @@ +name = 3d_armor_ui +depends = 3d_armor +optional_depends = unified_inventory +description = Adds 3d_armor page to the unified inventory diff --git a/mods/minetest-3d_armor/shields/depends.txt b/mods/minetest-3d_armor/shields/depends.txt deleted file mode 100644 index 585cc7a..0000000 --- a/mods/minetest-3d_armor/shields/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default -3d_armor diff --git a/mods/minetest-3d_armor/shields/description.txt b/mods/minetest-3d_armor/shields/description.txt deleted file mode 100644 index cb378bb..0000000 --- a/mods/minetest-3d_armor/shields/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds visible shields to 3d armor. diff --git a/mods/minetest-3d_armor/shields/mod.conf b/mods/minetest-3d_armor/shields/mod.conf new file mode 100644 index 0000000..9a95629 --- /dev/null +++ b/mods/minetest-3d_armor/shields/mod.conf @@ -0,0 +1,3 @@ +name = shields +depends = default, 3d_armor +description = Adds visible shields to 3d armor. diff --git a/mods/minetest-3d_armor/wieldview/depends.txt b/mods/minetest-3d_armor/wieldview/depends.txt deleted file mode 100644 index b6cac21..0000000 --- a/mods/minetest-3d_armor/wieldview/depends.txt +++ /dev/null @@ -1 +0,0 @@ -3d_armor diff --git a/mods/minetest-3d_armor/wieldview/description.txt b/mods/minetest-3d_armor/wieldview/description.txt deleted file mode 100644 index 0d51ad9..0000000 --- a/mods/minetest-3d_armor/wieldview/description.txt +++ /dev/null @@ -1 +0,0 @@ -Makes hand wielded items visible to other players. diff --git a/mods/minetest-3d_armor/wieldview/mod.conf b/mods/minetest-3d_armor/wieldview/mod.conf new file mode 100644 index 0000000..c5f4812 --- /dev/null +++ b/mods/minetest-3d_armor/wieldview/mod.conf @@ -0,0 +1,3 @@ +name = wieldview +depends = 3d_armor +description = Makes hand wielded items visible to other players. diff --git a/mods/mobs_animal/depends.txt b/mods/mobs_animal/depends.txt deleted file mode 100644 index 58b4e62..0000000 --- a/mods/mobs_animal/depends.txt +++ /dev/null @@ -1,4 +0,0 @@ -default -mobs -intllib? -lucky_block? diff --git a/mods/mobs_animal/description.txt b/mods/mobs_animal/description.txt deleted file mode 100644 index 85afccd..0000000 --- a/mods/mobs_animal/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds farm animals. \ No newline at end of file diff --git a/mods/mobs_animal/mod.conf b/mods/mobs_animal/mod.conf index e2080bc..130b034 100644 --- a/mods/mobs_animal/mod.conf +++ b/mods/mobs_animal/mod.conf @@ -1 +1,4 @@ name = mobs_animal +depends = mobs, default +optional_depends = intllib, lucky_block +description = Adds farm animals. diff --git a/mods/mobs_monster/depends.txt b/mods/mobs_monster/depends.txt deleted file mode 100644 index d0aea36..0000000 --- a/mods/mobs_monster/depends.txt +++ /dev/null @@ -1,5 +0,0 @@ -default -mobs -intllib? -lucky_block? -toolranks? diff --git a/mods/mobs_monster/description.txt b/mods/mobs_monster/description.txt deleted file mode 100644 index ac3d887..0000000 --- a/mods/mobs_monster/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds many types of monster. diff --git a/mods/mobs_monster/mod.conf b/mods/mobs_monster/mod.conf index 3c4fe39..f69ab0a 100644 --- a/mods/mobs_monster/mod.conf +++ b/mods/mobs_monster/mod.conf @@ -1 +1,4 @@ name = mobs_monster +depends = default, mobs +optional_depends = intllib, lucky_block, toolranks +description = Adds many types of monster. diff --git a/mods/mobs_water/mobs_crocs/depends.txt b/mods/mobs_water/mobs_crocs/depends.txt deleted file mode 100644 index cc03398..0000000 --- a/mods/mobs_water/mobs_crocs/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default -mobs diff --git a/mods/mobs_water/mobs_crocs/mod.conf b/mods/mobs_water/mobs_crocs/mod.conf new file mode 100644 index 0000000..a6c246d --- /dev/null +++ b/mods/mobs_water/mobs_crocs/mod.conf @@ -0,0 +1,2 @@ +name = mobs_crocs +depends = default, mobs diff --git a/mods/mobs_water/mobs_fish/depends.txt b/mods/mobs_water/mobs_fish/depends.txt deleted file mode 100644 index cc03398..0000000 --- a/mods/mobs_water/mobs_fish/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default -mobs diff --git a/mods/mobs_water/mobs_fish/mod.conf b/mods/mobs_water/mobs_fish/mod.conf new file mode 100644 index 0000000..825fdda --- /dev/null +++ b/mods/mobs_water/mobs_fish/mod.conf @@ -0,0 +1,2 @@ +name = mobs_fish +depends = default, mobs diff --git a/mods/mobs_water/mobs_sharks/depends.txt b/mods/mobs_water/mobs_sharks/depends.txt deleted file mode 100644 index cc03398..0000000 --- a/mods/mobs_water/mobs_sharks/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default -mobs diff --git a/mods/mobs_water/mobs_sharks/mod.conf b/mods/mobs_water/mobs_sharks/mod.conf new file mode 100644 index 0000000..6b77324 --- /dev/null +++ b/mods/mobs_water/mobs_sharks/mod.conf @@ -0,0 +1,2 @@ +name = mobs_sharks +depends = default, mobs diff --git a/mods/mobs_water/mobs_turtles/depends.txt b/mods/mobs_water/mobs_turtles/depends.txt deleted file mode 100644 index cc03398..0000000 --- a/mods/mobs_water/mobs_turtles/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default -mobs diff --git a/mods/mobs_water/mobs_turtles/mod.conf b/mods/mobs_water/mobs_turtles/mod.conf new file mode 100644 index 0000000..45b2043 --- /dev/null +++ b/mods/mobs_water/mobs_turtles/mod.conf @@ -0,0 +1,2 @@ +name = mobs_turtles +depends = default, mobs diff --git a/mods/morelights/morelights/depends.txt b/mods/morelights/morelights/depends.txt deleted file mode 100644 index 583a185..0000000 --- a/mods/morelights/morelights/depends.txt +++ /dev/null @@ -1,3 +0,0 @@ -default -dye -xpanes? diff --git a/mods/morelights/morelights/mod.conf b/mods/morelights/morelights/mod.conf new file mode 100644 index 0000000..d456b7e --- /dev/null +++ b/mods/morelights/morelights/mod.conf @@ -0,0 +1,3 @@ +name = morelights +depends = default, dye +optional_depends = xpanes diff --git a/mods/morelights/morelights_extras/depends.txt b/mods/morelights/morelights_extras/depends.txt deleted file mode 100644 index bec07a9..0000000 --- a/mods/morelights/morelights_extras/depends.txt +++ /dev/null @@ -1,3 +0,0 @@ -default -morelights -stairs? diff --git a/mods/morelights/morelights_extras/mod.conf b/mods/morelights/morelights_extras/mod.conf new file mode 100644 index 0000000..5523170 --- /dev/null +++ b/mods/morelights/morelights_extras/mod.conf @@ -0,0 +1,3 @@ +name = morelights_extras +depends = default, morelights +optional_depends = stairs diff --git a/mods/morelights/morelights_modern/depends.txt b/mods/morelights/morelights_modern/depends.txt deleted file mode 100644 index ba0e880..0000000 --- a/mods/morelights/morelights_modern/depends.txt +++ /dev/null @@ -1,4 +0,0 @@ -default -dye -morelights -wool diff --git a/mods/morelights/morelights_modern/mod.conf b/mods/morelights/morelights_modern/mod.conf new file mode 100644 index 0000000..b022661 --- /dev/null +++ b/mods/morelights/morelights_modern/mod.conf @@ -0,0 +1,2 @@ +name = morelights_modern +depends = default, dye, morelights, wool diff --git a/mods/morelights/morelights_vintage/depends.txt b/mods/morelights/morelights_vintage/depends.txt deleted file mode 100644 index ac7ff56..0000000 --- a/mods/morelights/morelights_vintage/depends.txt +++ /dev/null @@ -1,4 +0,0 @@ -basic_materials? -default -farming -morelights diff --git a/mods/morelights/morelights_vintage/mod.conf b/mods/morelights/morelights_vintage/mod.conf new file mode 100644 index 0000000..668b3e8 --- /dev/null +++ b/mods/morelights/morelights_vintage/mod.conf @@ -0,0 +1,3 @@ +name = morelights_vintage +depends = default, farming, morelights +optional_depends = basic_materials diff --git a/mods/names_per_ip/depends.txt b/mods/names_per_ip/depends.txt deleted file mode 100644 index e69de29..0000000 diff --git a/mods/names_per_ip/mod.conf b/mods/names_per_ip/mod.conf new file mode 100644 index 0000000..3d328f3 --- /dev/null +++ b/mods/names_per_ip/mod.conf @@ -0,0 +1 @@ +name = names_per_ip diff --git a/mods/other_worlds/depends.txt b/mods/other_worlds/depends.txt deleted file mode 100644 index 4ad96d5..0000000 --- a/mods/other_worlds/depends.txt +++ /dev/null @@ -1 +0,0 @@ -default diff --git a/mods/other_worlds/description.txt b/mods/other_worlds/description.txt deleted file mode 100644 index 808355a..0000000 --- a/mods/other_worlds/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds asteroid layers and height-based skybox switches to create space environments. \ No newline at end of file diff --git a/mods/other_worlds/mod.conf b/mods/other_worlds/mod.conf index 5f36b1e..c607948 100644 --- a/mods/other_worlds/mod.conf +++ b/mods/other_worlds/mod.conf @@ -1,2 +1,3 @@ name = other_worlds depends = default, epic, skylayer +description = Adds asteroid layers and height-based skybox switches to create space environments. diff --git a/mods/pbj_pup/depends.txt b/mods/pbj_pup/depends.txt deleted file mode 100644 index 4ad96d5..0000000 --- a/mods/pbj_pup/depends.txt +++ /dev/null @@ -1 +0,0 @@ -default diff --git a/mods/pbj_pup/mod.conf b/mods/pbj_pup/mod.conf new file mode 100644 index 0000000..9ec4789 --- /dev/null +++ b/mods/pbj_pup/mod.conf @@ -0,0 +1,2 @@ +name = pbj_pup +depends = default diff --git a/mods/protector/depends.txt b/mods/protector/depends.txt deleted file mode 100644 index f1e9655..0000000 --- a/mods/protector/depends.txt +++ /dev/null @@ -1,4 +0,0 @@ -default? -intllib? -lucky_block? -mesecons_mvps? diff --git a/mods/protector/description.txt b/mods/protector/description.txt deleted file mode 100644 index 587fee8..0000000 --- a/mods/protector/description.txt +++ /dev/null @@ -1 +0,0 @@ -Lets players craft special blocks to protect their builds or disable PVP in areas. \ No newline at end of file diff --git a/mods/protector/mod.conf b/mods/protector/mod.conf index 8eb0aa8..701c39f 100644 --- a/mods/protector/mod.conf +++ b/mods/protector/mod.conf @@ -1 +1,3 @@ -name = protector \ No newline at end of file +name = protector +optional_depends = default +description = Lets players craft special blocks to protect their builds or disable PVP in areas. diff --git a/mods/ropes/depends.txt b/mods/ropes/depends.txt deleted file mode 100644 index 55c98cb..0000000 --- a/mods/ropes/depends.txt +++ /dev/null @@ -1,8 +0,0 @@ -default -farming? -vines? -doc? -intllib? -loot? -hemp? -cottages? \ No newline at end of file diff --git a/mods/ropes/description.txt b/mods/ropes/description.txt deleted file mode 100644 index 846f150..0000000 --- a/mods/ropes/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds rope boxes of various lengths and also rope ladders. \ No newline at end of file diff --git a/mods/ropes/mod.conf b/mods/ropes/mod.conf index 88ecfd1..9868b55 100644 --- a/mods/ropes/mod.conf +++ b/mods/ropes/mod.conf @@ -1 +1,4 @@ -name = ropes \ No newline at end of file +name = ropes +depends = default +optional_depends = farming, vines, doc, intllib, loot, hemp, cottages +description = Adds rope boxes of various lengths and also rope ladders. diff --git a/mods/scaffolding/depends.txt b/mods/scaffolding/depends.txt deleted file mode 100644 index 4ad96d5..0000000 --- a/mods/scaffolding/depends.txt +++ /dev/null @@ -1 +0,0 @@ -default diff --git a/mods/scaffolding/init.lua b/mods/scaffolding/init.lua index e6e9436..848c3e2 100644 --- a/mods/scaffolding/init.lua +++ b/mods/scaffolding/init.lua @@ -68,6 +68,7 @@ minetest.register_node("scaffolding:scaffolding", { drawtype = "nodebox", tiles = {"scaffolding_wooden_scaffolding_top.png", "scaffolding_wooden_scaffolding_top.png", "scaffolding_wooden_scaffolding.png", "scaffolding_wooden_scaffolding.png", "scaffolding_wooden_scaffolding.png", "scaffolding_wooden_scaffolding.png"}, + use_texture_alpha = 'clip', paramtype = "light", paramtype2 = "facedir", climbable = true, @@ -123,6 +124,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", { drawtype = "nodebox", tiles = {"scaffolding_wooden_scaffolding.png^scaffolding_reinforced.png", "scaffolding_wooden_scaffolding.png^scaffolding_reinforced.png", "scaffolding_wooden_scaffolding.png^scaffolding_reinforced.png"}, + use_texture_alpha = 'clip', drop = "scaffolding:scaffolding", paramtype = "light", light_source = 14, @@ -170,6 +172,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", { description = "Wooden Platform", drawtype = "nodebox", tiles = {"scaffolding_wooden_scaffolding_top.png", "scaffolding_wooden_scaffolding_top.png", "scaffolding_wooden_scaffolding.png^scaffolding_platform.png"}, + use_texture_alpha = 'clip', paramtype = "light", paramtype2 = "facedir", climbable = false, @@ -209,6 +212,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", { drawtype = "nodebox", light_source = 14, tiles = {"scaffolding_wooden_scaffolding.png^scaffolding_reinforced.png", "scaffolding_wooden_scaffolding.png^scaffolding_reinforced.png", "scaffolding_wooden_scaffolding.png^scaffolding_platform.png"}, + use_texture_alpha = 'clip', drop = "scaffolding:platform", paramtype = "light", paramtype2 = "facedir", @@ -243,6 +247,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", { drawtype = "nodebox", tiles = {"scaffolding_iron_scaffolding_top.png", "scaffolding_iron_scaffolding_top.png", "scaffolding_iron_scaffolding.png", "scaffolding_iron_scaffolding.png", "scaffolding_iron_scaffolding.png", "scaffolding_iron_scaffolding.png"}, + use_texture_alpha = 'clip', paramtype = "light", paramtype2 = "facedir", climbable = true, @@ -299,6 +304,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", { drawtype = "nodebox", tiles = {"scaffolding_iron_scaffolding.png^scaffolding_reinforced.png", "scaffolding_iron_scaffolding.png^scaffolding_reinforced.png", "scaffolding_iron_scaffolding.png^scaffolding_reinforced.png"}, + use_texture_alpha = 'clip', drop = "scaffolding:iron_scaffolding", paramtype = "light", paramtype2 = "facedir", @@ -346,6 +352,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", { description = "Iron Platform", drawtype = "nodebox", tiles = {"scaffolding_iron_scaffolding_top.png", "scaffolding_iron_scaffolding_top.png", "scaffolding_iron_scaffolding.png^scaffolding_platform.png"}, + use_texture_alpha = 'clip', paramtype = "light", paramtype2 = "facedir", climbable = false, @@ -384,6 +391,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", { description = "Iron Platform", drawtype = "nodebox", tiles = {"scaffolding_iron_scaffolding.png^scaffolding_reinforced.png", "scaffolding_iron_scaffolding.png^scaffolding_reinforced.png", "scaffolding_iron_scaffolding.png^scaffolding_platform.png"}, + use_texture_alpha = 'clip', drop = "scaffolding:iron_platform", paramtype = "light", paramtype2 = "facedir", diff --git a/mods/scaffolding/mod.conf b/mods/scaffolding/mod.conf new file mode 100644 index 0000000..7d8dda9 --- /dev/null +++ b/mods/scaffolding/mod.conf @@ -0,0 +1,2 @@ +name = scaffolding +depends = default diff --git a/mods/signs_lib/depends.txt b/mods/signs_lib/depends.txt deleted file mode 100644 index d3cb379..0000000 --- a/mods/signs_lib/depends.txt +++ /dev/null @@ -1,7 +0,0 @@ -default -intllib? -screwdriver? -streetspoles? -streetlamps? -cottages? -prefab_redo? \ No newline at end of file diff --git a/mods/signs_lib/description.txt b/mods/signs_lib/description.txt deleted file mode 100644 index d157852..0000000 --- a/mods/signs_lib/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds signs with readable text. diff --git a/mods/signs_lib/mod.conf b/mods/signs_lib/mod.conf index 2781b60..b89d00c 100644 --- a/mods/signs_lib/mod.conf +++ b/mods/signs_lib/mod.conf @@ -1,2 +1,5 @@ name = signs_lib min_minetest_version = 5.2.0 +description = Adds signs with readable text. +depends = default +optional_depends = intllib, screwdriver, streetspoles, streetlamps, cottages, prefab_redo diff --git a/mods/simplecrafting_lib/depends.txt b/mods/simplecrafting_lib/depends.txt deleted file mode 100644 index 361359e..0000000 --- a/mods/simplecrafting_lib/depends.txt +++ /dev/null @@ -1,8 +0,0 @@ -default? -intllib? -hopper? -pipeworks? -awards? -wool? -sfinv? -unified_inventory? \ No newline at end of file diff --git a/mods/simplecrafting_lib/description.txt b/mods/simplecrafting_lib/description.txt deleted file mode 100644 index 99bb04b..0000000 --- a/mods/simplecrafting_lib/description.txt +++ /dev/null @@ -1 +0,0 @@ -A library for other mods that adds a simple alternative to Minetest's crafting grid. \ No newline at end of file diff --git a/mods/simplecrafting_lib/mod.conf b/mods/simplecrafting_lib/mod.conf index d567939..b5d9436 100644 --- a/mods/simplecrafting_lib/mod.conf +++ b/mods/simplecrafting_lib/mod.conf @@ -1,2 +1,3 @@ -name=simplecrafting_lib -optional-depends = awards, default, intllib, hopper, pipeworks, wool, sfinv, unified_inventory +name = simplecrafting_lib +optional_depends = awards, default, intllib, hopper, pipeworks, wool, sfinv, unified_inventory +description = A library for other mods that adds a simple alternative to Minetest's crafting grid. diff --git a/mods/skylayer/mod.conf b/mods/skylayer/mod.conf new file mode 100644 index 0000000..88ad1ad --- /dev/null +++ b/mods/skylayer/mod.conf @@ -0,0 +1 @@ +name = skylayer diff --git a/mods/spawn/commands.lua b/mods/spawn/commands.lua index 2f93002..b99b66c 100644 --- a/mods/spawn/commands.lua +++ b/mods/spawn/commands.lua @@ -10,7 +10,7 @@ minetest.register_chatcommand('spawn', { privs = {home=true}, func = function (name) local player = minetest.get_player_by_name(name) - player:setpos({x=1473, y=2486, z=2970}) + player:set_pos({x=1473, y=2486, z=2970}) default.player_attached[player] = false default.player_set_animation(player, "stand", 30) armor:set_player_armor(player) @@ -21,7 +21,7 @@ minetest.register_chatcommand('interact', { description = 'Gives player interact', privs = {home=true}, func = function(name, params) - if params == 'strawhat' then + if params == 'inverted-octopus' then local privs = minetest.get_player_privs(name) privs.interact = true minetest.set_player_privs(name, privs) diff --git a/mods/stainedglass/mod.conf b/mods/stainedglass/mod.conf new file mode 100644 index 0000000..05d10bf --- /dev/null +++ b/mods/stainedglass/mod.conf @@ -0,0 +1,2 @@ +title = Stained Glass +name = stainedglass diff --git a/mods/stations/station_weaving_loom.lua b/mods/stations/station_weaving_loom.lua index d87d126..f2273e6 100644 --- a/mods/stations/station_weaving_loom.lua +++ b/mods/stations/station_weaving_loom.lua @@ -133,6 +133,10 @@ minetest.register_node('stations:weaving_loom', { inv:add_item('output', 'epic:burlap') meta:set_string('progress', 0) meta:set_string('formspec', loom_formspec(0)) + else + inv:add_item('output', 'furniture:fabric_white') + meta:set_string('progress', 0) + meta:set_string('formspec', loom_formspec(0)) end end end @@ -255,6 +259,10 @@ minetest.register_node('stations:weaving_loom_locked', { inv:add_item('output', 'epic:burlap') meta:set_string('progress', 0) meta:set_string('formspec', loom_formspec(0)) + else + inv:add_item('output', 'furniture:fabric_white') + meta:set_string('progress', 0) + meta:set_string('formspec', loom_formspec(0)) end end end diff --git a/mods/tell/description.txt b/mods/tell/description.txt deleted file mode 100644 index f464f27..0000000 --- a/mods/tell/description.txt +++ /dev/null @@ -1,6 +0,0 @@ -It happens all the time, you join a server needing to tell someone something, but they aren't online. -Sure, some servers have an email/mailbox system, but for many, such systems are overly complex and therefore not available. -That's why I made tell. - -Forum: https://forum.minetest.net/viewtopic.php?f=9&t=17164 -GitHub: https://github.com/octacian/tell diff --git a/mods/tell/mod.conf b/mods/tell/mod.conf index 5cc4d8c..6ec795d 100644 --- a/mods/tell/mod.conf +++ b/mods/tell/mod.conf @@ -1 +1,2 @@ name = tell +description = It happens all the time, you join a server needing to tell someone something, but they aren't online. Sure, some servers have an email/mailbox system, but for many, such systems are overly complex and therefore not available. That's why I made tell. diff --git a/mods/tpad/init.lua b/mods/tpad/init.lua index 39e5d53..481eb34 100644 --- a/mods/tpad/init.lua +++ b/mods/tpad/init.lua @@ -463,12 +463,9 @@ end function tpad.on_rightclick(clicked_pos, node, clicker) local playername = clicker:get_player_name() - local clicked_meta = minetest.get_meta(clicked_pos) + local clicked_meta = minetest.env:get_meta(clicked_pos) local ownername = clicked_meta:get_string("owner") local pad = tpad.get_pad_data(clicked_pos) - if ownername then - print ('owner is '..ownername..' and clicker is '..playername) - end if not pad or not ownername then notify.err(playername, "Error! Missing pad data!") @@ -548,6 +545,13 @@ function tpad.on_destruct(pos) tpad.del_pad(ownername, pos) end +function tpad.on_blast(pos) + local meta = minetest.env:get_meta(pos) + local ownername = meta:get_string("owner") + tpad.del_pad(ownername, pos) + minetest.remove_node(pos) +end + -- ======================================================================== -- forms -- ======================================================================== @@ -704,12 +708,7 @@ minetest.register_node(tpad.nodename, { on_rightclick = tpad.on_rightclick, can_dig = tpad.can_dig, on_destruct = tpad.on_destruct, - on_blast = function(pos) - local meta = minetest:get_meta(pos) - local ownername = meta:get_string("owner") - tpad.del_pad(ownername, pos) - minetest.remove_node(pos) - end, + on_blast = tpad.on_blast, }) minetest.register_chatcommand("tpad", {func = tpad.command}) diff --git a/mods/tpad/storage.lua b/mods/tpad/storage.lua index caaeac5..d5c5577 100644 --- a/mods/tpad/storage.lua +++ b/mods/tpad/storage.lua @@ -9,7 +9,9 @@ function tpad._get_all_pads() if parts[1] == "pads" then local pads = minetest.deserialize(value) if type(pads) == "table" then - allpads[parts[2]] = pads + if parts[2] then + allpads[parts[2]] = pads + end end end end diff --git a/mods/tpad/storage_bak.lua b/mods/tpad/storage_bak.lua new file mode 100644 index 0000000..bf07cd7 --- /dev/null +++ b/mods/tpad/storage_bak.lua @@ -0,0 +1,59 @@ + +local storage = minetest.get_mod_storage() + +function tpad._get_all_pads() + local storage_table = storage:to_table() + local allpads = {} + for key, value in pairs(storage_table.fields) do + local parts = key:split(":") + if parts[1] == "pads" then + local pads = minetest.deserialize(value) + if type(pads) == "table" then + if parts[2] then + allpads[parts[2]] = pads + end + end + end + end + return allpads +end + +function tpad._get_stored_pads(ownername) + local serial_pads = storage:get_string("pads:" .. ownername) + if serial_pads == nil or serial_pads == "" then return {} end + print 'pads loaded in fine.' + return minetest.deserialize(serial_pads) +end + +function tpad._set_stored_pads(ownername, pads) + storage:set_string("pads:" .. ownername, minetest.serialize(pads)) +end + +function tpad._storage_sanity_check() + local storage_version = storage:get_string("_version") + local storage_path = minetest.get_worldpath() .. "/mod_storage/" + if storage_version == "1.1" then + tpad._copy_file(storage_path .. tpad.mod_name, storage_path .. tpad.mod_name .. ".1.1.backup") + tpad._convert_storage_1_1() + elseif storage_version ~= "" and storage_version ~= tpad.version then + error("Mod storage version not supported, aborting to prevent data corruption") + end + storage:set_string("_version", tpad.version) +end + +function tpad._convert_storage_1_1() + local storage_table = storage:to_table() + for field, value in pairs(storage_table.fields) do + local parts = field:split(":") + if parts[1] == "pads" then + local pads = minetest.deserialize(value) + for key, name in pairs(pads) do + pads[key] = { name = name } + end + storage_table.fields[field] = minetest.serialize(pads) + end + end + storage:from_table(storage_table) +end + +tpad._storage_sanity_check() diff --git a/mods/tunneltest/README.md b/mods/tunneltest/README.md deleted file mode 100644 index da915fe..0000000 --- a/mods/tunneltest/README.md +++ /dev/null @@ -1 +0,0 @@ -Minetest mod that adds a tool for digging tunnels. diff --git a/mods/tunneltest/mod.conf b/mods/tunneltest/mod.conf new file mode 100644 index 0000000..3affe95 --- /dev/null +++ b/mods/tunneltest/mod.conf @@ -0,0 +1,2 @@ +name = tunneltest +description = Minetest mod that adds a tool for digging tunnels.