Merge pull request #7198 from Crazylemon64/organ_varname_refactor

Refactors "organs" to be "bodyparts" to end confusion once and for all
This commit is contained in:
Fox McCloud
2017-04-30 17:00:44 -04:00
committed by GitHub
61 changed files with 167 additions and 179 deletions
+1 -1
View File
@@ -654,7 +654,7 @@
var/bruteloss = M.bruteloss
if(istype(M,/mob/living/carbon/human))
var/mob/living/carbon/human/C = M
for(var/obj/item/organ/external/L in C.organs)
for(var/obj/item/organ/external/L in C.bodyparts)
bruteloss += L.brute_dam
if(bruteloss < 100) // requires tenderization
M.apply_damage(rand(5,15),BRUTE)
+1 -1
View File
@@ -372,7 +372,7 @@ var/record_id_num = 1001
temp = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[H.tail]_s")
preview_icon.Blend(temp, ICON_OVERLAY)
for(var/obj/item/organ/external/E in H.organs)
for(var/obj/item/organ/external/E in H.bodyparts)
preview_icon.Blend(E.get_icon(), ICON_OVERLAY)
// Skin tone
+1 -1
View File
@@ -164,7 +164,7 @@ var/list/diseases = subtypesof(/datum/disease)
if(ishuman(affected_mob))
var/mob/living/carbon/human/H = affected_mob
for(var/obj/item/organ/O in required_organs)
if(!locate(O) in H.organs)
if(!locate(O) in H.bodyparts)
if(!locate(O) in H.internal_organs)
cure()
return
+1 -1
View File
@@ -1171,7 +1171,7 @@
if(ishuman(current))
var/mob/living/carbon/human/H = current
// Don't "undress" organs right out of the body
for(var/obj/item/W in H.contents - (H.organs | H.internal_organs))
for(var/obj/item/W in H.contents - (H.bodyparts | H.internal_organs))
current.unEquip(W, 1)
else
for(var/obj/item/W in current)
+1 -3
View File
@@ -33,7 +33,7 @@
H.apply_damage(10, BRUTE, "chest")
to_chat(H, "<span class='userdanger'>You have no appendix, but something had to give! Holy shit, what was that?</span>")
H.Weaken(3)
for(var/obj/item/organ/external/E in H.organs)
for(var/obj/item/organ/external/E in H.bodyparts)
if(istype(E, /obj/item/organ/external/head))
continue
if(istype(E, /obj/item/organ/external/chest))
@@ -43,5 +43,3 @@
if(prob(7))
to_chat(H, "<span class='userdanger'>Your [E] was severed by the explosion!</span>")
E.droplimb(1, DROPLIMB_EDGE, 0, 1)
+2 -2
View File
@@ -70,8 +70,8 @@
if(ishuman(M)) //Edge case housekeeping
var/mob/living/carbon/human/C = M
/*if(C.internal_organs_by_name && item_to_retrive in C.internal_organs_by_name ) //This won't work, as we use organ datums instead of objects. --DZD
C.internal_organs_by_name -= item_to_retrive
/*if(C.internal_bodyparts_by_name && item_to_retrive in C.internal_bodyparts_by_name ) //This won't work, as we use organ datums instead of objects. --DZD
C.internal_bodyparts_by_name -= item_to_retrive
if(istype(marked_item, /obj/item/brain)) //If this code ever runs I will be happy
var/obj/item/brain/B = new /obj/item/brain(target.loc)
B.transfer_identity(C)