kfodskfos

This commit is contained in:
Kacper Kostka
2023-01-12 19:03:24 +01:00
parent 343886f6ee
commit 342c05749e
8 changed files with 42 additions and 28 deletions

View File

@@ -101,26 +101,31 @@ minetest.register_tool("amogus_items:lightsaber_green", {
sound = {breaks = "amogus_sound"},
})
-- add lucky block with array of loot that can be easly edited
local loot = {
"amogus_items:amogus",
"amogus_items:sprite",
"amogus_items:coke",
"amogus_items:fanta",
"amogus_items:tomato",
"amogus_items:lightsaber_blue",
"amogus_items:lightsaber_red",
"amogus_items:lightsaber_green",
}
-- add theese items : goldenpickaxe, wooden plank, gold_ingot, sussium_ingot
minetest.register_craftitem("amogus_items:wooden_plank", {
description = "Wooden Plank",
inventory_image = "wooden_plank.png",
})
minetest.register_craftitem("amogus_items:gold_ingot", {
description = "Gold Ingot",
inventory_image = "gold_ingot.png",
})
minetest.register_craftitem("amogus_items:sussium_ingot", {
description = "Sussium Ingot",
inventory_image = "sussium_ingot.png",
})
minetest.register_node("amogus_items:lucky_block", {
description = "Lucky Block",
tiles = {"luckyblock.png"},
groups = {cracky = 3},
on_punch = function(pos, node, puncher, pointed_thing)
local item = loot[math.random(#loot)]
minetest.add_item(pos, item)
minetest.remove_node(pos)
end
})
minetest.register_tool("amogus_items:goldenpickaxe", {
description = "Golden Pickaxe",
inventory_image = "goldenpickaxe.png",
tool_capabilities = {
full_punch_interval = 0.1,
max_drop_level=3,
groupcaps={
cracky={times={[1]=0.1, [2]=0.1, [3]=0.1}, uses=0, maxlevel=3},
},
damage_groups = {fleshy=10},
},
sound = {breaks = "amogus_sound"},
})

Binary file not shown.

After

Width:  |  Height:  |  Size: 204 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 149 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 209 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 142 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 160 B