From e684b69741a48ce5c60fcc6e1a3839c6f7c0de8e Mon Sep 17 00:00:00 2001 From: Ccomp5950 Date: Sat, 23 Nov 2013 20:21:51 -0600 Subject: [PATCH] Fixed a runtime issue with demonsblood. Was causing runtimes because data was inheriting the bloods data var (which is a list). The drink will still maintain it's reagents and data vars but when ingested and procesed the blood is ignored. Downsides, you can't get sick from ingesting blood in a drink (which..you shouldn't anywho) Possible future updates: since blood is an amnetic substance make the person have nausia for ingesting it if quantities are high --- code/modules/reagents/Chemistry-Reagents.dm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/code/modules/reagents/Chemistry-Reagents.dm b/code/modules/reagents/Chemistry-Reagents.dm index 4ff26510884..e4382699c39 100644 --- a/code/modules/reagents/Chemistry-Reagents.dm +++ b/code/modules/reagents/Chemistry-Reagents.dm @@ -2814,8 +2814,8 @@ datum if (adj_drowsy) M.drowsyness = max(0,M.drowsyness + adj_drowsy) if (adj_sleepy) M.sleeping = max(0,M.sleeping + adj_sleepy) - if(!src.data) data = 1 - src.data += boozepwr + if(!src.data || (!isnum(src.data) && src.data.len)) data = 1 //if it doesn't exist we set it. if it's a list we're going to set it to 1 as well. This is to + src.data += boozepwr //avoid a runtime error associated with drinking blood mixed in drinks (demon's blood). var/d = data @@ -3363,7 +3363,6 @@ datum description = "AHHHH!!!!" color = "#820000" // rgb: 130, 0, 0 boozepwr = 3 - ethanol/vodkatonic name = "Vodka and Tonic" id = "vodkatonic"