diff --git a/code/modules/mining/equipment_locker.dm b/code/modules/mining/equipment_locker.dm
index 12ec53f1011..aea31a8d9cf 100644
--- a/code/modules/mining/equipment_locker.dm
+++ b/code/modules/mining/equipment_locker.dm
@@ -475,7 +475,7 @@
/obj/item/device/wormhole_jaunter
name = "wormhole jaunter"
- desc = "A single use device harnessing outdated wormhole technology, Nanotrasen has since turned its eyes to blue space for more accurate teleportation. The wormholes it creates are unpleasant to travel through, to say the least."
+ desc = "A single use device harnessing outdated wormhole technology, Nanotrasen has since turned its eyes to blue space for more accurate teleportation. The wormholes it creates are unpleasant to travel through, to say the least.\nThanks to modifications provided by the Free Golems, this jaunter can be worn on the belt to provide protection from chasms."
icon = 'icons/obj/mining.dmi'
icon_state = "Jaunter"
item_state = "electronic"
@@ -484,28 +484,58 @@
throw_speed = 3
throw_range = 5
origin_tech = "bluespace=2"
+ slot_flags = SLOT_BELT
/obj/item/device/wormhole_jaunter/attack_self(mob/user)
+ user.visible_message("[user.name] activates the [src.name]!")
+ activate(user)
+
+/obj/item/device/wormhole_jaunter/proc/turf_check(mob/user)
var/turf/device_turf = get_turf(user)
if(!device_turf||device_turf.z==2||device_turf.z>=7)
user << "You're having difficulties getting the [src.name] to work."
+ return FALSE
+ return TRUE
+
+/obj/item/device/wormhole_jaunter/proc/activate(mob/user)
+ if(!turf_check(user))
return
+
+ var/list/L = list()
+ for(var/obj/item/device/radio/beacon/B in world)
+ var/turf/T = get_turf(B)
+ if(T.z == ZLEVEL_STATION)
+ L += B
+ if(!L.len)
+ user << "The [src.name] found no beacons in the world to anchor a wormhole to."
+ return
+ var/chosen_beacon = pick(L)
+ var/obj/effect/portal/wormhole/jaunt_tunnel/J = new /obj/effect/portal/wormhole/jaunt_tunnel(get_turf(src), chosen_beacon, lifespan=100)
+ J.target = chosen_beacon
+ try_move_adjacent(J)
+ playsound(src,'sound/effects/sparks4.ogg',50,1)
+ qdel(src)
+
+/obj/item/device/wormhole_jaunter/emp_act(power)
+ var/triggered = FALSE
+
+ if(usr.get_item_by_slot(slot_belt) == src)
+ if(power == 1)
+ triggered = TRUE
+ else if(power == 2 && prob(50))
+ triggered = TRUE
+
+ if(triggered)
+ usr.visible_message("The [src] overloads and activates!")
+ activate(usr)
+
+/obj/item/device/wormhole_jaunter/proc/chasm_react(mob/user)
+ if(user.get_item_by_slot(slot_belt) == src)
+ user << "Your [src] activates, saving you from the chasm!"
+ activate(user)
else
- user.visible_message("[user.name] activates the [src.name]!")
- var/list/L = list()
- for(var/obj/item/device/radio/beacon/B in world)
- var/turf/T = get_turf(B)
- if(T.z == ZLEVEL_STATION)
- L += B
- if(!L.len)
- user << "The [src.name] failed to create a wormhole."
- return
- var/chosen_beacon = pick(L)
- var/obj/effect/portal/wormhole/jaunt_tunnel/J = new /obj/effect/portal/wormhole/jaunt_tunnel(get_turf(src), chosen_beacon, lifespan=100)
- J.target = chosen_beacon
- try_move_adjacent(J)
- playsound(src,'sound/effects/sparks4.ogg',50,1)
- qdel(src)
+ user << "The [src] is not attached to your belt, preventing it from saving you from the chasm. RIP."
+
/obj/effect/portal/wormhole/jaunt_tunnel
name = "jaunt tunnel"
@@ -518,6 +548,8 @@
return
if(istype(M, /atom/movable))
if(do_teleport(M, target, 6))
+ // KERPLUNK
+ playsound(M,'sound/weapons/resonator_blast.ogg',50,1)
if(iscarbon(M))
var/mob/living/carbon/L = M
L.Weaken(3)
@@ -1019,20 +1051,20 @@
/*********************Hivelord stabilizer****************/
/obj/item/weapon/hivelordstabilizer
- name = "hivelord stabilizer"
+ name = "stabilizing serum"
icon = 'icons/obj/chemical.dmi'
icon_state = "bottle19"
- desc = "Inject a hivelord core with this stabilizer to preserve its healing powers indefinitely."
+ desc = "Inject certain types of monster organs with this stabilizer to preserve their healing powers indefinitely."
w_class = 1
origin_tech = "biotech=1"
/obj/item/weapon/hivelordstabilizer/afterattack(obj/item/organ/internal/M, mob/user)
var/obj/item/organ/internal/hivelord_core/C = M
if(!istype(C, /obj/item/organ/internal/hivelord_core))
- user << "The stabilizer only works on hivelord cores."
+ user << "The stabilizer only works on certain types of monster organs, generally regenerative in nature."
return ..()
C.preserved = 1
- user << "You inject the hivelord core with the stabilizer. It will no longer go inert."
+ user << "You inject the [M] with the stabilizer. It will no longer go inert."
qdel(src)
@@ -1081,7 +1113,7 @@
new /datum/data/mining_equipment("Alien Toy", /obj/item/clothing/mask/facehugger/toy, 300),
new /datum/data/mining_equipment("Monkey Cube", /obj/item/weapon/reagent_containers/food/snacks/monkeycube, 300),
new /datum/data/mining_equipment("Toolbelt", /obj/item/weapon/storage/belt/utility, 350),
- new /datum/data/mining_equipment("Hivelord Stabilizer", /obj/item/weapon/hivelordstabilizer, 400),
+ new /datum/data/mining_equipment("Stabilizing Serum", /obj/item/weapon/hivelordstabilizer, 400),
new /datum/data/mining_equipment("Shelter Capsule", /obj/item/weapon/survivalcapsule, 400),
new /datum/data/mining_equipment("GAR scanners", /obj/item/clothing/glasses/meson/gar, 500),
new /datum/data/mining_equipment("Sulphuric Acid", /obj/item/weapon/reagent_containers/glass/beaker/sulphuric, 500),
@@ -1110,4 +1142,4 @@
component_parts += new /obj/item/weapon/stock_parts/matter_bin(null)
component_parts += new /obj/item/weapon/stock_parts/matter_bin(null)
component_parts += new /obj/item/weapon/stock_parts/console_screen(null)
- RefreshParts()
\ No newline at end of file
+ RefreshParts()
diff --git a/code/modules/mining/mine_turfs.dm b/code/modules/mining/mine_turfs.dm
index 3d5f72946dd..491db033ef7 100644
--- a/code/modules/mining/mine_turfs.dm
+++ b/code/modules/mining/mine_turfs.dm
@@ -563,12 +563,23 @@
/turf/open/chasm/Entered(atom/movable/AM)
if(istype(AM, /obj/singularity) || istype(AM, /obj/item/projectile))
return
+ if(istype(AM, /obj/effect/portal))
+ // Portals aren't affected by gravity. Probably.
+ return
// Flies right over the chasm
if(istype(AM, /mob/living/simple_animal))
// apparently only simple_animals can fly??
var/mob/living/simple_animal/SA = AM
if(SA.flying)
return
+ if(istype(AM, /mob/living/carbon/human))
+ var/mob/living/carbon/human/H = AM
+ if(istype(H.belt, /obj/item/device/wormhole_jaunter))
+ var/obj/item/device/wormhole_jaunter/J = H.belt
+ // To freak out any bystanders
+ visible_message("[H] falls into [src]!")
+ J.chasm_react(H)
+ return
drop(AM)