From a797e8f42d75f05268ee4c4e0106afc6dcd66be8 Mon Sep 17 00:00:00 2001 From: sys4-fr Date: Tue, 21 Feb 2017 04:36:50 +0100 Subject: [PATCH] Initial commit --- .gitignore | 7 ++--- depends.txt | 2 ++ init.lua | 44 +++++++++++++++++++++++++++ textures/morefarming_carrot.png | Bin 0 -> 181 bytes textures/morefarming_carrot_1.png | Bin 0 -> 105 bytes textures/morefarming_carrot_2.png | Bin 0 -> 112 bytes textures/morefarming_carrot_3.png | Bin 0 -> 112 bytes textures/morefarming_carrot_4.png | Bin 0 -> 119 bytes textures/morefarming_carrot_5.png | Bin 0 -> 122 bytes textures/morefarming_carrot_6.png | Bin 0 -> 126 bytes textures/morefarming_carrot_7.png | Bin 0 -> 127 bytes textures/morefarming_carrot_8.png | Bin 0 -> 145 bytes textures/morefarming_carrot_gold.png | Bin 0 -> 181 bytes textures/morefarming_carrot_seed.png | Bin 0 -> 213 bytes 14 files changed, 49 insertions(+), 4 deletions(-) create mode 100644 depends.txt create mode 100644 init.lua create mode 100644 textures/morefarming_carrot.png create mode 100644 textures/morefarming_carrot_1.png create mode 100644 textures/morefarming_carrot_2.png create mode 100644 textures/morefarming_carrot_3.png create mode 100644 textures/morefarming_carrot_4.png create mode 100644 textures/morefarming_carrot_5.png create mode 100644 textures/morefarming_carrot_6.png create mode 100644 textures/morefarming_carrot_7.png create mode 100644 textures/morefarming_carrot_8.png create mode 100644 textures/morefarming_carrot_gold.png create mode 100644 textures/morefarming_carrot_seed.png diff --git a/.gitignore b/.gitignore index 9b4291b..ff4f8ff 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,4 @@ -# Compiled -*.elc +*.el +*~ +*.autosave -# Packaging -.cask diff --git a/depends.txt b/depends.txt new file mode 100644 index 0000000..29e07c1 --- /dev/null +++ b/depends.txt @@ -0,0 +1,2 @@ +moreflowers +farming diff --git a/init.lua b/init.lua new file mode 100644 index 0000000..039b1c9 --- /dev/null +++ b/init.lua @@ -0,0 +1,44 @@ +-- carrot +minetest.override_item("moreflowers:wild_carrot", + { + drop = { + max_items = 1, + items = { + { items = {"morefarming:seed_carrot"}, rarity = 8}, + { items = {"moreflowers:wild_carrot"}}, + } + }}) + +farming.register_plant("morefarming:carrot", + { + description = "Carrot seed", + paramtype2 = "meshoptions", + inventory_image = "morefarming_carrot_seed.png", + steps = 8, + minlight = 13, + maxlight = default.LIGHT_MAX, + fertility = {"grassland"}, + groups = {flammable = 4}, + place_param2 = 3, + }) + +minetest.override_item("morefarming:carrot", + { + on_use = minetest.item_eat(4) + }) + +-- golden carrot +minetest.register_craftitem("morefarming:carrot_gold", { + description = "Golden Carrot", + inventory_image = "morefarming_carrot_gold.png", + on_use = minetest.item_eat(6), +}) + +minetest.register_craft({ + output = "morefarming:carrot_gold", + recipe = { + {"", "default:gold_lump", ""}, + {"default:gold_lump", "morefarming:carrot", "default:gold_lump"}, + {"", "default:gold_lump", ""}, + } +}) diff --git a/textures/morefarming_carrot.png b/textures/morefarming_carrot.png new file mode 100644 index 0000000000000000000000000000000000000000..3c2da3699c514eb3813dc701a43a25a64b9f5b88 GIT binary patch literal 181 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!73?$#)eFPGa4)6(aoyfp2!B^e1MB-3@?3x%o z=SgyJla$|9xdm-jy(a6o6R3=_B*-tA!Qt7BG$6;r)5S4_<9c!e15+P^z{vwr0tZ;q zG&YzSI5-5bxO6oub7&n})o`vru;qfz%aeQ=J)2S(4Vn$lvaE_YBXFvq*|0@+0Z-b5 aD26&Wj*Q8?llp*WGI+ZBxvX_!@pBkJkm7{YNqIbnf}27_TY^Mr()1O^6{%?!^B(yrtK6)_!@pBkJkm7{YNqIbng!3Wkjx%o7rF5*Qd*lNo+>DBjfsDq!$*^>bP0 Hl+XkKld2s< literal 0 HcmV?d00001 diff --git a/textures/morefarming_carrot_4.png b/textures/morefarming_carrot_4.png new file mode 100644 index 0000000000000000000000000000000000000000..17fe72390a4e758284b2a52aba25f96754ebde1c GIT binary patch literal 119 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!93?!50ihlx9JOMr-uBp1|rX>>2ljMRntIpbY z>?=^5u_VYZn8D%MjWi%f($mE;gyVX0!UB#6hK+8_6B4W#R4mL57#M_ZGsP^Kt5*+H O#Ng@b=d#Wzp$Pyz?;Y^~ literal 0 HcmV?d00001 diff --git a/textures/morefarming_carrot_5.png b/textures/morefarming_carrot_5.png new file mode 100644 index 0000000000000000000000000000000000000000..3e3bc4b071ce74ac649c63571fa912ea2d916c3b GIT binary patch literal 122 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!93?!50ihlx9JOMr-uBp1|rX>>2ljMRntIpbY z>?=^5u_VYZn8D%MjWi%f#?!?ygyVX0f`WJi!$vpd2?bURDi-AooR2wq7?htdXT)WG RxdT+k;OXk;vd$@?2>_ovACv$9 literal 0 HcmV?d00001 diff --git a/textures/morefarming_carrot_6.png b/textures/morefarming_carrot_6.png new file mode 100644 index 0000000000000000000000000000000000000000..471b24553430207c8e5c041b35820d6b149087cb GIT binary patch literal 126 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!93?!50ihlx9JOMr-uBp1|rX>>2ljMRntIpbY z>?=^5u_VYZn8D%MjWi%f!PCVtgyVX0f&y~{!$vpd2?bURDi-AooR2vjnoc${GMMHv VuWB^cPXelC@O1TaS?83{1OOW3AQS)q literal 0 HcmV?d00001 diff --git a/textures/morefarming_carrot_7.png b/textures/morefarming_carrot_7.png new file mode 100644 index 0000000000000000000000000000000000000000..4ad6cf2b29215427e2fb7f59aa072d384df830ed GIT binary patch literal 127 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!93?!50ihlx9JOMr-uBp1|rX>>2ljMRntIpbY z>?=^5u_VYZn8D%MjWi%f(bL5-gyVX0f&y;@!$vpd2?bURDi-AooR2vjnocr0F)(;I WFu!4~QM(6J%;4$j=d#Wzp$Pyr(;!3u literal 0 HcmV?d00001 diff --git a/textures/morefarming_carrot_8.png b/textures/morefarming_carrot_8.png new file mode 100644 index 0000000000000000000000000000000000000000..7c6a8a7990edc32892395f58a824a3ffdb838cb7 GIT binary patch literal 145 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!73?$#)eFPE^4e$wZ%`eI|Es;1BAnQCy?roCt z+bXx9&8l-xC&U01FqQ=Q1v5B2yO9RuXnDFghHzX@PFSFnV9XGFhK;Q!p^c%KDdgA% o9;Ktl(l|sD#T?RiSTS-k#7}1GU)WT=4XBI3)78&qol`;+0OVIH6#xJL literal 0 HcmV?d00001 diff --git a/textures/morefarming_carrot_gold.png b/textures/morefarming_carrot_gold.png new file mode 100644 index 0000000000000000000000000000000000000000..5a2cc91584f2189cf4241f8aae3ec35604d31ddb GIT binary patch literal 181 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!73?$#)eFPGa4)6(aHDq8gEs=1ZBsZx`Eoigq z;aReCHfp|osQm7~Y0)8TFQ78Uk|4ie28U-i(tsQfPZ!4!j_b(@3`}CI0w)hFS#W?O zjl;mwz@cFgmrGZxtDx2)m4v;Mo0Y|D0(+GZ{Qx{an^LB{Ts5Vs0goONr28L9L!GV*|g1ABR&6@`$bOa6^c)+oQA(cVEsB>*(B+yO