Advertisement
Silhouhat

cook_recipes.lua

Jun 21st, 2017
847
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 4.71 KB | None | 0 0
  1. SILCOOK = SILCOOK or {}
  2. SILCOOK.Config = SILCOOK.Config or {}
  3.  
  4. --[[-------------------------------------------------------------------------
  5.     ===[ EXPLANATION OF REWARDS SYSTEM ]===
  6.         There are four things that your recipe can give the player.
  7.             1) A cook_food entity.
  8.             2) A cook_ingredient entity.
  9.             3) A custom entity.
  10.             4) Money
  11.         These four require a different configuration.
  12.         You will find examples of the configuration methods in the same order as above below:
  13.             1)
  14.                 food = {
  15.                     model = "models/foodnhouseholditems/burgersims2.mdl", -- Model of the entity
  16.                     hunger = 25, -- Hunger given
  17.                 },
  18.             2)
  19.                 food = { "cook_ingredient", "INGREDIENT NAME" } -- Must exit in cook_config.lua
  20.             3)
  21.                 food = "CLASSNAME" -- Replace "CLASSNAME" with your desired entity's class.
  22.             4)
  23.                 food = 100 -- Replace "100" with your desired money amount given upon the recipe's completion.
  24. ---------------------------------------------------------------------------]]
  25.  
  26. SILCOOK.Config.Recipes = {
  27.     ["Cheeseburger"] = { -- This is the name of your recipe.
  28.         ingredients = { -- Add your ingredients under this table.
  29.             ["Bread Slice"] = 2, -- Enter the name of your ingredient or class name as designated in the cook_config.lua ingredient configuration and the amount required.
  30.             ["Cheese"] = 1, -- The amount required MUST be a multiple of the amount given by the ingredient or else it will be impossible to cook/bake this.
  31.             ["Lettuce"] = 2,
  32.             ["Raw Beef"] = 2,
  33.             ["Ketchup"] = 1,
  34.             --["sent_ball"] = 2, -- Example of a custom entity as an ingredient
  35.         },
  36.         cookedEnough = { 15, 30 }, -- Minimum & maximum time for the recipe to be cooked in order to give out the correct reward instead of mush.
  37.         cookers = { "cook_pot" }, -- Table of the cooking devices that this will work on. Currently there is only "cook_pot" and "cook_tray", for the cooking pot & baking tray.
  38.         food = { -- Explained above
  39.             model = "models/foodnhouseholditems/burgersims2.mdl",
  40.             hunger = 40,
  41.         },
  42.     },
  43.  
  44.     ["Double Cheeseburger"] = {
  45.         ingredients = {
  46.             ["Bread"] = 3,
  47.             ["Cheese"] = 2,
  48.             ["Lettuce"] = 6,
  49.             ["Raw Beef"] = 4,
  50.             ["Ketchup"] = 2,
  51.         },
  52.         cookedEnough = function( time, ply ) -- Example of a function cookedEnough configuration.
  53.             return ( time >= 30 and time < 45 )
  54.         end,
  55.         cookers = { "cook_pot" },
  56.         food = {
  57.             model = "models/foodnhouseholditems/mcdburger.mdl",
  58.             hunger = 80,
  59.         },
  60.     },
  61.  
  62.     ["Meth"] = {
  63.         ingredients = {
  64.             ["Lighter Fluid"] = 6,
  65.             ["Methylamine"] = 5,
  66.             ["sent_ball"] = 2,
  67.         },
  68.         cookedEnough = { 30, 40 },
  69.         cookers = { "cook_pot" },
  70.         food = 1000, -- Example of a money payout
  71.     },
  72.  
  73.     ["Turkey"] = {
  74.         ingredients = {
  75.             ["Raw Turkey"] = 1,
  76.             ["Lettuce"] = 3,
  77.         },
  78.         cookedEnough = { 15, 30 },
  79.         cookers = { "cook_tray" },
  80.         food = {
  81.             model = "models/foodnhouseholditems/turkey2.mdl",
  82.             hunger = 100,
  83.         },
  84.     },
  85.  
  86.     ["Vanilla Cake"] = {
  87.         ingredients = {
  88.             ["Egg"] = 3,
  89.             ["Flour"] = 2,
  90.             ["Vanilla Frosting"] = 4,
  91.             ["Milk"] = 2,
  92.         },
  93.         cookedEnough = { 285, 315 },
  94.         cookers = { "cook_tray" },
  95.         food = {
  96.             model = "models/foodnhouseholditems/cake.mdl",
  97.             hunger = 100,
  98.         }
  99.     },
  100.  
  101.     ["Chocolate Cake"] = {
  102.         ingredients = {
  103.             ["Egg"] = 3,
  104.             ["Flour"] = 2,
  105.             ["Chocolate Frosting"] = 4,
  106.             ["Milk"] = 2,
  107.         },
  108.         cookedEnough = { 285, 315 },
  109.         cookers = { "cook_tray" },
  110.         food = {
  111.             model = "models/foodnhouseholditems/cake_b.mdl",
  112.             hunger = 100,
  113.         }
  114.     },
  115.  
  116.     ["Pancake"] = {
  117.         ingredients = {
  118.             ["Flour"] = 1,
  119.             ["Salt"] = 1,
  120.             ["Sugar"] = 2,
  121.             ["Egg"] = 1,
  122.         },
  123.         cookedEnough = { 50, 70 },
  124.         cookers = { "cook_pot" },
  125.         food = {
  126.             model = "models/foodnhouseholditems/pancake.mdl",
  127.             hunger = 20,
  128.         }
  129.     },
  130.  
  131.     ["Bunch of Pancakes"] = {
  132.         ingredients = {
  133.             ["Flour"] = 3,
  134.             ["Salt"] = 3,
  135.             ["Sugar"] = 6,
  136.             ["Egg"] = 3,
  137.         },
  138.         cookedEnough = { 170, 190 },
  139.         cookers = { "cook_pot" },
  140.         food = {
  141.             model = "models/foodnhouseholditems/pancake.mdl",
  142.             hunger = 60,
  143.         }
  144.     },
  145.  
  146.     ["Steak"] = {
  147.         ingredients = {
  148.             ["Raw Steak"] = 1,
  149.             ["Salt"] = 1,
  150.         },
  151.         cookedEnough = { 110, 130 },
  152.         cookers = { "cook_tray" },
  153.         food = {
  154.             model = "models/foodnhouseholditems/steak2.mdl",
  155.             hunger = 60,
  156.         }
  157.     },
  158.  
  159.     ["Lobster"] = {
  160.         ingredients = {
  161.             ["Raw Lobster"] = 1,
  162.             ["Salt"] = 1,
  163.         },
  164.         cookedEnough = { 110, 130 },
  165.         cookers = { "cook_tray" },
  166.         fook = {
  167.             model = "models/foodnhouseholditems/lobster2.mdl",
  168.             hunger = 60,
  169.         },
  170.     },
  171.  
  172.     ["Pizza"] = {
  173.         ingredients = {
  174.             ["Cheese"] = 3,
  175.             ["Dough"] = 3,
  176.             ["Flour"] = 2,
  177.             ["Ketchup"] = 3,
  178.         },
  179.         cookedEnough = { 170, 190 },
  180.         cookers = { "cook_tray" },
  181.         fook = {
  182.             model = "models/foodnhouseholditems/pizza.mdl",
  183.             hunger = 40,
  184.         },
  185.     },
  186. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement