mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-21 11:07:12 +01:00
@@ -1182,22 +1182,22 @@ GLOBAL_LIST_INIT(ventcrawl_machinery, list(/obj/machinery/atmospherics/unary/ven
|
||||
SSticker.score.score_food_eaten++
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/proc/drink(obj/item/reagent_containers/drinks/to_eat, mob/user)
|
||||
/mob/living/carbon/proc/drink(obj/item/reagent_containers/drinks/to_drink, mob/user, drinksize_override)
|
||||
if(user == src)
|
||||
if(!selfDrink(to_eat))
|
||||
if(!selfDrink(to_drink))
|
||||
return FALSE
|
||||
else if(!forceFed(to_eat, user, nutrition))
|
||||
else if(!forceFed(to_drink, user, nutrition))
|
||||
return FALSE
|
||||
|
||||
if(to_eat.consume_sound)
|
||||
playsound(loc, to_eat.consume_sound, rand(10, 50), TRUE)
|
||||
if(to_eat.reagents.total_volume)
|
||||
taste(to_eat.reagents)
|
||||
var/fraction = min(1 / to_eat.reagents.total_volume, 1)
|
||||
var/drink_size = to_eat.amount_per_transfer_from_this > 5 ? 5 : to_eat.amount_per_transfer_from_this
|
||||
if(fraction)
|
||||
to_eat.reagents.reaction(src, REAGENT_INGEST, fraction)
|
||||
to_eat.reagents.trans_to(src, drink_size)
|
||||
if(to_drink.consume_sound)
|
||||
playsound(loc, to_drink.consume_sound, rand(10, 50), TRUE)
|
||||
if(to_drink.reagents.total_volume)
|
||||
taste(to_drink.reagents)
|
||||
var/drink_size = min(to_drink.amount_per_transfer_from_this, 5)
|
||||
if(drinksize_override)
|
||||
drink_size = drinksize_override
|
||||
to_drink.reagents.reaction(src, REAGENT_INGEST)
|
||||
to_drink.reagents.trans_to(src, drink_size)
|
||||
|
||||
SSticker.score.score_food_eaten++
|
||||
return TRUE
|
||||
|
||||
Reference in New Issue
Block a user