Skip to content

Commit

Permalink
[Bugfix] Worn lolipops properly consume reagents (#1334) (#2314)
Browse files Browse the repository at this point in the history
Update sweets.dm

The lolipops now properly lose reagents when worn in the face slot instead of infinitely giving you its reagents (leading to you inevitably gaining weight.

Co-authored-by: LordVoidron <161195966+LordVoidron@users.noreply.github.com>
  • Loading branch information
Steals-The-PRs and LordVoidron authored Mar 8, 2024
1 parent 023fe83 commit 0aea856
Showing 1 changed file with 24 additions and 3 deletions.
27 changes: 24 additions & 3 deletions code/game/objects/items/food/sweets.dm
Original file line number Diff line number Diff line change
Expand Up @@ -307,11 +307,18 @@
var/mutable_appearance/head
var/head_color = rgb(0, 0, 0)

/// NOVA ADDITION BEGIN
//Copies regent metabolization from bubblegum so that you cant get infinite reagents from wearing lolipops
var/metabolization_ammount = REAGENTS_METABOLISM / 2
// Nova ADDITION END

/obj/item/food/lollipop/Initialize(mapload)
. = ..()
head = mutable_appearance('icons/obj/food/lollipop.dmi', "lollipop_head")
change_head_color(rgb(rand(0, 255), rand(0, 255), rand(0, 255)))
AddElement(/datum/element/chewable)
// NOVA EDIT BEGIN: Original: AddElement(/datum/element/chewable)
AddElement(/datum/element/chewable, metabolization_ammount)
// NOVA EDIT END

/obj/item/food/lollipop/proc/change_head_color(C)
head_color = C
Expand Down Expand Up @@ -351,9 +358,16 @@
slot_flags = ITEM_SLOT_MASK
crafting_complexity = FOOD_COMPLEXITY_1

/// NOVA ADDITION BEGIN
//Copies regent metabolization from bubblegum so that you cant get infinite reagents from wearing lolipops
var/metabolization_ammount = REAGENTS_METABOLISM / 2
// Nova ADDITION END

/obj/item/food/spiderlollipop/Initialize(mapload)
. = ..()
AddElement(/datum/element/chewable)
// NOVA EDIT BEGIN: Original: AddElement(/datum/element/chewable)
AddElement(/datum/element/chewable, metabolization_ammount)
// NOVA EDIT END

/obj/item/food/swirl_lollipop
name = "swirl lollipop"
Expand All @@ -372,6 +386,13 @@
slot_flags = ITEM_SLOT_MASK
crafting_complexity = FOOD_COMPLEXITY_1

/// NOVA ADDITION BEGIN
//Copies regent metabolization from bubblegum so that you cant get infinite reagents from wearing lolipops
var/metabolization_ammount = REAGENTS_METABOLISM / 2
// Nova ADDITION END

/obj/item/food/swirl_lollipop/Initialize(mapload)
. = ..()
AddElement(/datum/element/chewable)
// NOVA EDIT BEGIN: Original: AddElement(/datum/element/chewable)
AddElement(/datum/element/chewable, metabolization_ammount)
// NOVA EDIT END

0 comments on commit 0aea856

Please sign in to comment.