diff --git a/baystation12.dme b/baystation12.dme
index 2218c3fa7cd..075645d281c 100644
--- a/baystation12.dme
+++ b/baystation12.dme
@@ -533,6 +533,7 @@
#include "code\game\machinery\computer\communications.dm"
#include "code\game\machinery\computer\computer.dm"
#include "code\game\machinery\computer\crew.dm"
+#include "code\game\machinery\computer\HolodeckControl.dm"
#include "code\game\machinery\computer\hologram.dm"
#include "code\game\machinery\computer\id.dm"
#include "code\game\machinery\computer\lockdown.dm"
diff --git a/code/defines/procs/helpers.dm b/code/defines/procs/helpers.dm
index 88ce01f0c4a..304645172f6 100644
--- a/code/defines/procs/helpers.dm
+++ b/code/defines/procs/helpers.dm
@@ -1534,6 +1534,172 @@ proc/listclearnulls(list/list)
+proc/DuplicateObject(obj/original, var/perfectcopy = 0 , var/sameloc = 0)
+ if(!original)
+ return null
+
+ var/obj/O = null
+
+ if(sameloc)
+ O=new original.type(original.loc)
+ else
+ O=new original.type(locate(0,0,0))
+
+ if(perfectcopy)
+ if((O) && (original))
+ for(var/V in original.vars)
+ if(!(V in list("type","loc","locs","vars", "parent", "parent_type","verbs","ckey","key")))
+ O.vars[V] = original.vars[V]
+ return O
+
+
+/area/proc/copy_contents_to(var/area/A , var/platingRequired = 0 )
+ //Takes: Area. Optional: If it should copy to areas that don't have plating
+ //Returns: Nothing.
+ //Notes: Attempts to move the contents of one area to another area.
+ // Movement based on lower left corner. Tiles that do not fit
+ // into the new area will not be moved.
+
+ if(!A || !src) return 0
+
+ var/list/turfs_src = get_area_turfs(src.type)
+ var/list/turfs_trg = get_area_turfs(A.type)
+
+ var/src_min_x = 0
+ var/src_min_y = 0
+ for (var/turf/T in turfs_src)
+ if(T.x < src_min_x || !src_min_x) src_min_x = T.x
+ if(T.y < src_min_y || !src_min_y) src_min_y = T.y
+
+ var/trg_min_x = 0
+ var/trg_min_y = 0
+ for (var/turf/T in turfs_trg)
+ if(T.x < trg_min_x || !trg_min_x) trg_min_x = T.x
+ if(T.y < trg_min_y || !trg_min_y) trg_min_y = T.y
+
+ var/list/refined_src = new/list()
+ for(var/turf/T in turfs_src)
+ refined_src += T
+ refined_src[T] = new/datum/coords
+ var/datum/coords/C = refined_src[T]
+ C.x_pos = (T.x - src_min_x)
+ C.y_pos = (T.y - src_min_y)
+
+ var/list/refined_trg = new/list()
+ for(var/turf/T in turfs_trg)
+ refined_trg += T
+ refined_trg[T] = new/datum/coords
+ var/datum/coords/C = refined_trg[T]
+ C.x_pos = (T.x - trg_min_x)
+ C.y_pos = (T.y - trg_min_y)
+
+ var/list/toupdate = new/list()
+
+ var/copiedobjs = list()
+
+
+ moving:
+ for (var/turf/T in refined_src)
+ var/datum/coords/C_src = refined_src[T]
+ for (var/turf/B in refined_trg)
+ var/datum/coords/C_trg = refined_trg[B]
+ if(C_src.x_pos == C_trg.x_pos && C_src.y_pos == C_trg.y_pos)
+
+ var/old_dir1 = T.dir
+ var/old_icon_state1 = T.icon_state
+ var/old_icon1 = T.icon
+
+ if(platingRequired)
+ if(istype(B, /turf/space))
+ continue moving
+
+ var/turf/X = new T.type(B)
+ X.dir = old_dir1
+ X.icon_state = old_icon_state1
+ X.icon = old_icon1 //Shuttle floors are in shuttle.dmi while the defaults are floors.dmi
+
+
+ var/list/objs = new/list()
+ var/list/newobjs = new/list()
+ var/list/mobs = new/list()
+ var/list/newmobs = new/list()
+
+ for(var/obj/O in T)
+
+ if(!istype(O,/obj))
+ continue
+
+ objs += O
+
+
+ for(var/obj/O in objs)
+ newobjs += DuplicateObject(O , 1)
+
+
+ for(var/obj/O in newobjs)
+ O.loc = X
+
+ for(var/mob/M in T)
+
+ if(!istype(M,/mob))
+ continue
+
+ mobs += M
+
+ for(var/mob/M in mobs)
+ newmobs += DuplicateObject(M , 1)
+
+ for(var/mob/M in newmobs)
+ M.loc = X
+
+ copiedobjs += newobjs
+ copiedobjs += newmobs
+
+
+
+ for(var/V in T.vars)
+ if(!(V in list("type","loc","locs","vars", "parent", "parent_type","verbs","ckey","key","x","y","z","contents", "luminosity", "sd_light_spill",)))
+ X.vars[V] = T.vars[V]
+
+ var/area/AR = X.loc
+
+ if(AR.sd_lighting)
+ X.opacity = !X.opacity
+ X.sd_SetOpacity(!X.opacity)
+
+ toupdate += X
+
+ refined_src -= T
+ refined_trg -= B
+ continue moving
+
+
+
+
+ var/list/doors = new/list()
+
+ if(toupdate.len)
+ for(var/turf/simulated/T1 in toupdate)
+ for(var/obj/machinery/door/D2 in T1)
+ doors += D2
+ if(T1.parent)
+ air_master.groups_to_rebuild += T1.parent
+ else
+ air_master.tiles_to_update += T1
+
+ for(var/obj/O in doors)
+ O:update_nearby_tiles(1)
+
+
+
+
+ return copiedobjs
+
+
+
+
+
+
proc/get_cardinal_dir(atom/A, atom/B)
var/dx = abs(B.x - A.x)
var/dy = abs(B.y - A.y)
diff --git a/code/game/machinery/computer/HolodeckControl.dm b/code/game/machinery/computer/HolodeckControl.dm
new file mode 100644
index 00000000000..6d29232f04a
--- /dev/null
+++ b/code/game/machinery/computer/HolodeckControl.dm
@@ -0,0 +1,458 @@
+/obj/machinery/computer/HolodeckControl
+ name = "Holodeck Control Computer"
+ desc = "A computer used to control a nearby holodeck."
+ icon_state = "computer_generic"
+ var/area/linkedholodeck = null
+ var/area/target = null
+ var/active = 0
+ var/list/holographic_items = list()
+ var/damaged = 0
+
+
+ attack_ai(var/mob/user as mob)
+ return src.attack_hand(user)
+
+ attack_paw(var/mob/user as mob)
+ return
+
+ attack_hand(var/mob/user as mob)
+
+ if(..())
+ return
+ user.machine = src
+ var/dat
+
+
+ dat += "Holodeck Control System
"
+ dat += "
Current Loaded Programs:
"
+
+ dat += "((Empty Court))
"
+ dat += "((Boxing Court))
"
+ dat += "((Thunderdome Court))
"
+ dat += "((Beach))
"
+// dat += "((Shutdown System))
"
+
+ dat += "Please ensure that only holographic weapons are used in the holodeck if a combat simulation has been loaded.
"
+
+ if(issilicon(user) && !emagged)
+ dat += "(Override Safety Protocols?)
"
+
+ if(emagged)
+ dat += "(Begin Atmospheric Burn Simulation)
"
+ dat += "Ensure the holodeck is empty before testing.
"
+ dat += "
"
+ dat += "(Begin Wildlife Simulation)
"
+ dat += "Ensure the holodeck is empty before testing.
"
+ dat += "
"
+ dat += "Safety Protocols are DISABLED
"
+ else
+ dat += "
"
+ dat += "Safety Protocols are ENABLED
"
+
+ user << browse(dat, "window=computer;size=400x500")
+ onclose(user, "computer")
+
+
+ return
+
+
+ Topic(href, href_list)
+ if(..())
+ return
+ if((usr.contents.Find(src) || (in_range(src, usr) && istype(src.loc, /turf))) || (istype(usr, /mob/living/silicon)))
+ usr.machine = src
+
+ if(href_list["emptycourt"])
+ target = locate(/area/holodeck/source_emptycourt)
+ if(target)
+ loadProgram(target)
+
+ else if(href_list["boxingcourt"])
+ target = locate(/area/holodeck/source_boxingcourt)
+ if(target)
+ loadProgram(target)
+
+ else if(href_list["thunderdomecourt"])
+ target = locate(/area/holodeck/source_thunderdomecourt)
+ if(target)
+ loadProgram(target)
+
+ else if(href_list["beach"])
+ target = locate(/area/holodeck/source_beach)
+ if(target)
+ loadProgram(target)
+
+ else if(href_list["turnoff"])
+ target = locate(/area/holodeck/source_plating)
+ if(target)
+ loadProgram(target)
+
+ else if(href_list["burntest"])
+ target = locate(/area/holodeck/source_burntest)
+ if(target)
+ loadProgram(target)
+
+ else if(href_list["wildlifecarp"])
+ target = locate(/area/holodeck/source_wildlife)
+ if(target)
+ loadProgram(target)
+
+ else if(href_list["AIoverride"])
+ emagged = 1
+
+ src.add_fingerprint(usr)
+ src.updateUsrDialog()
+ return
+
+
+
+/obj/machinery/computer/HolodeckControl/attackby(var/obj/item/weapon/D as obj, var/mob/user as mob)
+/* if(istype(D, /obj/item/weapon/screwdriver))
+ playsound(src.loc, 'Screwdriver.ogg', 50, 1)
+ if(do_after(user, 20))
+ if (src.stat & BROKEN)
+ user << "\blue The broken glass falls out."
+ var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
+ new /obj/item/weapon/shard( src.loc )
+ var/obj/item/weapon/circuitboard/comm_traffic/M = new /obj/item/weapon/circuitboard/comm_traffic( A )
+ for (var/obj/C in src)
+ C.loc = src.loc
+ A.circuit = M
+ A.state = 3
+ A.icon_state = "3"
+ A.anchored = 1
+ del(src)
+ else
+ user << "\blue You disconnect the monitor."
+ var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
+ var/obj/item/weapon/circuitboard/comm_traffic/M = new /obj/item/weapon/circuitboard/comm_traffic( A )
+ for (var/obj/C in src)
+ C.loc = src.loc
+ A.circuit = M
+ A.state = 4
+ A.icon_state = "4"
+ A.anchored = 1
+ del(src)
+
+*/
+ if(istype(D, /obj/item/weapon/card/emag) && !emagged)
+ playsound(src.loc, 'sparks4.ogg', 75, 1)
+ emagged = 1
+ user << "\blue You vastly increase projector power and override the safety and security protocols."
+ user << "Warning. Automatic shutoff and derezing protocols have been corrupted. Please call Nanotrasen maintence and do not use the simulator."
+ src.updateUsrDialog()
+ return
+
+/obj/machinery/computer/HolodeckControl/New()
+ ..()
+ linkedholodeck = locate(/area/holodeck/alphadeck)
+ //if(linkedholodeck)
+ // target = locate(/area/holodeck/source_emptycourt)
+ // if(target)
+ // loadProgram(target)
+
+
+/obj/machinery/computer/HolodeckControl/process()
+
+ if(active)
+
+ if(!checkInteg(linkedholodeck))
+ damaged = 1
+ target = locate(/area/holodeck/source_plating)
+ if(target)
+ loadProgram(target)
+ active = 0
+ for(var/mob/M in range(10,src))
+ M.show_message("The holodeck overloads!")
+
+
+ for(var/turf/T in linkedholodeck)
+ if(prob(30))
+ var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
+ s.set_up(2, 1, T)
+ s.start()
+ T.ex_act(3)
+ T.hotspot_expose(1000,500,1)
+
+
+ for(var/item in holographic_items)
+ if(!(get_turf(item) in linkedholodeck))
+ derez(item, 0)
+
+
+
+/obj/machinery/computer/HolodeckControl/proc/derez(var/obj , var/silent = 1)
+ holographic_items.Remove(obj)
+
+ if(istype(obj , /obj/))
+ if(istype(obj:loc , /mob/))
+ var/mob/M = obj:loc
+ M.drop_from_slot(obj)
+
+ if(!silent)
+ var/obj/oldobj = obj
+ for(var/mob/M in viewers(world.view,get_turf(obj)))
+ M << "The [oldobj.name] fades away!"
+ del(obj)
+
+/obj/machinery/computer/HolodeckControl/proc/checkInteg(var/area/A)
+ for(var/turf/T in A)
+ if(istype(T, /turf/space))
+ return 0
+
+ return 1
+
+/obj/machinery/computer/HolodeckControl/proc/togglePower(var/toggleOn = 0)
+
+ if(toggleOn)
+ var/area/targetsource = locate(/area/holodeck/source_emptycourt)
+ holographic_items = targetsource.copy_contents_to(linkedholodeck)
+
+ spawn(30)
+ for(var/obj/effect/landmark/L in linkedholodeck)
+ if(L.name=="Atmospheric Test Start")
+ spawn(20)
+ var/turf/T = get_turf(L)
+ var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
+ s.set_up(2, 1, T)
+ s.start()
+ if(T)
+ T.temperature = 5000
+ T.hotspot_expose(50000,50000,1)
+
+ active = 1
+ else
+ for(var/item in holographic_items)
+ derez(item)
+ var/area/targetsource = locate(/area/holodeck/source_plating)
+ targetsource.copy_contents_to(linkedholodeck , 1)
+ active = 0
+
+
+/obj/machinery/computer/HolodeckControl/proc/loadProgram(var/area/A)
+
+ active = 1
+
+ for(var/item in holographic_items)
+ derez(item)
+
+ for(var/obj/effect/decal/cleanable/blood/B in linkedholodeck)
+ del(B)
+
+ holographic_items = A.copy_contents_to(linkedholodeck , 1)
+
+ if(emagged)
+ for(var/obj/item/weapon/melee/energy/sword/holosword/H in linkedholodeck)
+ H.damtype = BRUTE
+
+ spawn(30)
+ for(var/obj/effect/landmark/L in linkedholodeck)
+ if(L.name=="Atmospheric Test Start")
+ spawn(20)
+ var/turf/T = get_turf(L)
+ var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
+ s.set_up(2, 1, T)
+ s.start()
+ if(T)
+ T.temperature = 5000
+ T.hotspot_expose(50000,50000,1)
+
+
+
+
+
+
+
+
+
+
+// Holographic Items!
+
+/turf/simulated/floor/holofloor/
+ thermal_conductivity = 0
+
+/turf/simulated/floor/holofloor/grass
+ name = "Lush Grass"
+ icon_state = "grass1"
+ floor_tile = new/obj/item/stack/tile/grass
+
+ New()
+ floor_tile.New() //I guess New() isn't run on objects spawned without the definition of a turf to house them, ah well.
+ icon_state = "grass[pick("1","2","3","4")]"
+ ..()
+ spawn(4)
+ update_icon()
+ for(var/direction in cardinal)
+ if(istype(get_step(src,direction),/turf/simulated/floor))
+ var/turf/simulated/floor/FF = get_step(src,direction)
+ FF.update_icon() //so siding get updated properly
+
+/turf/simulated/floor/holofloor/attackby(obj/item/weapon/W as obj, mob/user as mob)
+ return
+ // HOLOFLOOR DOES NOT GIVE A FUCK
+
+
+
+
+
+
+
+
+
+
+/obj/structure/table/holotable
+ name = "table"
+ desc = "A square piece of metal standing on four metal legs. It can not move."
+ icon = 'structures.dmi'
+ icon_state = "table"
+ density = 1
+ anchored = 1.0
+ layer = 2.8
+
+
+/obj/structure/table/holotable/attack_paw(mob/user as mob)
+ return attack_hand(user)
+
+/obj/structure/table/holotable/attack_alien(mob/user as mob) //Removed code for larva since it doesn't work. Previous code is now a larva ability. /N
+ return attack_hand(user)
+
+/obj/structure/table/holotable/attack_animal(mob/living/simple_animal/user as mob) //Removed code for larva since it doesn't work. Previous code is now a larva ability. /N
+ return attack_hand(user)
+
+/obj/structure/table/holotable/attack_hand(mob/user as mob)
+ return // HOLOTABLE DOES NOT GIVE A FUCK
+
+
+/obj/structure/table/holotable/attackby(obj/item/weapon/W as obj, mob/user as mob)
+ if (istype(W, /obj/item/weapon/grab) && get_dist(src,user)<2)
+ var/obj/item/weapon/grab/G = W
+ if(G.state<2)
+ user << "\red You need a better grip to do that!"
+ return
+ G.affecting.loc = src.loc
+ G.affecting.Weaken(5)
+ for(var/mob/O in viewers(world.view, src))
+ if (O.client)
+ O << text("\red [] puts [] on the table.", G.assailant, G.affecting)
+ del(W)
+ return
+
+ if (istype(W, /obj/item/weapon/wrench))
+ user << "It's a holotable! There are no bolts!"
+ return
+
+ if(isrobot(user))
+ return
+
+
+
+/obj/item/clothing/gloves/boxing/hologlove
+ name = "boxing gloves"
+ desc = "Because you really needed another excuse to punch your crewmates."
+ icon_state = "boxing"
+ item_state = "boxing"
+
+/obj/structure/holowindow
+ name = "reinforced window"
+ icon = 'structures.dmi'
+ icon_state = "rwindow"
+ desc = "A window."
+ density = 1
+ layer = 3.2//Just above doors
+ pressure_resistance = 4*ONE_ATMOSPHERE
+ anchored = 1.0
+ flags = ON_BORDER
+
+
+/obj/structure/holowindow/Del()
+ ..()
+
+
+/obj/item/weapon/melee/energy/sword/holosword
+ damtype = HALLOSS
+
+/obj/item/weapon/melee/energy/sword/holosword/green
+ New()
+ color = "green"
+
+/obj/item/weapon/melee/energy/sword/holosword/red
+ New()
+ color = "red"
+
+
+
+
+
+
+/obj/machinery/readybutton
+ name = "Ready Declaration Device"
+ desc = "This device is used to declare ready. If all devices in an area are ready, the event will begin!"
+ icon = 'monitors.dmi'
+ icon_state = "auth_off"
+ var/ready = 0
+ var/area/currentarea = null
+ var/eventstarted = 0
+
+ anchored = 1.0
+ use_power = 1
+ idle_power_usage = 2
+ active_power_usage = 6
+ power_channel = ENVIRON
+
+/obj/machinery/readybutton/attack_ai(mob/user as mob)
+ user << "The station AI is not to interact with these devices"
+ return
+
+/obj/machinery/readybutton/attack_paw(mob/user as mob)
+ user << "You are too primitive to use this device"
+ return
+
+/obj/machinery/readybutton/New()
+ ..()
+
+
+/obj/machinery/readybutton/attackby(obj/item/weapon/W as obj, mob/user as mob)
+ user << "The device is a solid button, there's nothing you can do with it!"
+
+/obj/machinery/readybutton/attack_hand(mob/user as mob)
+ if(user.stat || stat & (NOPOWER|BROKEN))
+ user << "This device is not powered."
+ return
+
+ currentarea = get_area(src.loc)
+ if(!currentarea)
+ del(src)
+
+ if(eventstarted)
+ usr << "The event has already begun!"
+ return
+
+ ready = !ready
+
+ update_icon()
+
+ var/numbuttons = 0
+ var/numready = 0
+ for(var/obj/machinery/readybutton/button in currentarea)
+ numbuttons++
+ if (button.ready)
+ numready++
+
+ if(numbuttons == numready)
+ begin_event()
+
+/obj/machinery/readybutton/update_icon()
+ if(ready)
+ icon_state = "auth_on"
+ else
+ icon_state = "auth_off"
+
+/obj/machinery/readybutton/proc/begin_event()
+
+ eventstarted = 1
+
+ for(var/obj/structure/holowindow/W in currentarea)
+ del(W)
+
+ for(var/mob/M in currentarea)
+ M << "FIGHT!"
\ No newline at end of file
diff --git a/code/modules/mob/living/carbon/human/human_attackhand.dm b/code/modules/mob/living/carbon/human/human_attackhand.dm
index 7d434f659a5..0340f2a925e 100644
--- a/code/modules/mob/living/carbon/human/human_attackhand.dm
+++ b/code/modules/mob/living/carbon/human/human_attackhand.dm
@@ -32,6 +32,30 @@
visible_message("\red [src] has been touched with the stun gloves by [M]!")
return
+ if(istype(M.gloves , /obj/item/clothing/gloves/boxing/hologlove))
+
+ var/damage = rand(0, 9)
+ if(!damage)
+ playsound(loc, 'punchmiss.ogg', 25, 1, -1)
+ visible_message("\red [M] has attempted to punch [src]!")
+ return 0
+ var/datum/organ/external/affecting = get_organ(ran_zone(M.zone_sel.selecting))
+ var/armor_block = run_armor_check(affecting, "melee")
+
+ if(M.mutations & HULK) damage += 5
+ playsound(loc, "punch", 25, 1, -1)
+
+ visible_message("\red [M] has punched [src]!")
+
+ apply_damage(damage, HALLOSS, affecting, armor_block)
+ if(damage >= 9)
+ visible_message("\red [M] has weakened [src]!")
+ apply_effect(4, WEAKEN, armor_block)
+ UpdateDamageIcon()
+
+ return
+
+
switch(M.a_intent)
if("help")
if(health > 0)
diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm
index f88b78787d1..4b96f26273a 100644
--- a/code/modules/mob/living/carbon/human/human_defense.dm
+++ b/code/modules/mob/living/carbon/human/human_defense.dm
@@ -143,7 +143,7 @@ emp_act
apply_damage(power, I.damtype, affecting, armor, is_cut(I), I.name)
var/bloody = 0
- if((I.damtype == BRUTE) && prob(25 + is_sharp(I) * 50 + (I.force * 2)))
+ if(((I.damtype == BRUTE) || (I.damtype == HALLOSS)) && prob(25 + is_sharp(I) * 50 + (I.force * 2)))
I.add_blood(src) //Make the weapon bloody, not the person.
bloody = 1
var/turf/location = loc
diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm
index 58f3628941e..f8f5cf3ea2d 100644
--- a/code/modules/mob/living/carbon/human/life.dm
+++ b/code/modules/mob/living/carbon/human/life.dm
@@ -186,15 +186,29 @@
// a.hallucinate(src)
if(!handling_hal && hallucination > 20)
spawn handle_hallucinations() //The not boring kind!
- hallucination = max(hallucination - 2, 0)
+
+ if(hallucination <= 2)
+ halloss = 0
+ hallucination = 0
+ else
+ hallucination -= 2
//if(health < 0)
// for(var/obj/a in hallucinations)
// del a
else
- halloss = 0
+ //halloss = 0
for(var/atom/a in hallucinations)
del a
+ if(halloss > 100)
+ src << "You're too tired to keep going..."
+ for(var/mob/O in viewers(src, null))
+ if(O == src)
+ continue
+ O.show_message(text("\red [src] slumps to the ground panting, too weak to continue fighting."), 1)
+ Paralyse(15)
+ setHalLoss(99)
+
if(mutations2 & mSmallsize)
if(!(pass_flags & PASSTABLE))
pass_flags |= PASSTABLE
@@ -927,7 +941,7 @@
if(getOxyLoss() > 50) Paralyse(3)
if(sleeping)
-// adjustHalLoss(-5)
+ adjustHalLoss(-5)
if(paralysis <= 0)
Paralyse(2)
if (prob(10) && health && !hal_crit) spawn(0) emote("snore")
diff --git a/code/modules/mob/living/carbon/shock.dm b/code/modules/mob/living/carbon/shock.dm
index d7bca333688..f53ca6f66f0 100644
--- a/code/modules/mob/living/carbon/shock.dm
+++ b/code/modules/mob/living/carbon/shock.dm
@@ -3,7 +3,7 @@
// proc to find out in how much pain the mob is at the moment
/mob/living/carbon/proc/updateshock()
- src.traumatic_shock = src.getOxyLoss() + src.getToxLoss() + src.getFireLoss() + 1.2*src.getBruteLoss() + 2*src.getCloneLoss()
+ src.traumatic_shock = src.getOxyLoss() + src.getToxLoss() + src.getFireLoss() + 1.2*src.getBruteLoss() + 2*src.getCloneLoss() + src.halloss
if(reagents.has_reagent("alkysine"))
src.traumatic_shock -= 10
if(reagents.has_reagent("inaprovaline"))
diff --git a/code/modules/mob/living/damage_procs.dm b/code/modules/mob/living/damage_procs.dm
index b1778089a8c..78e4257cf86 100644
--- a/code/modules/mob/living/damage_procs.dm
+++ b/code/modules/mob/living/damage_procs.dm
@@ -22,18 +22,21 @@
adjustOxyLoss(damage/(blocked+1))
if(CLONE)
adjustCloneLoss(damage/(blocked+1))
+ if(HALLOSS)
+ adjustHalLoss(damage/(blocked+1))
UpdateDamageIcon()
updatehealth()
return 1
-/mob/living/proc/apply_damages(var/brute = 0, var/burn = 0, var/tox = 0, var/oxy = 0, var/clone = 0, var/def_zone = null, var/blocked = 0)
+/mob/living/proc/apply_damages(var/brute = 0, var/burn = 0, var/tox = 0, var/oxy = 0, var/clone = 0, var/def_zone = null, var/blocked = 0, var/halloss = 0)
if(blocked >= 2) return 0
if(brute) apply_damage(brute, BRUTE, def_zone, blocked)
if(burn) apply_damage(burn, BURN, def_zone, blocked)
if(tox) apply_damage(tox, TOX, def_zone, blocked)
if(oxy) apply_damage(oxy, OXY, def_zone, blocked)
if(clone) apply_damage(clone, CLONE, def_zone, blocked)
+ if(halloss) apply_damage(halloss, HALLOSS, def_zone, blocked)
return 1
diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm
index fa15f854fdf..9ac8ee68130 100644
--- a/code/modules/mob/mob.dm
+++ b/code/modules/mob/mob.dm
@@ -1149,3 +1149,66 @@ note dizziness decrements automatically in the mob's Life() proc.
/mob/proc/AdjustParalysis(amount)
paralysis = max(paralysis + amount,0)
return
+
+// ++++ROCKDTBEN++++ MOB PROCS -- Ask me before touching
+
+/mob/proc/getBruteLoss()
+ return bruteloss
+
+/mob/proc/adjustBruteLoss(var/amount)
+ bruteloss = max(bruteloss + amount, 0)
+
+/mob/proc/getOxyLoss()
+ return oxyloss
+
+/mob/proc/adjustOxyLoss(var/amount)
+ oxyloss = max(oxyloss + amount, 0)
+
+/mob/proc/setOxyLoss(var/amount)
+ oxyloss = amount
+
+/mob/proc/getToxLoss()
+ return toxloss
+
+/mob/proc/adjustToxLoss(var/amount)
+ toxloss = max(toxloss + amount, 0)
+
+/mob/proc/setToxLoss(var/amount)
+ toxloss = amount
+
+/mob/proc/getFireLoss()
+ return fireloss
+
+/mob/proc/adjustFireLoss(var/amount)
+ fireloss = max(fireloss + amount, 0)
+
+/mob/proc/getCloneLoss()
+ return cloneloss
+
+/mob/proc/adjustCloneLoss(var/amount)
+ cloneloss = max(cloneloss + amount, 0)
+
+/mob/proc/setCloneLoss(var/amount)
+ cloneloss = amount
+
+/mob/proc/getHalLoss()
+ return halloss
+
+/mob/proc/adjustHalLoss(var/amount)
+ halloss = max(halloss + amount, 0)
+
+/mob/proc/setHalLoss(var/amount)
+ halloss = amount
+
+
+
+/mob/proc/getBrainLoss()
+ return brainloss
+
+/mob/proc/adjustBrainLoss(var/amount)
+ brainloss = max(brainloss + amount, 0)
+
+/mob/proc/setBrainLoss(var/amount)
+ brainloss = amount
+
+// ++++ROCKDTBEN++++ MOB PROCS //END
\ No newline at end of file
diff --git a/code/modules/mob/mob_defines.dm b/code/modules/mob/mob_defines.dm
index 1da6a25f4f3..a727014738f 100644
--- a/code/modules/mob/mob_defines.dm
+++ b/code/modules/mob/mob_defines.dm
@@ -288,58 +288,3 @@ the mob is also allowed to move without any sort of restriction. For instance, i
//Singularity wants you!
var/grav_delay = 0
var/being_strangled = 0
-
-
-
-// ++++ROCKDTBEN++++ MOB PROCS
-
-/mob/proc/getBruteLoss()
- return bruteloss
-
-/mob/proc/adjustBruteLoss(var/amount)
- bruteloss = max(bruteloss + amount, 0)
-
-/mob/proc/getOxyLoss()
- return oxyloss
-
-/mob/proc/adjustOxyLoss(var/amount)
- oxyloss = max(oxyloss + amount, 0)
-
-/mob/proc/setOxyLoss(var/amount)
- oxyloss = amount
-
-/mob/proc/getToxLoss()
- return toxloss
-
-/mob/proc/adjustToxLoss(var/amount)
- toxloss = max(toxloss + amount, 0)
-
-/mob/proc/setToxLoss(var/amount)
- toxloss = amount
-
-/mob/proc/getFireLoss()
- return fireloss
-
-/mob/proc/adjustFireLoss(var/amount)
- fireloss = max(fireloss + amount, 0)
-
-/mob/proc/getCloneLoss()
- return cloneloss
-
-/mob/proc/adjustCloneLoss(var/amount)
- cloneloss = max(cloneloss + amount, 0)
-
-/mob/proc/setCloneLoss(var/amount)
- cloneloss = amount
-
-/mob/proc/getBrainLoss()
- return brainloss
-
-/mob/proc/adjustBrainLoss(var/amount)
- brainloss = max(brainloss + amount, 0)
-
-/mob/proc/setBrainLoss(var/amount)
- brainloss = amount
-
-// ++++ROCKDTBEN++++ MOB PROCS //END
-