Add chicken meat and feather
parent
8ed84e7793
commit
7c8137b79f
|
@ -2,13 +2,13 @@ Chicken for Creatures MOB-Engine
|
||||||
================================
|
================================
|
||||||
Copyright (c) 2015 BlockMen <blockmen2015@gmail.com>
|
Copyright (c) 2015 BlockMen <blockmen2015@gmail.com>
|
||||||
|
|
||||||
Version: 2.0 Beta
|
Version: 2.1 Beta
|
||||||
|
|
||||||
|
|
||||||
Adds chicken to Minetest (requires Creatures MOB-Engine).
|
Adds chicken to Minetest (requires Creatures MOB-Engine).
|
||||||
Chicken spawn on dirt and grass blocks, have 5 HP and are friendly. When killed they
|
Chicken spawn on dirt and grass blocks, have 5 HP and are friendly. When killed or dying
|
||||||
drop meat, which can be eaten or cooked. Also they drop randomly eggs (which have
|
they drop meat, which can be eaten or cooked and probably some feathers. Also they drop
|
||||||
no real use yet.)
|
randomly eggs (which can be thrown to spawn new chicken)
|
||||||
|
|
||||||
|
|
||||||
License:
|
License:
|
||||||
|
|
|
@ -21,6 +21,7 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
-- Egg
|
||||||
dofile(core.get_modpath("chicken") .. "/egg.lua")
|
dofile(core.get_modpath("chicken") .. "/egg.lua")
|
||||||
local function dropEgg(obj)
|
local function dropEgg(obj)
|
||||||
local pos = obj:getpos()
|
local pos = obj:getpos()
|
||||||
|
@ -29,6 +30,32 @@ local function dropEgg(obj)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- Flesh
|
||||||
|
core.register_craftitem(":creatures:chicken_flesh", {
|
||||||
|
description = "Raw Chicken Flesh",
|
||||||
|
inventory_image = "creatures_chicken_flesh.png",
|
||||||
|
on_use = core.item_eat(1)
|
||||||
|
})
|
||||||
|
|
||||||
|
core.register_craftitem(":creatures:chicken_meat", {
|
||||||
|
description = "Chicken Meat",
|
||||||
|
inventory_image = "creatures_chicken_meat.png",
|
||||||
|
on_use = core.item_eat(3)
|
||||||
|
})
|
||||||
|
|
||||||
|
core.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "creatures:chicken_meat",
|
||||||
|
recipe = "creatures:chicken_flesh",
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Feather
|
||||||
|
core.register_craftitem(":creatures:feather", {
|
||||||
|
description = "Feather",
|
||||||
|
inventory_image = "creatures_feather.png",
|
||||||
|
on_use = core.item_eat(3)
|
||||||
|
})
|
||||||
|
|
||||||
local def = {
|
local def = {
|
||||||
-- general
|
-- general
|
||||||
name = "creatures:chicken",
|
name = "creatures:chicken",
|
||||||
|
@ -96,7 +123,8 @@ local def = {
|
||||||
},
|
},
|
||||||
|
|
||||||
drops = {
|
drops = {
|
||||||
{"creatures:flesh"},
|
{"creatures:chicken_flesh"},
|
||||||
|
{"creatures:feather", {min = 1, max = 2}, chance = 0.45},
|
||||||
},
|
},
|
||||||
|
|
||||||
on_step = function(self, dtime)
|
on_step = function(self, dtime)
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 969 B |
Binary file not shown.
After Width: | Height: | Size: 966 B |
Binary file not shown.
After Width: | Height: | Size: 452 B |
Loading…
Reference in New Issue