From 726ace52eba9f39a300631ceaa8e86ae71543335 Mon Sep 17 00:00:00 2001
From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
Date: Tue, 26 Mar 2019 12:59:39 -0400
Subject: [PATCH 1/7] merg conflict is this
---
.../research/designs/medical_designs.dm | 44 +++++++++++++++++++
1 file changed, 44 insertions(+)
diff --git a/code/modules/research/designs/medical_designs.dm b/code/modules/research/designs/medical_designs.dm
index ca3f2b420b..aea3a3755f 100644
--- a/code/modules/research/designs/medical_designs.dm
+++ b/code/modules/research/designs/medical_designs.dm
@@ -195,6 +195,50 @@
category = list("Medical Designs")
departmental_flags = DEPARTMENTAL_FLAG_MEDICAL
+/datum/design/defib_heal
+ name = "Defibrillartor Healing disk"
+ desc = "A disk allowing for greater amounts of healing"
+ id = "defib_heal"
+ build_type = PROTOLATHE
+ materials = list(MAT_METAL=16000, MAT_GLASS = 18000, MAT_GOLD = 6000, MAT_SILVER = 6000)
+ build_path = /obj/item/disk/medical/defib_heal
+ construction_time = 10
+ category = list("Misc")
+ departmental_flags = DEPARTMENTAL_FLAG_MEDICAL
+
+/datum/design/defib_shock
+ name = "Defibrillartor Anit-Shock Disk"
+ desc = "A disk that helps agains shocking anyone, other then the intented target"
+ id = "defib_shock"
+ build_type = PROTOLATHE
+ materials = list(MAT_METAL=16000, MAT_GLASS = 18000, MAT_GOLD = 6000, MAT_SILVER = 6000)
+ build_path = /obj/item/disk/medical/defib_shock
+ construction_time = 10
+ category = list("Misc")
+ departmental_flags = DEPARTMENTAL_FLAG_MEDICAL
+
+/datum/design/defib_decay
+ name = "Defibrillartor Body-Decay extender Disk"
+ desc = "A disk that helps defibrillator revive the longer decayed dead"
+ id = "defib_decay"
+ build_type = PROTOLATHE
+ materials = list(MAT_METAL=16000, MAT_GLASS = 18000, MAT_GOLD = 16000, MAT_SILVER = 6000, MAT_TITANIUM = 2000)
+ build_path = /obj/item/disk/medical/defib_decay
+ construction_time = 10
+ category = list("Misc")
+ departmental_flags = DEPARTMENTAL_FLAG_MEDICAL
+
+/datum/design/defib_speed
+ name = "Defibrllartor Pre-Primer Disk"
+ desc = "A disk that cuts the time charg time in half for defibrillator use"
+ id = "defib_speed"
+ build_type = PROTOLATHE
+ build_path = /obj/item/disk/medical/defib_speed
+ materials = list(MAT_METAL=16000, MAT_GLASS = 8000, MAT_GOLD = 26000, MAT_SILVER = 26000)
+ construction_time = 10
+ category = list("Misc")
+ departmental_flags = DEPARTMENTAL_FLAG_MEDICAL
+
/////////////////////////////////////////
//////////Alien Surgery Tools////////////
From 52003b20f4484290dc46366ea1c73a6ea48d19df Mon Sep 17 00:00:00 2001
From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
Date: Tue, 26 Mar 2019 13:06:53 -0400
Subject: [PATCH 2/7] >_<
---
code/game/objects/items/defib.dm | 85 ++++++++++++++++++++++++++++++--
1 file changed, 82 insertions(+), 3 deletions(-)
diff --git a/code/game/objects/items/defib.dm b/code/game/objects/items/defib.dm
index 71302d6506..674bfe8588 100644
--- a/code/game/objects/items/defib.dm
+++ b/code/game/objects/items/defib.dm
@@ -23,6 +23,10 @@
var/obj/item/stock_parts/cell/high/cell
var/combat = FALSE //can we revive through space suits?
var/grab_ghost = FALSE // Do we pull the ghost back into their body?
+ var/healdisk = FALSE // Will we shock people dragging the body?
+ var/pullshocksafely = FALSE //Dose the unit have the healdisk upgrade?
+ var/primetime = 0 // is the defib faster
+ var/timedeath = 10
/obj/item/defibrillator/get_cell()
return cell
@@ -534,7 +538,7 @@
user.visible_message("[user] begins to place [src] on [H]'s chest.", "You begin to place [src] on [H]'s chest...")
busy = TRUE
update_icon()
- if(do_after(user, 30, target = H)) //beginning to place the paddles on patient's chest to allow some time for people to move away to stop the process
+ if(do_after(user, 30 - defib.primetime, target = H))) //beginning to place the paddles on patient's chest to allow some time for people to move away to stop the process
user.visible_message("[user] places [src] on [H]'s chest.", "You place [src] on [H]'s chest.")
playsound(src, 'sound/machines/defib_charge.ogg', 75, 0)
var/tplus = world.time - H.timeofdeath
@@ -542,10 +546,10 @@
// (in deciseconds)
// brain damage starts setting in on the patient after
// some time left rotting
- var/tloss = DEFIB_TIME_LOSS * 10
+ var/tloss = DEFIB_TIME_LOSS * defib.timedeath
var/total_burn = 0
var/total_brute = 0
- if(do_after(user, 20, target = H)) //placed on chest and short delay to shock for dramatic effect, revive time is 5sec total
+ if(do_after(user, 20 - defib.primetime, target = H)) //placed on chest and short delay to shock for dramatic effect, revive time is 5sec total
for(var/obj/item/carried_item in H.contents)
if(istype(carried_item, /obj/item/clothing/suit/space))
if((!combat && !req_defib) || (req_defib && !defib.combat))
@@ -605,6 +609,8 @@
if(tplus > tloss)
H.adjustBrainLoss( max(0, min(99, ((tlimit - tplus) / tlimit * 100))), 150)
log_combat(user, H, "revived", defib)
+ if(defib.healdisk)
+ H.heal_overall_damage(25, 25)
if(req_defib)
defib.deductcharge(revivecost)
cooldown = 1
@@ -628,6 +634,43 @@
busy = FALSE
update_icon()
+/obj/item/twohanded/shockpaddles/shock_touching(dmg, mob/H)
+ if(defib.pullshocksafely && isliving(H.pulledby))
+ H.visible_message("The defibrillator safely discharges the excessive charge into the floor!")
+ return
+ ..()
+
+/obj/item/defibrillator/attackby(obj/item/I, mob/user, params)
+ if(istype(I, /obj/item/disk/medical/defib_heal))
+ if(healdisk)
+ to_chat(user, "This unit is already upgraded with this disk!")
+ return TRUE
+ to_chat(user, "You upgrade the unit with Heal upgrade disk!")
+ healdisk = TRUE
+ return TRUE
+ if(istype(I, /obj/item/disk/medical/defib_shock))
+ if(pullshocksafely)
+ to_chat(user, "This unit is already upgraded with this disk!")
+ return TRUE
+ to_chat(user, "You upgrade the unit with Shock Safety upgrade disk!")
+ pullshocksafely = TRUE
+ return TRUE
+ if(istype(I, /obj/item/disk/medical/defib_speed))
+ if(!primetime == initial(primetime))
+ to_chat(user, "This unit is already upgraded with this disk!")
+ return TRUE
+ to_chat(user, "You upgrade the unit with Speed upgrade disk!")
+ primetime = 10
+ return TRUE
+ if(istype(I, /obj/item/disk/medical/defib_decay))
+ if(!timedeath == initial(timedeath))
+ to_chat(user, "This unit is already upgraded with this disk!")
+ return TRUE
+ to_chat(user, "You upgrade the unit with Longer Decay upgrade disk!")
+ timedeath = 20
+ return TRUE
+ return ..()
+
/obj/item/twohanded/shockpaddles/cyborg
name = "cyborg defibrillator paddles"
icon = 'icons/obj/items_and_weapons.dmi'
@@ -656,4 +699,40 @@
item_state = "defibpaddles0"
req_defib = FALSE
+///////////////////////////////////////////
+/////////Dedibrillators Disks//////////////
+///////////////////////////////////////////
+
+/obj/item/disk/medical
+ name = "Defibrillator Upgrade Disk"
+ desc = "A blank defibrillator disk..."
+ icon = 'modular_citadel/icons/obj/defib_disks.dmi'
+ icon_state = "upgrade_disk"
+ item_state = "heal_disk"
+ w_class = WEIGHT_CLASS_SMALL
+
+/obj/item/disk/medical/defib_heal
+ name = "Defibrillator Healing Disk"
+ desc = "A disk alowing for grater amounts of healing"
+ icon_state = "heal_disk"
+ materials = list(MAT_METAL=16000, MAT_GLASS = 18000, MAT_GOLD = 6000, MAT_SILVER = 6000)
+
+/obj/item/disk/medical/defib_shock
+ name = "Defibrillator Anti-Shock Disk"
+ desc = "A disk that helps agains shocking anyone, other then the intented target"
+ icon_state = "zap_disk"
+ materials = list(MAT_METAL=16000, MAT_GLASS = 18000, MAT_GOLD = 6000, MAT_SILVER = 6000)
+
+/obj/item/disk/medical/defib_decay
+ name = "Defibrillator Body-Decay Extender Disk"
+ desc = "A disk that helps defibrillators revive the longer decayed"
+ icon_state = "body_disk"
+ materials = list(MAT_METAL=16000, MAT_GLASS = 18000, MAT_GOLD = 16000, MAT_SILVER = 6000, MAT_TITANIUM = 2000)
+
+/obj/item/disk/medical/defib_speed
+ name = "Defibrllator Pre-Primer Disk"
+ desc = "A disk that cuts the time charg time in half for defibrillator use"
+ icon_state = "fast_disk"
+ materials = list(MAT_METAL=16000, MAT_GLASS = 8000, MAT_GOLD = 26000, MAT_SILVER = 26000)
+
#undef HALFWAYCRITDEATH
From 8bebae82f5a86e8fb44915e09ce1c6318fa3235c Mon Sep 17 00:00:00 2001
From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
Date: Tue, 26 Mar 2019 13:08:09 -0400
Subject: [PATCH 3/7] Update all_nodes.dm
---
code/modules/research/techweb/all_nodes.dm | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/code/modules/research/techweb/all_nodes.dm b/code/modules/research/techweb/all_nodes.dm
index e7bbd468dc..fe7ee491c8 100644
--- a/code/modules/research/techweb/all_nodes.dm
+++ b/code/modules/research/techweb/all_nodes.dm
@@ -100,6 +100,15 @@
research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500)
export_price = 5000
+/datum/techweb_node/adv_defibrillator_tec
+ id = "adv_defibrillator_tec"
+ display_name = "Adv Defibrillator tec"
+ description = "More ways to bring back the freshly dead."
+ prereq_ids = list("adv_biotech", "exp_surgery", "adv_engi", "adv_power")
+ design_ids = list("defib_decay", "defib_shock", "defib_heal", "defib_speed")
+ research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500)
+ export_price = 5000
+
/////////////////////////Advanced Surgery/////////////////////////
/datum/techweb_node/adv_surgery
id = "adv_surgery"
From 558eba89ecd70848bfaa1a649b2e4798a7862bac Mon Sep 17 00:00:00 2001
From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
Date: Tue, 26 Mar 2019 13:09:29 -0400
Subject: [PATCH 4/7] Add files via upload
---
modular_citadel/icons/obj/defib_disks.dmi | Bin 0 -> 1387 bytes
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 modular_citadel/icons/obj/defib_disks.dmi
diff --git a/modular_citadel/icons/obj/defib_disks.dmi b/modular_citadel/icons/obj/defib_disks.dmi
new file mode 100644
index 0000000000000000000000000000000000000000..8908b0cf98c584556b0df25731b685126576149e
GIT binary patch
literal 1387
zcmYk63pCVO9LN8Y$IQ?~nOU(IYio-VQdne+C68nv2oIFnO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mon Sep 17 00:00:00 2001
From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
Date: Tue, 26 Mar 2019 13:13:22 -0400
Subject: [PATCH 5/7] Cant count Lilly
---
code/game/objects/items/defib.dm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/code/game/objects/items/defib.dm b/code/game/objects/items/defib.dm
index 674bfe8588..0f758d16ef 100644
--- a/code/game/objects/items/defib.dm
+++ b/code/game/objects/items/defib.dm
@@ -538,7 +538,7 @@
user.visible_message("[user] begins to place [src] on [H]'s chest.", "You begin to place [src] on [H]'s chest...")
busy = TRUE
update_icon()
- if(do_after(user, 30 - defib.primetime, target = H))) //beginning to place the paddles on patient's chest to allow some time for people to move away to stop the process
+ if(do_after(user, 30 - defib.primetime, target = H)) //beginning to place the paddles on patient's chest to allow some time for people to move away to stop the process
user.visible_message("[user] places [src] on [H]'s chest.", "You place [src] on [H]'s chest.")
playsound(src, 'sound/machines/defib_charge.ogg', 75, 0)
var/tplus = world.time - H.timeofdeath
From 1bf175a3c07f9a122a1fa98f12ff91742af4474b Mon Sep 17 00:00:00 2001
From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
Date: Tue, 26 Mar 2019 13:19:02 -0400
Subject: [PATCH 6/7] Hmm
---
code/game/objects/items/defib.dm | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/code/game/objects/items/defib.dm b/code/game/objects/items/defib.dm
index 0f758d16ef..2fd5daae57 100644
--- a/code/game/objects/items/defib.dm
+++ b/code/game/objects/items/defib.dm
@@ -445,7 +445,9 @@
return (!H.suiciding && !(H.has_trait(TRAIT_NOCLONE)) && !H.hellbound && ((world.time - H.timeofdeath) < tlimit) && (H.getBruteLoss() < 180) && (H.getFireLoss() < 180) && H.getorgan(/obj/item/organ/heart) && BR && !BR.damaged_brain)
/obj/item/twohanded/shockpaddles/proc/shock_touching(dmg, mob/H)
- if(isliving(H.pulledby)) //CLEAR!
+ if(defib.pullshocksafely && isliving(H.pulledby))
+ H.visible_message("The defibrillator safely discharges the excessive charge into the floor!")
+ else
var/mob/living/M = H.pulledby
if(M.electrocute_act(30, src))
M.visible_message("[M] is electrocuted by [M.p_their()] contact with [H]!")
@@ -634,12 +636,6 @@
busy = FALSE
update_icon()
-/obj/item/twohanded/shockpaddles/shock_touching(dmg, mob/H)
- if(defib.pullshocksafely && isliving(H.pulledby))
- H.visible_message("The defibrillator safely discharges the excessive charge into the floor!")
- return
- ..()
-
/obj/item/defibrillator/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/disk/medical/defib_heal))
if(healdisk)
From 09c6abd19c053d0b08baab13db70304b832dd1be Mon Sep 17 00:00:00 2001
From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
Date: Wed, 27 Mar 2019 15:19:47 -0400
Subject: [PATCH 7/7] maybe
---
code/game/objects/items/defib.dm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/code/game/objects/items/defib.dm b/code/game/objects/items/defib.dm
index 2fd5daae57..ba0aa36634 100644
--- a/code/game/objects/items/defib.dm
+++ b/code/game/objects/items/defib.dm
@@ -447,7 +447,7 @@
/obj/item/twohanded/shockpaddles/proc/shock_touching(dmg, mob/H)
if(defib.pullshocksafely && isliving(H.pulledby))
H.visible_message("The defibrillator safely discharges the excessive charge into the floor!")
- else
+ else
var/mob/living/M = H.pulledby
if(M.electrocute_act(30, src))
M.visible_message("[M] is electrocuted by [M.p_their()] contact with [H]!")