Add variables
Adding variables makes it easier to change the sizes. Use the variable at the top of the respective file to change it. Also added forum link to README.
This commit is contained in:
parent
9591429f0e
commit
a8d241ae6f
@ -2,3 +2,5 @@
|
|||||||
Adds various enhancements (usually wield-scale based) to Minetest's default game
|
Adds various enhancements (usually wield-scale based) to Minetest's default game
|
||||||
|
|
||||||
To install, rename to "enhancements" and place in the mods/ directory.
|
To install, rename to "enhancements" and place in the mods/ directory.
|
||||||
|
|
||||||
|
Forum topic: https://forum.minetest.net/viewtopic.php?f=9&t=13470
|
||||||
|
16
ingots.lua
16
ingots.lua
@ -1,41 +1,43 @@
|
|||||||
|
sizei = 1.5
|
||||||
|
|
||||||
minetest.register_craftitem(":default:steel_ingot", {
|
minetest.register_craftitem(":default:steel_ingot", {
|
||||||
description = "Steel Ingot",
|
description = "Steel Ingot",
|
||||||
inventory_image = "default_steel_ingot.png",
|
inventory_image = "default_steel_ingot.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizei, y=sizei, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:copper_ingot", {
|
minetest.register_craftitem(":default:copper_ingot", {
|
||||||
description = "Copper Ingot",
|
description = "Copper Ingot",
|
||||||
inventory_image = "default_copper_ingot.png",
|
inventory_image = "default_copper_ingot.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizei, y=sizei, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:bronze_ingot", {
|
minetest.register_craftitem(":default:bronze_ingot", {
|
||||||
description = "Bronze Ingot",
|
description = "Bronze Ingot",
|
||||||
inventory_image = "default_bronze_ingot.png",
|
inventory_image = "default_bronze_ingot.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizei, y=sizei, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:gold_ingot", {
|
minetest.register_craftitem(":default:gold_ingot", {
|
||||||
description = "Gold Ingot",
|
description = "Gold Ingot",
|
||||||
inventory_image = "default_gold_ingot.png",
|
inventory_image = "default_gold_ingot.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizei, y=sizei, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:mese_crystal_fragment", {
|
minetest.register_craftitem(":default:mese_crystal_fragment", {
|
||||||
description = "Mese Crystal Fragment",
|
description = "Mese Crystal Fragment",
|
||||||
inventory_image = "default_mese_crystal_fragment.png",
|
inventory_image = "default_mese_crystal_fragment.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizei, y=sizei, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:clay_brick", {
|
minetest.register_craftitem(":default:clay_brick", {
|
||||||
description = "Clay Brick",
|
description = "Clay Brick",
|
||||||
inventory_image = "default_clay_brick.png",
|
inventory_image = "default_clay_brick.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizei, y=sizei, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:obsidian_shard", {
|
minetest.register_craftitem(":default:obsidian_shard", {
|
||||||
description = "Obsidian Shard",
|
description = "Obsidian Shard",
|
||||||
inventory_image = "default_obsidian_shard.png",
|
inventory_image = "default_obsidian_shard.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizei, y=sizei, z=1},
|
||||||
})
|
})
|
||||||
|
11
lumps.lua
11
lumps.lua
@ -1,8 +1,9 @@
|
|||||||
|
sizel = 1.5
|
||||||
minetest.register_craftitem(":default:coal_lump", {
|
minetest.register_craftitem(":default:coal_lump", {
|
||||||
description = "Coal Lump",
|
description = "Coal Lump",
|
||||||
inventory_image = "default_coal_lump.png",
|
inventory_image = "default_coal_lump.png",
|
||||||
groups = {coal = 1},
|
groups = {coal = 1},
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizel, y=sizel, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
@ -21,23 +22,23 @@ minetest.register_craftitem(":default:iron_lump", {
|
|||||||
minetest.register_craftitem(":default:copper_lump", {
|
minetest.register_craftitem(":default:copper_lump", {
|
||||||
description = "Copper Lump",
|
description = "Copper Lump",
|
||||||
inventory_image = "default_copper_lump.png",
|
inventory_image = "default_copper_lump.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizel, y=sizel, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:mese_crystal", {
|
minetest.register_craftitem(":default:mese_crystal", {
|
||||||
description = "Mese Crystal",
|
description = "Mese Crystal",
|
||||||
inventory_image = "default_mese_crystal.png",
|
inventory_image = "default_mese_crystal.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizel, y=sizel, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:gold_lump", {
|
minetest.register_craftitem(":default:gold_lump", {
|
||||||
description = "Gold Lump",
|
description = "Gold Lump",
|
||||||
inventory_image = "default_gold_lump.png",
|
inventory_image = "default_gold_lump.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizel, y=sizel, z=1},
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craftitem(":default:diamond", {
|
minetest.register_craftitem(":default:diamond", {
|
||||||
description = "Diamond",
|
description = "Diamond",
|
||||||
inventory_image = "default_diamond.png",
|
inventory_image = "default_diamond.png",
|
||||||
wield_scale = {x=1.5, y=1.5, z=1},
|
wield_scale = {x=sizel, y=sizel, z=1},
|
||||||
})
|
})
|
||||||
|
15
swords.lua
15
swords.lua
@ -1,3 +1,6 @@
|
|||||||
|
sizex = 1.5
|
||||||
|
sizey = 2
|
||||||
|
|
||||||
minetest.register_tool(":default:sword_wood", {
|
minetest.register_tool(":default:sword_wood", {
|
||||||
description = "Wooden Sword",
|
description = "Wooden Sword",
|
||||||
inventory_image = "default_tool_woodsword.png",
|
inventory_image = "default_tool_woodsword.png",
|
||||||
@ -9,7 +12,7 @@ minetest.register_tool(":default:sword_wood", {
|
|||||||
},
|
},
|
||||||
damage_groups = {fleshy=2},
|
damage_groups = {fleshy=2},
|
||||||
},
|
},
|
||||||
wield_scale = {x=1.5, y=2, z=1},
|
wield_scale = {x=sizex, y=sizey, z=1},
|
||||||
})
|
})
|
||||||
minetest.register_tool(":default:sword_stone", {
|
minetest.register_tool(":default:sword_stone", {
|
||||||
description = "Stone Sword",
|
description = "Stone Sword",
|
||||||
@ -22,7 +25,7 @@ minetest.register_tool(":default:sword_stone", {
|
|||||||
},
|
},
|
||||||
damage_groups = {fleshy=4},
|
damage_groups = {fleshy=4},
|
||||||
},
|
},
|
||||||
wield_scale = {x=1.5, y=2, z=1},
|
wield_scale = {x=sizex, y=sizey, z=1},
|
||||||
})
|
})
|
||||||
minetest.register_tool(":default:sword_steel", {
|
minetest.register_tool(":default:sword_steel", {
|
||||||
description = "Steel Sword",
|
description = "Steel Sword",
|
||||||
@ -35,7 +38,7 @@ minetest.register_tool(":default:sword_steel", {
|
|||||||
},
|
},
|
||||||
damage_groups = {fleshy=6},
|
damage_groups = {fleshy=6},
|
||||||
},
|
},
|
||||||
wield_scale = {x=1.5, y=2, z=1},
|
wield_scale = {x=sizex, y=sizey, z=1},
|
||||||
})
|
})
|
||||||
minetest.register_tool(":default:sword_bronze", {
|
minetest.register_tool(":default:sword_bronze", {
|
||||||
description = "Bronze Sword",
|
description = "Bronze Sword",
|
||||||
@ -48,7 +51,7 @@ minetest.register_tool(":default:sword_bronze", {
|
|||||||
},
|
},
|
||||||
damage_groups = {fleshy=6},
|
damage_groups = {fleshy=6},
|
||||||
},
|
},
|
||||||
wield_scale = {x=1.5, y=2, z=1},
|
wield_scale = {x=sizex, y=sizey, z=1},
|
||||||
})
|
})
|
||||||
minetest.register_tool(":default:sword_mese", {
|
minetest.register_tool(":default:sword_mese", {
|
||||||
description = "Mese Sword",
|
description = "Mese Sword",
|
||||||
@ -61,7 +64,7 @@ minetest.register_tool(":default:sword_mese", {
|
|||||||
},
|
},
|
||||||
damage_groups = {fleshy=7},
|
damage_groups = {fleshy=7},
|
||||||
},
|
},
|
||||||
wield_scale = {x=1.5, y=2, z=1},
|
wield_scale = {x=sizex, y=sizey, z=1},
|
||||||
})
|
})
|
||||||
minetest.register_tool(":default:sword_diamond", {
|
minetest.register_tool(":default:sword_diamond", {
|
||||||
description = "Diamond Sword",
|
description = "Diamond Sword",
|
||||||
@ -74,5 +77,5 @@ minetest.register_tool(":default:sword_diamond", {
|
|||||||
},
|
},
|
||||||
damage_groups = {fleshy=8},
|
damage_groups = {fleshy=8},
|
||||||
},
|
},
|
||||||
wield_scale = {x=1.5, y=2, z=1},
|
wield_scale = {x=sizex, y=sizey, z=1},
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user