Fixes simplemobs with 0 init nutrition runtiming

Fixes runtime spam caused by simplemobs with initial nutrition value of 0.
This commit is contained in:
Verkister
2021-11-12 15:37:40 +02:00
committed by GitHub
parent 0051b29ead
commit 201bef6b06

View File

@@ -54,7 +54,7 @@
healths.icon_state = "health7"
//Updates the nutrition while we're here
var/food_per = (nutrition / initial(nutrition)) * 100
var/food_per = (nutrition / max_nutrition) * 100
switch(food_per)
if(90 to INFINITY)
clear_alert("nutrition")
@@ -164,4 +164,4 @@
spawn(3) //We'll update our icon in a sec
update_icon()
return ..(gibbed,deathmessage)
return ..(gibbed,deathmessage)