Use 'spawneggs' & 'tnt' to craft 'creeper:spawnegg'

This commit is contained in:
AntumDeluge 2017-05-13 03:42:48 -07:00 committed by Jordan Irwin
parent 84f6c2f3c9
commit 9d4581ec5b
2 changed files with 25 additions and 14 deletions

@ -342,7 +342,8 @@ end
minetest.register_entity("creeper:creeper",def) minetest.register_entity("creeper:creeper",def)
minetest.register_craftitem("creeper:spawnegg",{ if minetest.global_exists("spawneggs") then
minetest.register_craftitem("creeper:spawnegg",{
description = "Creeper Spawn Egg", description = "Creeper Spawn Egg",
inventory_image = "creeper_spawnegg.png", inventory_image = "creeper_spawnegg.png",
stack_max = 64, stack_max = 64,
@ -357,4 +358,13 @@ minetest.register_craftitem("creeper:spawnegg",{
return itemstack return itemstack
end end
end end
}) })
minetest.register_craft({
output = "creeper:spawnegg",
type = "shapeless",
recipe = {"spawneggs:egg", "tnt:tnt",},
})
minetest.register_alias("spawneggs:creeper", "creeper:spawnegg")
end

@ -3,3 +3,4 @@ title = Creeper
description = Adds some explosive nuisance. description = Adds some explosive nuisance.
author = Rui author = Rui
depends = default, tnt depends = default, tnt
optional_depends = spawneggs