mirror of
https://github.com/SPLURT-Station/S.P.L.U.R.T-Station-13.git
synced 2025-12-10 09:54:52 +00:00
Adds Sticks of Butter, Mayonnaise, and Mix function to grinder (#896)
This commit is contained in:
committed by
kevinz000
parent
4e51020ec1
commit
4a818bee1f
@@ -23,7 +23,8 @@
|
||||
"sodiumchloride" = list("saltshakersmall", "salt shaker", "Salt. From space oceans, presumably"),
|
||||
"blackpepper" = list("peppermillsmall", "pepper mill", "Often used to flavor food or make people sneeze"),
|
||||
"cornoil" = list("oliveoil", "corn oil bottle", "A delicious oil used in cooking. Made from corn"),
|
||||
"sugar" = list("emptycondiment", "sugar bottle", "Tasty spacey sugar!"))
|
||||
"sugar" = list("emptycondiment", "sugar bottle", "Tasty spacey sugar!"),
|
||||
"mayonnaise" = list("mayonnaise", "mayonnaise jar", "An oily condiment made from egg yolks."))
|
||||
var/originalname = "condiment" //Can't use initial(name) for this. This stores the name set by condimasters.
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/condiment/attack(mob/M, mob/user, def_zone)
|
||||
@@ -207,6 +208,13 @@
|
||||
list_reagents = list("soysauce" = 50)
|
||||
possible_states = list()
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/condiment/mayonnaise
|
||||
name = "mayonnaise"
|
||||
desc = "An oily condiment made from egg yolks."
|
||||
icon_state = "mayonnaise"
|
||||
list_reagents = list("mayonnaise" = 50)
|
||||
possible_states = list()
|
||||
|
||||
|
||||
|
||||
//Food packs. To easily apply deadly toxi... delicious sauces to your food!
|
||||
|
||||
@@ -468,3 +468,11 @@
|
||||
list_reagents = list("nutriment" = 3, "vitamin" = 2, "sodiumchloride" = 5)
|
||||
bonus_reagents = list("sodiumchloride" = 10)
|
||||
tastes = list("bran" = 4, "raisins" = 3, "salt" = 1)
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/snacks/butter
|
||||
name = "stick of butter"
|
||||
desc = "A stick of delicious, golden, fatty goodness."
|
||||
icon_state = "butter"
|
||||
list_reagents = list("nutriment" = 5)
|
||||
filling_color = "#FFD700"
|
||||
tastes = list("butter" = 1)
|
||||
@@ -10,7 +10,7 @@
|
||||
active_power_usage = 100
|
||||
pass_flags = PASSTABLE
|
||||
resistance_flags = ACID_PROOF
|
||||
var/operating = 0
|
||||
var/operating = FALSE
|
||||
var/obj/item/weapon/reagent_containers/beaker = null
|
||||
var/limit = 10
|
||||
var/list/blend_items = list (
|
||||
@@ -220,9 +220,12 @@
|
||||
[processing_chamber]<br>
|
||||
[beaker_contents]<hr>
|
||||
"}
|
||||
if (is_beaker_ready && !is_chamber_empty && !(stat & (NOPOWER|BROKEN)))
|
||||
if (is_beaker_ready)
|
||||
if(!is_chamber_empty && !(stat & (NOPOWER|BROKEN)))
|
||||
dat += "<A href='?src=\ref[src];action=grind'>Grind the reagents</a><BR>"
|
||||
dat += "<A href='?src=\ref[src];action=juice'>Juice the reagents</a><BR><BR>"
|
||||
else if (beaker.reagents.total_volume)
|
||||
dat += "<A href='?src=\ref[src];action=mix'>Mix the reagents</a><BR><BR>"
|
||||
if(holdingitems && holdingitems.len > 0)
|
||||
dat += "<A href='?src=\ref[src];action=eject'>Eject the reagents</a><BR>"
|
||||
if (beaker)
|
||||
@@ -248,6 +251,8 @@
|
||||
grind()
|
||||
if("juice")
|
||||
juice()
|
||||
if("mix")
|
||||
mix()
|
||||
if("eject")
|
||||
eject()
|
||||
if ("detach")
|
||||
@@ -327,11 +332,11 @@
|
||||
playsound(src.loc, 'sound/machines/juicer.ogg', 20, 1)
|
||||
var/offset = prob(50) ? -2 : 2
|
||||
animate(src, pixel_x = pixel_x + offset, time = 0.2, loop = 250) //start shaking
|
||||
operating = 1
|
||||
operating = TRUE
|
||||
updateUsrDialog()
|
||||
spawn(50)
|
||||
pixel_x = initial(pixel_x) //return to its spot after shaking
|
||||
operating = 0
|
||||
operating = FALSE
|
||||
updateUsrDialog()
|
||||
|
||||
//Snacks
|
||||
@@ -365,11 +370,11 @@
|
||||
playsound(src.loc, 'sound/machines/blender.ogg', 50, 1)
|
||||
var/offset = prob(50) ? -2 : 2
|
||||
animate(src, pixel_x = pixel_x + offset, time = 0.2, loop = 250) //start shaking
|
||||
operating = 1
|
||||
operating = TRUE
|
||||
updateUsrDialog()
|
||||
spawn(60)
|
||||
pixel_x = initial(pixel_x) //return to its spot after shaking
|
||||
operating = 0
|
||||
operating = FALSE
|
||||
updateUsrDialog()
|
||||
|
||||
//Snacks and Plants
|
||||
@@ -467,3 +472,33 @@
|
||||
break
|
||||
beaker.reagents.add_reagent(r_id, min(O.reagent_contents[r_id], space))
|
||||
remove_object(O)
|
||||
|
||||
/obj/machinery/reagentgrinder/proc/mix()
|
||||
|
||||
//For butter and other things that would change upon shaking or mixing
|
||||
power_change()
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
return
|
||||
if (!beaker)
|
||||
return
|
||||
playsound(src.loc, 'sound/machines/juicer.ogg', 20, 1)
|
||||
var/offset = prob(50) ? -2 : 2
|
||||
animate(src, pixel_x = pixel_x + offset, time = 0.2, loop = 250) //start shaking
|
||||
operating = TRUE
|
||||
updateUsrDialog()
|
||||
addtimer(CALLBACK(src, /obj/machinery/reagentgrinder/proc/mix_complete), 50)
|
||||
|
||||
/obj/machinery/reagentgrinder/proc/mix_complete()
|
||||
pixel_x = initial(pixel_x) //return to its spot after shaking
|
||||
operating = FALSE
|
||||
updateUsrDialog()
|
||||
if (beaker.reagents.total_volume)
|
||||
//Recipe to make Butter
|
||||
while(beaker.reagents.get_reagent_amount("milk") >= 15)
|
||||
beaker.reagents.remove_reagent("milk", 15)
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/butter(src.loc)
|
||||
//Recipe to make Mayonnaise
|
||||
if (beaker.reagents.has_reagent("eggyolk"))
|
||||
var/amount = beaker.reagents.get_reagent_amount("eggyolk")
|
||||
beaker.reagents.remove_reagent("eggyolk", amount)
|
||||
beaker.reagents.add_reagent("mayonnaise", amount)
|
||||
@@ -527,6 +527,12 @@
|
||||
M.heal_bodypart_damage(3,1)
|
||||
..()
|
||||
|
||||
/datum/reagent/consumable/mayonnaise
|
||||
name = "Mayonnaise"
|
||||
id = "mayonnaise"
|
||||
description = "An white and oily mixture of mixed egg yolks."
|
||||
color = "#DFDFDF"
|
||||
taste_description = "mayonnaise"
|
||||
|
||||
////Lavaland Flora Reagents////
|
||||
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 9.0 KiB After Width: | Height: | Size: 9.7 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 50 KiB After Width: | Height: | Size: 50 KiB |
Reference in New Issue
Block a user