Nutrition Refactor (#12389)

This commit is contained in:
Fox McCloud
2019-09-24 15:17:55 -07:00
committed by variableundefined
parent 082dcc9910
commit 86e6d85093
40 changed files with 135 additions and 111 deletions
+2 -2
View File
@@ -337,11 +337,11 @@
break
A.charging = 1
if(A.cell.charge >= 500)
H.nutrition += 50
H.adjust_nutrition(50)
A.cell.charge -= 500
to_chat(H, "<span class='notice'>You siphon off some of the stored charge for your own use.</span>")
else
H.nutrition += A.cell.charge/10
H.adjust_nutrition(A.cell.charge * 0.1)
A.cell.charge = 0
to_chat(H, "<span class='notice'>You siphon off the last of \the [A]'s charge.</span>")
break
@@ -229,7 +229,7 @@
if(owner.nutrition <= hunger_threshold)
synthesizing = 1
to_chat(owner, "<span class='notice'>You feel less hungry...</span>")
owner.nutrition += 50
owner.adjust_nutrition(50)
spawn(50)
synthesizing = 0
@@ -285,7 +285,7 @@
/obj/item/organ/internal/honktumor/cursed/on_life() //No matter what you do, no matter who you are, no matter where you go, you're always going to be a fat, stuttering dimwit.
..()
owner.setBrainLoss(80)
owner.nutrition = 9000
owner.set_nutrition(9000)
owner.overeatduration = 9000
@@ -41,7 +41,7 @@
owner.visible_message("<span class='notice'>[owner] fades to dark.</span>")
return
owner.nutrition = max(owner.nutrition - KIDAN_LANTERN_HUNGERCOST, KIDAN_LANTERN_HUNGERCOST)
owner.set_nutrition(max(owner.nutrition - KIDAN_LANTERN_HUNGERCOST, KIDAN_LANTERN_HUNGERCOST))
var/new_light = calculate_glow(KIDAN_LANTERN_LIGHT)