mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-12 03:02:54 +00:00
Fixes runtime in Chemistry-Reagents-Food-Drinks.dm,25: bad index (#7654)
This commit is contained in:
@@ -18,11 +18,14 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
//add the new taste data
|
//add the new taste data
|
||||||
for(var/taste in newdata)
|
if(islist(data))
|
||||||
if(taste in data)
|
for(var/taste in newdata)
|
||||||
data[taste] += newdata[taste]
|
if(taste in data)
|
||||||
else
|
data[taste] += newdata[taste]
|
||||||
data[taste] = newdata[taste]
|
else
|
||||||
|
data[taste] = newdata[taste]
|
||||||
|
else
|
||||||
|
initialize_data(newdata)
|
||||||
|
|
||||||
//cull all tastes below 10% of total
|
//cull all tastes below 10% of total
|
||||||
var/totalFlavor = 0
|
var/totalFlavor = 0
|
||||||
@@ -676,7 +679,7 @@
|
|||||||
var/mob/living/carbon/human/H = M
|
var/mob/living/carbon/human/H = M
|
||||||
if(!H.can_feel_pain())
|
if(!H.can_feel_pain())
|
||||||
return
|
return
|
||||||
|
|
||||||
var/effective_dose = (dose * M.species.spice_mod)
|
var/effective_dose = (dose * M.species.spice_mod)
|
||||||
if((effective_dose < 5) && (dose == metabolism || prob(5)))
|
if((effective_dose < 5) && (dose == metabolism || prob(5)))
|
||||||
to_chat(M, "<span class='danger'>Your insides feel uncomfortably hot!</span>")
|
to_chat(M, "<span class='danger'>Your insides feel uncomfortably hot!</span>")
|
||||||
|
|||||||
Reference in New Issue
Block a user