diff --git a/README.md b/README.md index 5ef53de..3151f07 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,33 @@ -BBQ v1.0 by Grizzly Adam +BBQ v1.01 by Grizzly Adam https://forum.minetest.net/viewtopic.php?f=9&t=19324 -https://github.com/Grizzly-Adam/BBQ-MINETEST- +https://github.com/Grizzly-Adam/BBQ + +New In This Version +------------------- +Bug Fix: All Colours of Sheep Now Drop Mutton + +Added support for Farming Redo + +New Items: + Wood Pile (can store trees, wood slabs, and sticks) + Smoker Blue Print (wall hanging) + Yeast (Can be found when harvesting grass and jungle grass) + Bacon Cheeseburger + + +Updated Textures: + Raw Mutton + Cooked Mutton + Raw Leg of Lamb + Cooked Leg of Lamb + Sugar + Brine + Hotdog + Hamburger + + Goals ----- @@ -28,7 +53,7 @@ Exceptions: * Tomato image taken from Rubenwardy's Food Mod * Beef designs taken from Daniel_Smith, some were further modified -* Other meats, hotdog, sugar and Beef Map images were found through internet searches and modified, some more severely than others. +* All other textures created by Grizzly Adam Have I missed out credit? Please tell me. diff --git a/cooking.lua b/cooking.lua index ed4842d..9346e2e 100644 --- a/cooking.lua +++ b/cooking.lua @@ -21,6 +21,16 @@ minetest.register_craft( { } }) +--Smoker Blueprint Recipe +minetest.register_craft( { + output = "bbq:smoker_blueprint", + recipe = { + {"group:wood", "group:wood", "group:wood"}, + {"group:wood", "dye:blue", "group:wood"}, + {"group:wood", "group:wood", "group:wood"}, + } +}) + --Leg of Lamb Craft Recipe minetest.register_craft( { output = "bbq:rack_lamb_raw", @@ -67,7 +77,7 @@ minetest.register_craft( { recipe = { {"", "", ""}, {"", "", ""}, - {"bbq:bbq_sauce", "bbq:beef_raw", "bbq:pepper_ground"} + {"bbq:bbq_sauce", "bbq:beef_raw", "group:pepper_ground"} } }) @@ -77,7 +87,17 @@ minetest.register_craft( { recipe = { {"", "", ""}, {"", "", ""}, - {"bbq:hot_sauce", "mobs:chicken_raw", "bbq:pepper_ground"} + {"bbq:hot_sauce", "mobs:chicken_raw", "group:pepper_ground"} + } +}) + +--Bacon Cheeseburger Craft Recipe +minetest.register_craft( { + output = "bbq:bacon_cheeseburger", + recipe = { + {"", "farming:bread", ""}, + {"bbq:bacon", "bbq:beef", "group:cheese"}, + {"", "farming:bread", ""} } }) diff --git a/crafts.lua b/crafts.lua index 78d3135..117ef16 100644 --- a/crafts.lua +++ b/crafts.lua @@ -82,6 +82,13 @@ minetest.register_craftitem("bbq:hot_wings", { on_use = minetest.item_eat(9), }) +-- Bacon Cheeseburger +minetest.register_craftitem("bbq:bacon_cheeseburger", { + description = ("Bacon Cheeseburger"), + inventory_image = "bbq_bacon_cheeseburger.png", + on_use = minetest.item_eat(9), +}) + -- Hamburger minetest.register_craftitem("bbq:hamburger", { description = ("Hamburger"), @@ -281,6 +288,40 @@ minetest.register_node("bbq:beef_map", { sounds = default.node_sound_wood_defaults(), }) +minetest.register_node("bbq:smoker_blueprint", { + description = "Beef Map", + inventory_image = "bbq_smoker_blueprint.png", + tiles = { + "default_pine_wood.png", "default_pine_wood.png", + "default_pine_wood.png", "default_pine_wood.png", + "default_pine_wood.png", "bbq_smoker_blueprint.png", + }, + + paramtype2 = "facedir", + paramtype = "light", + drawtype = "nodebox", + node_box = { + type = "fixed", + fixed = { + {-0.5, -0.5, 0.4, 0.5, 0.5, 0.5}, + + }, + }, + groups = {choppy=3, oddly_breakable_by_hand=2, flammable=3}, + sounds = default.node_sound_wood_defaults(), +}) + +-- Yeast +minetest.register_node("bbq:yeast", { + description = ("Yeast"), + inventory_image = "bbq_yeast.png", + wield_image = "bbq_yeast.png", + drawtype = "plantlike", + tiles = {"bbq_yeast.png"}, + groups = {vessel = 1, dig_immediate = 3, attached_node = 1}, + sounds = default.node_sound_glass_defaults(), +}) + ------------------- --Animal Drop Meats ------------------- diff --git a/description.txt b/description.txt index 98798d0..c1c3dfc 100644 --- a/description.txt +++ b/description.txt @@ -3,9 +3,9 @@ A BBQ add-on for Minetest. Depends on (and expands upon) Mobs-Redo and it's animals add-ons. Causes cows to drop beef and lambs to drop button. -Play's nice with Crops and Food addons. Can use tomatos, cheese, sugar, and honey from Crops, Food, and Mobs-Redo add-ons. Also compatible with my expansion of the Crops add-on (adds peppers, peppercorns, and ground pepper to the Crops add-on, all are present in this addon but without the actual pepper plant). +Play's nice with Crops, Food, and Farming Redo addons. Can use tomatos, chili peppers, cheese, sugar, and honey from Crops, Food, Farming Redo, and Mobs-Redo add-ons. Also compatible with my expansion of the Crops add-on (adds peppers, peppercorns, and ground pepper to the Crops add-on, all are present in this addon but without the actual pepper plant). -Upgrades the BTUs of wood and wood planks in a realistic way when used in furnaces (including the smoker). +Upgrades the BTUs of wood and wood planks in a realistic way when used in furnaces (including the smoker). Allows trees, slabs, and sticks to be stored in woodpile. All spices and sauces can be placed on the vessels shelf. Also added support for placing the bucket in the vessels shelf. @@ -13,11 +13,14 @@ Adds the following items: Smoker Beef Map (Wall Hanging) +Smoker Blueprint (Wall Hanging) +Wood Pile Peppercorn Ground Pepper Sea Salt Sugar +Yeast (Can be found when harvesting grass and jungle grass) Bell Pepper Tomato @@ -36,6 +39,7 @@ BBQ Chicken (Raw & Cooked) BBQ Beef Ribs (Raw & Cooked) Hot Wings (Raw & Cooked) Hamburger +Bacon Cheeseburger Hot Dog Beef Jerky (Raw & Cooked) Pepper Steak (Raw & Cooked) diff --git a/init.lua b/init.lua index 72cc66a..e0b99ec 100644 --- a/init.lua +++ b/init.lua @@ -2,3 +2,4 @@ dofile(minetest.get_modpath("bbq").."/cooking.lua") dofile(minetest.get_modpath("bbq").."/crafts.lua") dofile(minetest.get_modpath("bbq").."/smoker.lua") dofile(minetest.get_modpath("bbq").."/overrides.lua") +dofile(minetest.get_modpath("bbq").."/woodpile.lua") diff --git a/overrides.lua b/overrides.lua index 0358917..50c00eb 100644 --- a/overrides.lua +++ b/overrides.lua @@ -7,14 +7,40 @@ if minetest.registered_items["food:tomato"] ~= nil then minetest.override_item("food:tomato", { groups = {tomato=1}, }) +end + +if minetest.registered_items["food:cheese"] ~= nil then minetest.override_item("food:cheese", { groups = {cheese=1}, }) +end +if minetest.registered_items["food:sugar"] ~= nil then minetest.override_item("food:sugar", { groups = {sugar=1}, }) +end + +--------------------------------------------------------- + +-----CHECK FOR FARMING REDO ADDON------------------------------- +if minetest.registered_items["farming:chili_pepper"] ~= nil then +minetest.override_item("farming:chili_pepper", { + groups = {pepper=1}, +}) +end + +if minetest.registered_items["farming:sugar"] ~= nil then +minetest.override_item("farming:sugar", { + groups = {sugar=1}, +}) +end + +if minetest.registered_items["farming:tomato"] ~= nil then +minetest.override_item("farming:tomato", { + groups = {tomato=1}, +}) end --------------------------------------------------------- @@ -27,45 +53,133 @@ minetest.override_item("mobs:cheese", { groups = {cheese=1}, }) - - ---------- ---Aliases ---------- -minetest.register_alias("crops:tomato", "bbq:tomato") -minetest.register_alias("food:tomato", "bbq:tomato") - - -minetest.register_alias("mobs:cheese", "bbq:cheese") -minetest.register_alias("food:cheese", "bbq:cheese") - -minetest.register_alias("crops:pepper", "bbq:pepper") - - -minetest.register_alias("crops:peppercorn", "bbq:peppercorn") - -minetest.register_alias("crops:pepper_ground", "bbq:pepper_ground") - -minetest.register_alias("crops:pepper", "bbq:pepper") - -minetest.register_alias("food:sugar", "bbq:sugar") - - --------------------------------- --UPGRADE MEAT DROPS IN MOBS REDO --------------------------------- + +local def = minetest.registered_entities["mobs_animal:sheep_black"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_blue"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_brown"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_cyan"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_dark_green"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_dark_grey"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_green"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_grey"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_magenta"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_orange"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_pink"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_red"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + +local def = minetest.registered_entities["mobs_animal:sheep_violet"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + local def = minetest.registered_entities["mobs_animal:sheep_white"] assert(def, "mobs:sheep not found") def.drops = { {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, } +local def = minetest.registered_entities["mobs_animal:sheep_yellow"] +assert(def, "mobs:sheep not found") +def.drops = { + {name = "bbq:mutton_raw", chance = 1, min = 1, max = 2 }, +} + + + local def = minetest.registered_entities["mobs_animal:cow"] assert(def, "mobs:cow not found") def.drops = { {name = "bbq:beef_raw", chance = 1, min = 1, max = 3}, {name = "mobs:leather", chance = 1, min = 1, max = 2}, } + +------------------------------- +--MAKE YEAST NATURALLY OCCURING +------------------------------- + +for i = 1, 5 do + minetest.override_item("default:grass_"..i, {drop = { + max_items = 1, + items = { + {items = {'farming:seed_wheat'},rarity = 5}, + {items = {'bbq:yeast'},rarity = 8}, + {items = {'default:grass_1'}}, + } + }}) +end + +minetest.override_item("default:junglegrass", {drop = { + max_items = 1, + items = { + {items = {'farming:seed_cotton'},rarity = 8}, + {items = {'bbq:yeast'},rarity = 8}, + {items = {'default:junglegrass'}}, + } +}}) + ----------------------------------------------- --MAKE VESSEL TYPE ITEMS WORK WITH VESSEL SHELF ----------------------------------------------- @@ -147,3 +261,75 @@ minetest.register_craft({ recipe = "stairs:slab_aspen_wood", burntime = 7, }) + +minetest.register_craft({ + type = "fuel", + recipe = "default:stick", + burntime = 2, +}) + +-------------------------------------------------- +--ADD WOOD SLABWOOD, TREES AND STICKS TO WOOD PILE +-------------------------------------------------- +minetest.override_item("default:wood", { + groups = {wood_pile=1, wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:aspen_wood", { + groups = {wood_pile=1, wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:junglewood", { + groups = {wood_pile=1, wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:acacia_wood", { + groups = {wood_pile=1, wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:pine_wood", { + groups = {wood_pile=1, wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) +minetest.override_item("stairs:slab_wood", { + groups = {wood_pile=1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("stairs:slab_aspen_wood", { + groups = {wood_pile=1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("stairs:slab_junglewood", { + groups = {wood_pile=1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("stairs:slab_acacia_wood", { + groups = {wood_pile=1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("stairs:slab_pine_wood", { + groups = {wood_pile=1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:tree", { + groups = {wood_pile=1, tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:aspen_tree", { + groups = {wood_pile=1, tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:jungletree", { + groups = {wood_pile=1, tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:acacia_tree", { + groups = {wood_pile=1, tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:pine_tree", { + groups = {wood_pile=1, tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2}, +}) + +minetest.override_item("default:stick", { + groups = {wood_pile=1, stick = 1, flammable = 2}, +}) diff --git a/textures/bbq_bacon_cheeseburger.png b/textures/bbq_bacon_cheeseburger.png new file mode 100644 index 0000000..7376e03 Binary files /dev/null and b/textures/bbq_bacon_cheeseburger.png differ diff --git a/textures/bbq_brine.png b/textures/bbq_brine.png index c8e9ca3..8743262 100644 Binary files a/textures/bbq_brine.png and b/textures/bbq_brine.png differ diff --git a/textures/bbq_ham.png b/textures/bbq_ham.png index 242f7b9..92a8735 100644 Binary files a/textures/bbq_ham.png and b/textures/bbq_ham.png differ diff --git a/textures/bbq_ham_raw.png b/textures/bbq_ham_raw.png index c241d74..66fcf35 100644 Binary files a/textures/bbq_ham_raw.png and b/textures/bbq_ham_raw.png differ diff --git a/textures/bbq_hamburger.png b/textures/bbq_hamburger.png index 54eb362..dbc5816 100644 Binary files a/textures/bbq_hamburger.png and b/textures/bbq_hamburger.png differ diff --git a/textures/bbq_hotdog.png b/textures/bbq_hotdog.png index a123449..49d7d21 100644 Binary files a/textures/bbq_hotdog.png and b/textures/bbq_hotdog.png differ diff --git a/textures/bbq_leg_lamb.png b/textures/bbq_leg_lamb.png index 8fa7bf7..5505c1f 100644 Binary files a/textures/bbq_leg_lamb.png and b/textures/bbq_leg_lamb.png differ diff --git a/textures/bbq_leg_lamb_raw.png b/textures/bbq_leg_lamb_raw.png index 52dae70..4b8b9ca 100644 Binary files a/textures/bbq_leg_lamb_raw.png and b/textures/bbq_leg_lamb_raw.png differ diff --git a/textures/bbq_liquid_smoke.png b/textures/bbq_liquid_smoke.png index 438a061..f8ef5fd 100644 Binary files a/textures/bbq_liquid_smoke.png and b/textures/bbq_liquid_smoke.png differ diff --git a/textures/bbq_mutton_cooked.png b/textures/bbq_mutton_cooked.png index eac7389..28a49fc 100644 Binary files a/textures/bbq_mutton_cooked.png and b/textures/bbq_mutton_cooked.png differ diff --git a/textures/bbq_mutton_raw.png b/textures/bbq_mutton_raw.png index 15454c2..c05bce0 100644 Binary files a/textures/bbq_mutton_raw.png and b/textures/bbq_mutton_raw.png differ diff --git a/textures/bbq_smoker_blueprint.png b/textures/bbq_smoker_blueprint.png new file mode 100644 index 0000000..fe3b033 Binary files /dev/null and b/textures/bbq_smoker_blueprint.png differ diff --git a/textures/bbq_sugar.png b/textures/bbq_sugar.png index e58aa4c..fef753b 100644 Binary files a/textures/bbq_sugar.png and b/textures/bbq_sugar.png differ diff --git a/textures/bbq_wood_pile_front.png b/textures/bbq_wood_pile_front.png new file mode 100644 index 0000000..306f741 Binary files /dev/null and b/textures/bbq_wood_pile_front.png differ diff --git a/textures/bbq_wood_pile_side.png b/textures/bbq_wood_pile_side.png new file mode 100644 index 0000000..52c9de9 Binary files /dev/null and b/textures/bbq_wood_pile_side.png differ diff --git a/textures/bbq_wood_pile_slot.png b/textures/bbq_wood_pile_slot.png new file mode 100644 index 0000000..7bda235 Binary files /dev/null and b/textures/bbq_wood_pile_slot.png differ diff --git a/textures/bbq_wood_pile_top.png b/textures/bbq_wood_pile_top.png new file mode 100644 index 0000000..3344e8d Binary files /dev/null and b/textures/bbq_wood_pile_top.png differ diff --git a/textures/bbq_yeast.png b/textures/bbq_yeast.png new file mode 100644 index 0000000..502c629 Binary files /dev/null and b/textures/bbq_yeast.png differ diff --git a/woodpile.lua b/woodpile.lua new file mode 100644 index 0000000..35e3b1a --- /dev/null +++ b/woodpile.lua @@ -0,0 +1,94 @@ +-- Minetest 0.4 mod: bbq +-- See README.txt for licensing and other information. + +local bbq_wood_pile_formspec = + "size[8,7;]" .. + default.gui_bg .. + default.gui_bg_img .. + default.gui_slots .. + "list[context;bbq;0,0.3;8,2;]" .. + "list[current_player;main;0,2.85;8,1;]" .. + "list[current_player;main;0,4.08;8,3;8]" .. + "listring[context;bbq]" .. + "listring[current_player;main]" .. + default.get_hotbar_bg(0, 2.85) + +local function get_bbq_wood_pile_formspec(inv) + local formspec = bbq_wood_pile_formspec + local invlist = inv and inv:get_list("bbq") + -- Inventory slots overlay + local vx, vy = 0, 0.3 + for i = 1, 16 do + if i == 9 then + vx = 0 + vy = vy + 1 + end + if not invlist or invlist[i]:is_empty() then + formspec = formspec .. + "image[" .. vx .. "," .. vy .. ";1,1;bbq_wood_pile_slot.png]" + end + vx = vx + 1 + end + return formspec +end + +minetest.register_node("bbq:wood_pile", { + description = "Wood Pile", + tiles = {"bbq_wood_pile_top.png", "bbq_wood_pile_top.png", "bbq_wood_pile_side.png", + "bbq_wood_pile_side.png", "bbq_wood_pile_front.png", "bbq_wood_pile_front.png"}, + paramtype2 = "facedir", + is_ground_content = false, + groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3}, + sounds = default.node_sound_wood_defaults(), + + on_construct = function(pos) + local meta = minetest.get_meta(pos) + meta:set_string("formspec", get_bbq_wood_pile_formspec(nil)) + local inv = meta:get_inventory() + inv:set_size("bbq", 8 * 2) + end, + can_dig = function(pos,player) + local inv = minetest.get_meta(pos):get_inventory() + return inv:is_empty("bbq") + end, + allow_metadata_inventory_put = function(pos, listname, index, stack, player) + if minetest.get_item_group(stack:get_name(), "wood_pile") ~= 0 then + return stack:get_count() + end + return 0 + end, + on_metadata_inventory_move = function(pos, from_list, from_index, to_list, to_index, count, player) + minetest.log("action", player:get_player_name() .. + " moves stuff in bbq wood_pile at ".. minetest.pos_to_string(pos)) + local meta = minetest.get_meta(pos) + meta:set_string("formspec", get_bbq_wood_pile_formspec(meta:get_inventory())) + end, + on_metadata_inventory_put = function(pos, listname, index, stack, player) + minetest.log("action", player:get_player_name() .. + " moves stuff to bbq wood_pile at ".. minetest.pos_to_string(pos)) + local meta = minetest.get_meta(pos) + meta:set_string("formspec", get_bbq_wood_pile_formspec(meta:get_inventory())) + end, + on_metadata_inventory_take = function(pos, listname, index, stack, player) + minetest.log("action", player:get_player_name() .. + " takes stuff from bbq wood_pile at ".. minetest.pos_to_string(pos)) + local meta = minetest.get_meta(pos) + meta:set_string("formspec", get_bbq_wood_pile_formspec(meta:get_inventory())) + end, + on_blast = function(pos) + local drops = {} + default.get_inventory_drops(pos, "bbq", drops) + drops[#drops + 1] = "bbq:wood_pile" + minetest.remove_node(pos) + return drops + end, +}) + +minetest.register_craft({ + output = "bbq:wood_pile", + recipe = { + {"group:wood", "group:wood", "group:wood"}, + {"group:wood", "group:wood", "group:wood"}, + {"group:wood", "group:wood", "group:wood"}, + } +})