Added a few null checks.

This commit is contained in:
Zuhayr
2015-04-01 17:15:59 -07:00
parent 6e0e98469c
commit c3eb6102b4
5 changed files with 20 additions and 26 deletions
+4 -2
View File
@@ -343,9 +343,11 @@
var/o_a = (O.gender == PLURAL) ? "" : "a "
var/o_do = (O.gender == PLURAL) ? "don't" : "doesn't"
if(target.species.has_organ[O.organ_tag])
if(O.organ_tag == "limb")
return 0
else if(target.species.has_organ[O.organ_tag])
if(!O.health)
if(O.is_damaged())
user << "\red \The [O.organ_tag] [o_is] in no state to be transplanted."
return 2