Merge pull request #1956 from Yoshax/harpiesports

Various Bay Ports
This commit is contained in:
EmperorJon
2016-06-21 17:31:29 +01:00
committed by GitHub
21 changed files with 161 additions and 80 deletions
+1
View File
@@ -50,6 +50,7 @@ var/list/organ_cache = list()
max_damage = min_broken_damage * 2
if(istype(holder))
src.owner = holder
src.w_class = max(src.w_class + mob_size_difference(holder.mob_size, MOB_MEDIUM), 1) //smaller mobs have smaller organs.
species = all_species["Human"]
if(holder.dna)
dna = holder.dna.Clone()
+27 -21
View File
@@ -60,7 +60,7 @@
var/cannot_gib // Impossible to gib, distinct from amputation.
var/joint = "joint" // Descriptive string used in dislocation.
var/amputation_point // Descriptive string used in amputation.
var/dislocated = 0 // If you target a joint, you can dislocate the limb, causing temporary damage to the organ.
var/dislocated = 0 // If you target a joint, you can dislocate the limb, impairing it's usefulness and causing pain
var/encased // Needs to be opened with a saw to access the organs.
// Surgery vars.
@@ -156,32 +156,38 @@
/obj/item/organ/external/proc/is_dislocated()
if(dislocated > 0)
return 1
if(parent)
return parent.is_dislocated()
if(is_parent_dislocated())
return 1//if any parent is dislocated, we are considered dislocated as well
return 0
/obj/item/organ/external/proc/dislocate(var/primary)
if(dislocated != -1)
if(primary)
dislocated = 2
else
dislocated = 1
owner.verbs |= /mob/living/carbon/human/proc/undislocate
if(children && children.len)
for(var/obj/item/organ/external/child in children)
child.dislocate()
/obj/item/organ/external/proc/is_parent_dislocated()
var/obj/item/organ/external/O = parent
while(O && O.dislocated != -1)
if(O.dislocated == 1)
return 1
O = O.parent
return 0
/obj/item/organ/external/proc/dislocate()
if(dislocated == -1)
return
dislocated = 1
if(owner)
owner.verbs |= /mob/living/carbon/human/proc/undislocate
/obj/item/organ/external/proc/undislocate()
if(dislocated != -1)
dislocated = 0
if(children && children.len)
for(var/obj/item/organ/external/child in children)
if(child.dislocated == 1)
child.undislocate()
if(dislocated == -1)
return
dislocated = 0
if(owner)
owner.shock_stage += 20
//check to see if we still need the verb
for(var/obj/item/organ/external/limb in owner.organs)
if(limb.dislocated == 2)
if(limb.dislocated == 1)
return
owner.verbs -= /mob/living/carbon/human/proc/undislocate
@@ -1085,7 +1091,7 @@ Note that amputating the affected organ does in fact remove the infection from t
return 0
/obj/item/organ/external/proc/is_usable()
return !is_dislocated() && !(status & (ORGAN_MUTATED|ORGAN_DEAD))
return !(status & (ORGAN_MUTATED|ORGAN_DEAD))
/obj/item/organ/external/proc/is_malfunctioning()
return ((robotic >= ORGAN_ROBOT) && (brute_dam + burn_dam) >= 10 && prob(brute_dam + burn_dam))
+2 -1
View File
@@ -206,4 +206,5 @@
amputation_point = "branch"
joint = "structural ligament"
dislocated = -1
vital = 0
vital = 0
slot_flags = SLOT_BELT
+3
View File
@@ -2,6 +2,8 @@
ORGAN DEFINES
****************************************************/
//Make sure that w_class is set as if the parent mob was medium sized! This is because w_class is adjusted automatically for mob_size in New()
/obj/item/organ/external/chest
name = "upper body"
organ_tag = BP_TORSO
@@ -148,6 +150,7 @@
organ_tag = BP_HEAD
icon_name = "head"
name = "head"
slot_flags = SLOT_BELT
max_damage = 75
min_broken_damage = 35
w_class = 3