Merge pull request #35324 from AutomaticFrenzy/patch/defibrillator-runtime

Fix defibrillator mount runtiming continously while empty
This commit is contained in:
vuonojenmustaturska
2018-02-06 01:58:16 +02:00
committed by CitadelStationBot
parent 7b46f951cc
commit a7057f8331
+1 -1
View File
@@ -38,7 +38,7 @@
if(defib && defib.cell && defib.cell.charge < defib.cell.maxcharge)
use_power(20)
defib.cell.give(18) //90% efficiency, slightly better than the cell charger's 87.5%
if(isliving(defib.paddles.loc))
if(defib && defib.paddles && isliving(defib.paddles.loc))
var/mob/living/L = defib.paddles.loc
if(!L.Adjacent(src))
to_chat(L, "<span class='warning'>[defib]'s paddles overextend and come out of your hands!</span>")