From 7c8137b79f3c0d9d86b9e9b8d0b9322c1026b4ce Mon Sep 17 00:00:00 2001 From: BlockMen Date: Tue, 2 Feb 2016 03:29:35 +0100 Subject: [PATCH] Add chicken meat and feather --- chicken/README.txt | 8 ++--- chicken/init.lua | 30 ++++++++++++++++++- chicken/textures/creatures_chicken_flesh.png | Bin 0 -> 969 bytes chicken/textures/creatures_chicken_meat.png | Bin 0 -> 966 bytes chicken/textures/creatures_feather.png | Bin 0 -> 452 bytes 5 files changed, 33 insertions(+), 5 deletions(-) create mode 100644 chicken/textures/creatures_chicken_flesh.png create mode 100644 chicken/textures/creatures_chicken_meat.png create mode 100644 chicken/textures/creatures_feather.png diff --git a/chicken/README.txt b/chicken/README.txt index 5bc05b0..b1b8b60 100644 --- a/chicken/README.txt +++ b/chicken/README.txt @@ -2,13 +2,13 @@ Chicken for Creatures MOB-Engine ================================ Copyright (c) 2015 BlockMen -Version: 2.0 Beta +Version: 2.1 Beta Adds chicken to Minetest (requires Creatures MOB-Engine). -Chicken spawn on dirt and grass blocks, have 5 HP and are friendly. When killed they -drop meat, which can be eaten or cooked. Also they drop randomly eggs (which have -no real use yet.) +Chicken spawn on dirt and grass blocks, have 5 HP and are friendly. When killed or dying +they drop meat, which can be eaten or cooked and probably some feathers. Also they drop +randomly eggs (which can be thrown to spawn new chicken) License: diff --git a/chicken/init.lua b/chicken/init.lua index cb9b123..45db9b0 100644 --- a/chicken/init.lua +++ b/chicken/init.lua @@ -21,6 +21,7 @@ +-- Egg dofile(core.get_modpath("chicken") .. "/egg.lua") local function dropEgg(obj) local pos = obj:getpos() @@ -29,6 +30,32 @@ local function dropEgg(obj) 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 = { -- general name = "creatures:chicken", @@ -96,7 +123,8 @@ local def = { }, drops = { - {"creatures:flesh"}, + {"creatures:chicken_flesh"}, + {"creatures:feather", {min = 1, max = 2}, chance = 0.45}, }, on_step = function(self, dtime) diff --git a/chicken/textures/creatures_chicken_flesh.png b/chicken/textures/creatures_chicken_flesh.png new file mode 100644 index 0000000000000000000000000000000000000000..770235ccb2363171a567d56633182356182c28f1 GIT binary patch literal 969 zcmV;)12+7LP)z@;j(q!3lK=n!AY({UO#lFTB>(_`g8%^e{{R4h=>PzA zFaQARU;qF*m;eA5Z<1fdMgRZurr zDGbA9IOpu`1JJjw=e53kSwd?~N5@4n`!=rQFg!fWD{XBCXv6RI26BRdW5IwwP@bO~ ze!0MN-_@X%B4ayDXZ$TfYfbc66r~+pt@!qnPergc==T*`#|?D;;`HQ%Gz}c3D9F#F zwE8sbbF;*j*FkFx;MutAi_gVYp=o08g;r-KSC(d`CK_t1@CO1!D$1y6sKZlQ$>yFz zeOn8rgfJl|%-ZG_FTU1^FeNIpi|e`v04)^D1ktLj{R_JbNx)KF{yJbeVO?<&Dj8qbz-^)fQNNg=hIFyZL zc{tnA$@uSoQdaX)R7jZ=T5EcHy0t)X>GDOygTHa3uj84y$DOq}<&l#_gL%ksF{#l% z7@wNuWMgyGarKguGSfzHPq(hBuOd<(;Y7F{)g0x{-JdYZqh;ycU7F5cCKFpgW(WB# zk)-lmOS$V9v3=W3KS-sN0T7K=(%#<1&fXli28O7sZ?^v1+Ix~6$U>MFId69{Fz^HK zz5mhixRtxQnd93YS&j+jMCfFtuKB24mbM;`TF{8LkKiNU>YXU rG%+oSCFKF&c{u`iUA-or*ZF?{%RzJ#P`4hW00000NkvXXu0mjfz|g>- literal 0 HcmV?d00001 diff --git a/chicken/textures/creatures_chicken_meat.png b/chicken/textures/creatures_chicken_meat.png new file mode 100644 index 0000000000000000000000000000000000000000..6e0a10462360d3427790129bb211b65c53fc3854 GIT binary patch literal 966 zcmV;%13CPOP)z@;j(q!3lK=n!AY({UO#lFTB>(_`g8%^e{{R4h=>PzA zFaQARU;qF*m;eA5Z<1fdMgRZ=jZ$Fw=J|#3Y3&m#`xuE z3z4Z|YMg}ZVw}!lycnY~CPR%RJNOUm;K2(AV|3A|H!v}}UAAQLvV(Y;{21aK8B7R2 zMxmv&rBK>_zn`~O8cyG_kw4&sMewfD8D)JofR2%06CnYrE9GFuO3PMHq}=t$^%O=G&^S2s9To^TcmgQhr$vZ`>+!dB10Vn*JXpF%Z9XJi@1?OhL}o9I+hyPhgy`<%>0ItLurGIolwVsX`0NKJ3{qZ<`CnKZ_C35?FtnKFLZEGP_DB<_{ z5CO~Wov$uH;c0ct%=XIiv$1Y!EEA`EjOq5$eC{I2{4s$V3&U~~kM*&zw!?EnFI+H9 zbJYMSy*n&-=YOxfGJ1~kL55&^59RzG8*K@~JyH6)I*9hhDd#iHEZpPFi)SwwmU~Xy zR?3V759HL~DVoAf#A2iPPM_q?YKC}EVrV&+ztmaCaj^M-nx;0^+xvNWeEnd?8^Dn7-{$(%O@@Zgxi*&4^242^ z%-;H0OhaLr21-Qu_KQyi;QPsGWosL8gpb}IkvHFYjcb!P`0~474W$s2!Zb`=rip2} ouw1Sx@TB_>9=klDo|O4_0QY%yI7LxwPXGV_07*qoM6N<$g4JHXod5s; literal 0 HcmV?d00001 diff --git a/chicken/textures/creatures_feather.png b/chicken/textures/creatures_feather.png new file mode 100644 index 0000000000000000000000000000000000000000..99507c6e63d30202763d5a1e75df4635b15043a9 GIT binary patch literal 452 zcmV;#0XzPQP)z@;j(q!3lK=n!AY({UO#lFTB>(_`g8%^e{{R4h=>PzA zFaQARU;qF*m;eA5Z<1fdMgRZ-I!Q!9RCwB?lTA_rF%*P56bE6UZq*y83$^4ToB+;{ z;v#YYteNre2wE$#E3eYSN7m0yoUSO?lfNSzCu=joqhQRv#_yoXoI%RDeYZCz(V;V-uBej;E zoL!vjy(s0JYZ|mEVWn-UG16S-MQD9z2Xz{svss8~6;)uqyuR9wDAr%I16XS*^I|7+ zjBPkSx*Y|_tEyr?uf7HEOd(6szzlFV9{>2yn;t~^opW-|>89H?`_F