diff --git a/code/game/machinery/vending.dm b/code/game/machinery/vending.dm index d5e7a78db48..e1fad17a871 100644 --- a/code/game/machinery/vending.dm +++ b/code/game/machinery/vending.dm @@ -607,8 +607,8 @@ use_power(vend_power_usage) //actuators and stuff if (src.icon_vend) //Show the vending animation if needed flick(src.icon_vend,src) + playsound(src.loc, "sound/[vending_sound]", 100, 1) spawn(src.vend_delay) - playsound(src.loc, "sound/[vending_sound]", 100, 1) var/obj/vended = new R.product_path(get_turf(src)) src.status_message = "" src.status_error = 0 diff --git a/code/game/machinery/vending_types.dm b/code/game/machinery/vending_types.dm index c2b9e0b3748..63c37a0313f 100644 --- a/code/game/machinery/vending_types.dm +++ b/code/game/machinery/vending_types.dm @@ -92,7 +92,7 @@ /obj/item/reagent_containers/food/drinks/bottle/mintsyrup = 5, /obj/item/reagent_containers/food/drinks/bottle/cremewhite = 4, /obj/item/reagent_containers/food/drinks/bottle/brandy = 4, - /obj/item/reagent_containers/food/drinks/bottle/guinnes = 4, + /obj/item/reagent_containers/food/drinks/bottle/guinness = 4, /obj/item/reagent_containers/food/drinks/bottle/drambuie = 4, /obj/item/reagent_containers/food/drinks/bottle/cremeyvette = 4, /obj/item/reagent_containers/food/drinks/bottle/small/xuizijuice = 8, diff --git a/code/game/objects/items/trash.dm b/code/game/objects/items/trash.dm index 102271fb927..2ee263674c6 100644 --- a/code/game/objects/items/trash.dm +++ b/code/game/objects/items/trash.dm @@ -158,3 +158,13 @@ icon = 'icons/obj/food.dmi' icon_state = "stew_empty" drop_sound = 'sound/items/drop/shovel.ogg' + +/obj/item/trash/coffee + name = "empty cup" + icon_state = "coffee_vended" + drop_sound = 'sound/items/drop/papercup.ogg' + +/obj/item/trash/ramen + name = "cup ramen" + icon_state = "ramen" + drop_sound = 'sound/items/drop/papercup.ogg' diff --git a/code/game/objects/random/random.dm b/code/game/objects/random/random.dm index 8eac6e0aece..c2d16a67767 100644 --- a/code/game/objects/random/random.dm +++ b/code/game/objects/random/random.dm @@ -575,7 +575,7 @@ /obj/item/reagent_containers/food/drinks/bottle/melonliquor, /obj/item/reagent_containers/food/drinks/bottle/pwine, /obj/item/reagent_containers/food/drinks/bottle/brandy, - /obj/item/reagent_containers/food/drinks/bottle/guinnes, + /obj/item/reagent_containers/food/drinks/bottle/guinness, /obj/item/reagent_containers/food/drinks/bottle/drambuie, /obj/item/reagent_containers/food/drinks/bottle/cremeyvette, /obj/item/reagent_containers/food/drinks/bottle/cremewhite, diff --git a/code/modules/item_worth/reagents.dm b/code/modules/item_worth/reagents.dm index 0e2d16309c5..d2f8c7cd7d2 100644 --- a/code/modules/item_worth/reagents.dm +++ b/code/modules/item_worth/reagents.dm @@ -477,7 +477,7 @@ /datum/reagent/alcohol/ethanol/brandy value = 0.2 -/datum/reagent/alcohol/ethanol/guinnes +/datum/reagent/alcohol/ethanol/guinness value = 0.1 /datum/reagent/alcohol/ethanol/drambuie diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm index 16197ba7df2..dcdaebe7ae8 100644 --- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm +++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm @@ -284,7 +284,7 @@ color = "#c79705" touch_met = 1.5 var/lastburnmessage = 0 - taste_description = "some short of oil" + taste_description = "some sort of oil" taste_mult = 0.1 /datum/reagent/nutriment/triglyceride/oil/touch_turf(var/turf/simulated/T) @@ -3731,16 +3731,16 @@ glass_name = "glass of Brandy" glass_desc = "Cheap knock off for cognac." -/datum/reagent/alcohol/ethanol/guinnes +/datum/reagent/alcohol/ethanol/guinness name = "Guinness" - id = "guinnes" + id = "guinness" description = "Special Guinnes drink." color = "#2E6671" strength = 8 taste_description = "dryness" carbonated = TRUE - glass_icon_state = "guinnes_glass" + glass_icon_state = "guinness_glass" glass_name = "glass of Guinness" glass_desc = "A glass of Guinness." diff --git a/code/modules/reagents/reagent_containers/food.dm b/code/modules/reagents/reagent_containers/food.dm index 104e84e0b17..a2a0f539411 100644 --- a/code/modules/reagents/reagent_containers/food.dm +++ b/code/modules/reagents/reagent_containers/food.dm @@ -2,19 +2,29 @@ /// Food. //////////////////////////////////////////////////////////////////////////////// /obj/item/reagent_containers/food + drop_sound = 'sound/items/drop/food.ogg' flags = OPENCONTAINER possible_transfer_amounts = null volume = 50 //Sets the default container amount for all food items. var/filling_color = "#FFFFFF" //Used by sandwiches - drop_sound = 'sound/items/drop/food.ogg' - var/is_liquid = FALSE // Handles whether you can eat with a fork & which eating sound is played - -/obj/item/reagent_containers/food/self_feed_message(var/mob/user) - to_chat(user, "You [is_liquid? "drink" : "eat"] \the [src].") + var/trash = null + var/is_liquid = TRUE +/obj/item/reagent_containers/food/self_feed_message(var/mob/user) + to_chat(user, "You [is_liquid ? "drink from" : "eat"] \the [src].") /obj/item/reagent_containers/food/feed_sound(var/mob/user) if(is_liquid) playsound(user.loc, 'sound/items/drink.ogg', rand(10, 50), 1) else playsound(user.loc, 'sound/items/eatfood.ogg', rand(10, 50), 1) + +/obj/item/reagent_containers/food/proc/on_consume(var/mob/user, var/mob/target) + if(!reagents.total_volume) + user.drop_from_inventory(src) //so trash actually stays in the active hand. + if(trash) + var/obj/item/TrashItem = new trash(user) + user.put_in_hands(TrashItem) + target.visible_message(span("notice", "[target] finishes [is_liquid ? "drinking" : "eating"] \the [src]."), + span("notice","You finish [is_liquid ? "drinking" : "eating"] \the [src].")) + qdel(src) diff --git a/code/modules/reagents/reagent_containers/food/cans.dm b/code/modules/reagents/reagent_containers/food/cans.dm index 7f86c33b3b3..67795092486 100644 --- a/code/modules/reagents/reagent_containers/food/cans.dm +++ b/code/modules/reagents/reagent_containers/food/cans.dm @@ -100,7 +100,7 @@ /obj/item/reagent_containers/food/drinks/cans/grape_juice name = "\improper Grapel juice" desc = "500 pages of rules of how to appropriately enter into a combat with this juice!" - icon_state = "purple_can" + icon_state = "grapesoda" center_of_mass = list("x"=16, "y"=10) /obj/item/reagent_containers/food/drinks/cans/grape_juice/Initialize() diff --git a/code/modules/reagents/reagent_containers/food/drinks.dm b/code/modules/reagents/reagent_containers/food/drinks.dm index 0bce43c1750..31806502c5c 100644 --- a/code/modules/reagents/reagent_containers/food/drinks.dm +++ b/code/modules/reagents/reagent_containers/food/drinks.dm @@ -15,12 +15,6 @@ /obj/item/reagent_containers/food/drinks/on_reagent_change() return -/obj/item/reagent_containers/food/drinks/feed_sound(var/mob/user) - playsound(user.loc, 'sound/items/drink.ogg', rand(10, 50), 1) - -/obj/item/reagent_containers/food/drinks/self_feed_message(var/mob/user) - to_chat(user, "You drink from \the [src].") - /obj/item/reagent_containers/food/drinks/attack_self(mob/user as mob) if(!is_open_container()) if(user.a_intent == I_HURT && !shaken) @@ -56,6 +50,7 @@ if(!is_open_container()) to_chat(user, "You need to open \the [src]!") return 1 + on_consume(target,user) return ..() /obj/item/reagent_containers/food/drinks/standard_dispenser_refill(var/mob/user, var/obj/structure/reagent_dispensers/target) @@ -130,61 +125,72 @@ reagents.add_reagent("soymilk", 50) /obj/item/reagent_containers/food/drinks/coffee - name = "Robust coffee" + name = "robust coffee" desc = "Careful, the beverage you're about to enjoy is extremely hot." - icon_state = "coffee" + icon_state = "coffee_vended" item_state = "contvapour" - drop_sound = 'sound/items/drop/box.ogg' + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=16, "y"=11) Initialize() . = ..() reagents.add_reagent("coffee", 30) /obj/item/reagent_containers/food/drinks/pslatte - name = "Seasonal Pumpkin Spice Latte" + name = "seasonal pumpkin spice latte" desc = "A limited edition pumpkin spice coffee drink!" icon_state = "psl_vended" - drop_sound = 'sound/items/drop/box.ogg' + item_state = "contvapour" + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=16, "y"=11) Initialize() . = ..() reagents.add_reagent("sadpslatte", 30) /obj/item/reagent_containers/food/drinks/tea - name = "Duke purple tea" + name = "duke purple tea" desc = "An insult to Duke Purple is an insult to the Space Queen! Any proper gentleman will fight you, if you sully this tea." - icon_state = "coffee" - item_state = "coffee" + icon_state = "coffee_vended" + item_state = "contvapour" + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=16, "y"=14) Initialize() . = ..() reagents.add_reagent("tea", 30) /obj/item/reagent_containers/food/drinks/greentea - name = "Green Tea" + name = "green tea" desc = "Tasty green tea. It's good for you!" icon_state = "greentea_vended" - item_state = "coffee" + item_state = "contvapour" + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=16, "y"=14) Initialize() . = ..() reagents.add_reagent("greentea", 30) /obj/item/reagent_containers/food/drinks/hotcider - name = "Hot Cider" + name = "hot cider" desc = "A hearty apple drink, spiced just right." - icon_state = "soy_latte" - item_state = "coffee" + icon_state = "soy_latte_vended" + item_state = "contvapour" + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=16, "y"=14) Initialize() . = ..() reagents.add_reagent("ciderhot", 30) /obj/item/reagent_containers/food/drinks/chaitea - name = "Chai Tea" + name = "chai Tea" desc = "The name is redundant but the flavor is delicious!" icon_state = "chai_vended" - item_state = "coffee" + item_state = "contvapour" + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=16, "y"=14) Initialize() . = ..() @@ -193,7 +199,10 @@ /obj/item/reagent_containers/food/drinks/ice name = "ice cup" desc = "Careful, cold ice, do not chew." - icon_state = "coffee" + icon_state = "coffee_vended" + item_state = "contvapour" + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=15, "y"=10) Initialize() . = ..() @@ -203,7 +212,9 @@ name = "dutch hot coco" desc = "Made in Space South America." icon_state = "hot_coco" - item_state = "coffee" + item_state = "contvapour" + trash = /obj/item/trash/coffee + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=15, "y"=13) Initialize() . = ..() @@ -213,7 +224,9 @@ name = "cup ramen" desc = "Just add 10ml water, self heats! A taste that reminds you of your school years." icon_state = "ramen" - drop_sound = 'sound/items/drop/gloves.ogg' + item_state = "contvapour" + trash = /obj/item/trash/ramen + drop_sound = 'sound/items/drop/papercup.ogg' center_of_mass = list("x"=16, "y"=11) Initialize() . = ..() @@ -224,7 +237,7 @@ name = "paper cup" desc = "A paper water cup." icon_state = "water_cup_e" - drop_sound = 'sound/items/drop/paper.ogg' + drop_sound = 'sound/items/drop/papercup.ogg' possible_transfer_amounts = null volume = 10 center_of_mass = list("x"=16, "y"=12) diff --git a/code/modules/reagents/reagent_containers/food/drinks/bottle.dm b/code/modules/reagents/reagent_containers/food/drinks/bottle.dm index fd0e13a5220..379f25397d3 100644 --- a/code/modules/reagents/reagent_containers/food/drinks/bottle.dm +++ b/code/modules/reagents/reagent_containers/food/drinks/bottle.dm @@ -19,10 +19,9 @@ var/rag_underlay = "rag" /obj/item/reagent_containers/food/drinks/bottle/Initialize() - . = ..() + ..() if(isGlass) unacidable = 1 - drop_sound = 'sound/items/drop/bottle.ogg' /obj/item/reagent_containers/food/drinks/bottle/Destroy() if(rag) @@ -30,6 +29,10 @@ rag = null return ..() +/obj/item/reagent_containers/food/drinks/bottle/on_reagent_change() + update_icon() + + //when thrown on impact, bottles smash and spill their contents /obj/item/reagent_containers/food/drinks/bottle/throw_impact(atom/hit_atom, var/speed) ..() @@ -112,7 +115,8 @@ update_icon() /obj/item/reagent_containers/food/drinks/bottle/open(mob/user) - if(rag) return + if(rag) + return ..() /obj/item/reagent_containers/food/drinks/bottle/update_icon() @@ -120,6 +124,13 @@ if(rag) var/underlay_image = image(icon='icons/obj/drinks.dmi', icon_state=rag.on_fire? "[rag_underlay]_lit" : rag_underlay) underlays += underlay_image + set_light(2) + else + set_light(0) + if(reagents.total_volume) + icon_state = "[initial(icon_state)]" + else + icon_state = "[initial(icon_state)]_empty" /obj/item/reagent_containers/food/drinks/bottle/attack(mob/living/target, mob/living/user, var/hit_zone) var/blocked = ..() @@ -170,6 +181,7 @@ desc = "A bottle with a sharp broken bottom." icon = 'icons/obj/drinks.dmi' icon_state = "broken_bottle" + drop_sound = 'sound/items/drop/glass.ogg' force = 9 throwforce = 5 throw_speed = 3 @@ -219,7 +231,7 @@ /obj/item/reagent_containers/food/drinks/bottle/fireball name = "Uncle Git's Cinnamon Fireball" desc = "A premium single-malt whiskey, infused with cinnamon and hot pepper inside the tunnels of a nuclear shelter. TUNNEL WHISKEY RULES." - icon_state = "fireballbottle" + icon_state = "whiskeybottle" center_of_mass = list("x"=16, "y"=4) Initialize() . = ..() @@ -578,14 +590,14 @@ . = ..() reagents.add_reagent("brandy", 100) -/obj/item/reagent_containers/food/drinks/bottle/guinnes +/obj/item/reagent_containers/food/drinks/bottle/guinness name = "Guinness" desc = "A bottle of good old Guinness." - icon_state = "guinnes_bottle" + icon_state = "guinness_bottle" center_of_mass = list("x" = 15,"y" = 4) Initialize() . = ..() - reagents.add_reagent("guinnes", 100) + reagents.add_reagent("guinness", 100) /obj/item/reagent_containers/food/drinks/bottle/drambuie name = "Drambuie" diff --git a/code/modules/reagents/reagent_containers/food/snacks.dm b/code/modules/reagents/reagent_containers/food/snacks.dm index ed791d58b59..98ff073206e 100644 --- a/code/modules/reagents/reagent_containers/food/snacks.dm +++ b/code/modules/reagents/reagent_containers/food/snacks.dm @@ -7,9 +7,11 @@ desc = "Yummy!" icon = 'icons/obj/food.dmi' icon_state = null + center_of_mass = list("x"=16, "y"=16) + w_class = 2 + is_liquid = FALSE var/bitesize = 1 var/bitecount = 0 - var/trash = null var/slice_path var/slices_num var/dried_type = null @@ -17,8 +19,6 @@ var/nutriment_amt = 0 var/nutriment_type = NUTRIMENT_GOOD var/list/nutriment_desc = list("food" = 1) - center_of_mass = list("x"=16, "y"=16) - w_class = 2 var/datum/reagent/nutriment/coating/coating = null var/icon/flat_icon = null //Used to cache a flat icon generated from dipping in batter. This is used again to make the cooked-batter-overlay var/do_coating_prefix = 1 @@ -40,20 +40,10 @@ /obj/item/reagent_containers/food/snacks/standard_splash_mob(var/mob/user, var/mob/target) return 1 //Returning 1 will cancel everything else in a long line of things it should do. -/obj/item/reagent_containers/food/snacks/proc/on_consume(var/mob/eater, var/mob/feeder = null) +/obj/item/reagent_containers/food/snacks/on_consume() + ..() if(!reagents.total_volume) - eater.visible_message(span("notice", "[eater] finishes [is_liquid ? "drinking" : "eating"] \the [src]."),span("notice","You finish [is_liquid ? "drinking" : "eating"] \the [src].")) - if(!feeder) - feeder = eater - feeder.drop_from_inventory(src) //so icons update :[ //what the fuck is this???? - if(trash) - if(ispath(trash,/obj/item)) - var/obj/item/TrashItem = new trash(feeder) - feeder.put_in_hands(TrashItem) - else if(istype(trash,/obj/item)) - feeder.put_in_hands(trash) qdel(src) - return /obj/item/reagent_containers/food/snacks/attack_self(mob/user as mob) return @@ -65,11 +55,6 @@ if(!istype(target)) return - if(!reagents.total_volume) - to_chat(user,span("warning","There is none of \the [src] left to eat!")) - qdel(src) - return - if (isanimal(target)) var/mob/living/simple_animal/SA = target if(!(reagents && SA.reagents)) @@ -147,10 +132,7 @@ msg_admin_attack("[key_name_admin(user)] fed [key_name_admin(target)] with [name] Reagents: [contained] (INTENT: [uppertext(user.a_intent)]) (JMP)",ckey=key_name(user),ckey_target=key_name(target)) reagents.trans_to_mob(target, min(reagents.total_volume,bitesize), CHEM_INGEST) - if(is_liquid) - playsound(user.loc, 'sound/items/drink.ogg', rand(10, 50), 1) - else - playsound(user.loc, 'sound/items/eatfood.ogg', rand(10, 50), 1) + feed_sound(target,user) bitecount++ on_consume(target,user) @@ -230,11 +212,8 @@ U.is_liquid = TRUE if (reagents.total_volume <= 0) if(trash) - if(ispath(trash,/obj/item)) - var/obj/item/TrashItem = new trash(user) - user.put_in_hands(TrashItem) - else if(istype(trash,/obj/item)) - user.put_in_hands(trash) + var/obj/item/TrashItem = new trash(user) + user.put_in_hands(TrashItem) qdel(src) return @@ -529,7 +508,6 @@ . = ..() reagents.add_reagent("sugar", 3) - /obj/item/reagent_containers/food/snacks/candy/koko name = "\improper koko bar" desc = "A sweet and gritty candy bar cultivated exclusively on the Compact ruled world of Ha'zana. A good pick-me-up for Unathi, but has no effect on other species." @@ -547,6 +525,7 @@ /obj/item/reagent_containers/food/snacks/candy/donor name = "donor candy" + icon_state = "candy" desc = "A little treat for blood donors. Made with real sugar!" trash = /obj/item/trash/candy nutriment_desc = list("candy" = 10) @@ -5517,6 +5496,5 @@ It is known for its hard crust, bland taste and for being long lasting. The hard bread was usually prepared for long journeys, hard winters or military campaigns, \ due to its shelf life. Certain folk stories and jokes claim that such food could also be used as an artillery ammunition or thrown at besieging armies during sieges." - #undef NUTRIMENT_GOOD -#undef NUTRIMENT_BAD +#undef NUTRIMENT_BAD \ No newline at end of file diff --git a/html/changelogs/wezzy_cuphead.yml b/html/changelogs/wezzy_cuphead.yml new file mode 100644 index 00000000000..b7235966d43 --- /dev/null +++ b/html/changelogs/wezzy_cuphead.yml @@ -0,0 +1,43 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# wip (For works in progress) +# tweak +# soundadd +# sounddel +# rscadd (general adding of nice things) +# rscdel (general deleting of nice things) +# imageadd +# imagedel +# maptweak +# spellcheck (typo fixes) +# experiment +# balance +# admin +# backend +# security +# refactor +################################# + +# Your name. +author: Wowzewow (Wezzy) + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. +# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. +changes: + - rscadd: "New trash states for cup ramen and coffee cups! Check them out!" + - imageadd: "Tweaks some drink and bottle sprites, namely soda cans. Alcohol bottles have empty states now." + - soundadd: "New paper cup sound and tweaks the coffee vend sound again." diff --git a/icons/obj/drinks.dmi b/icons/obj/drinks.dmi index ae38d8fcd11..4a1a353f6aa 100644 Binary files a/icons/obj/drinks.dmi and b/icons/obj/drinks.dmi differ diff --git a/icons/obj/trash.dmi b/icons/obj/trash.dmi index 79add6ae410..3898bcc4e40 100644 Binary files a/icons/obj/trash.dmi and b/icons/obj/trash.dmi differ diff --git a/sound/items/drop/papercup.ogg b/sound/items/drop/papercup.ogg new file mode 100644 index 00000000000..6bea17488f5 Binary files /dev/null and b/sound/items/drop/papercup.ogg differ diff --git a/sound/machines/vending/vending_coffee.ogg b/sound/machines/vending/vending_coffee.ogg index b1f7e17bda5..31edabc50ab 100644 Binary files a/sound/machines/vending/vending_coffee.ogg and b/sound/machines/vending/vending_coffee.ogg differ