Skip to content

Commit

Permalink
prevent infinite eating with fork.
Browse files Browse the repository at this point in the history
  • Loading branch information
Julien committed Aug 12, 2023
1 parent 499a639 commit 8c6daf6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions code/game/objects/items/tools/kitchen_tools.dm
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@
return ..()

if (reagents.total_volume > 0)
var/fullness = M.nutrition + (M.reagents.get_reagent_amount("nutriment") * 25)
if(fullness > 540)
to_chat(user, SPAN_WARNING("[user == M ? "You" : "They"] don't feel like eating more right now."))
return
reagents.set_source_mob(user)
reagents.trans_to_ingest(M, reagents.total_volume)
if(M == user)
Expand Down

0 comments on commit 8c6daf6

Please sign in to comment.