Merge pull request #10986 from Seris02/atomwalkers

wall walking boots for traitors
This commit is contained in:
Ghom
2020-04-13 14:25:43 +02:00
committed by GitHub
7 changed files with 109 additions and 1 deletions
@@ -377,3 +377,99 @@
name = "black cowboy boots"
desc = "A pair of black cowboy boots, pretty easy to scuff up."
icon_state = "cowboyboots_black"
/obj/item/clothing/shoes/wallwalkers
name = "wall walking boots"
desc = "Contrary to popular belief, these do not allow you to walk on walls. Through bluespace magic stolen from an organisation that hoards technology, they simply allow you to slip through the atoms that make up anything, but only while walking, for safety reasons. As well as this, they unfortunately cause minor breath loss as the majority of atoms in your lungs are sucked out into any solid object you walk through. Make sure not to overuse them."
icon_state = "walkboots"
var/walkcool = 0
var/wallcharges = 4
var/newlocobject = null
/obj/item/clothing/shoes/wallwalkers/equipped(mob/user,slot)
. = ..()
if(slot == SLOT_SHOES)
RegisterSignal(user, COMSIG_MOB_CLIENT_MOVE,.proc/intercept_user_move)
/obj/item/clothing/shoes/wallwalkers/dropped(mob/user)
. = ..()
UnregisterSignal(user, COMSIG_MOB_CLIENT_MOVE)
/obj/item/clothing/shoes/wallwalkers/attackby(obj/item/W, mob/user, params)
. = ..()
if(!istype(W, /obj/item/bluespacerecharge))
return
var/obj/item/bluespacerecharge/ER = W
if(ER.uses)
wallcharges += ER.uses
to_chat(user, "<span class='notice'>You charged the bluespace crystal in the [src]. It now has [wallcharges] charges left.</span>")
ER.uses = 0
ER.icon_state = "[initial(ER.icon_state)]0"
else
to_chat(user, "<span class='warning'>[ER] has no crystal on it.</span>")
/obj/item/clothing/shoes/wallwalkers/examine(mob/user)
. = ..()
. += "<span class='warning'>It has [wallcharges] charges left.</span>"
/obj/item/clothing/shoes/wallwalkers/proc/intercept_user_move(mob/living/m, client/client, dir, newloc, oldloc)
if (walkcool >= world.time || m.m_intent != MOVE_INTENT_WALK || wallcharges <= 0)
return
walkcool = world.time + m.movement_delay()
var/issolid = FALSE
var/turf/K = newloc
if (istype(K))
if (K.density)
issolid = TRUE
if (!issolid)
for (var/atom/T in newloc) //stuff on the new turf
if (!T.CanPass(m,newloc) && T != m)
issolid = TRUE
newlocobject = T
break
if (!issolid)
for (var/atom/T in oldloc) //directional shit on the old turf
if (!T.CanPass(m,newloc) && T != m && T != newlocobject)
issolid = TRUE
break
newlocobject = null //stopping structures from using two charges because of how shitty the canpass code is
m.forceMove(newloc)
if (!issolid)
return
m.adjustOxyLoss(rand(5,13))
if (prob(15))
m.adjustBruteLoss(rand(4,7))
to_chat(m,"<span class='warning'>You feel as if travelling through the solid object left something behind and it hurts!</span>")
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
s.set_up(5, 1, oldloc)
s.start()
flash_lighting_fx(3, 3, LIGHT_COLOR_ORANGE)
wallcharges--
/obj/item/bluespacerecharge
name = "bluespace crystal recharging device"
desc = "A small cell with two prongs lazily jabbed into it. It looks like it's made for replacing the crystals in bluespace devices."
icon = 'icons/obj/module.dmi'
icon_state = "bluespace_charge"
item_flags = NOBLUDGEON
w_class = WEIGHT_CLASS_TINY
var/uses = 6
/obj/item/bluespacerecharge/examine(mob/user)
. = ..()
if(uses)
. += "<span class='notice'>It can add up to [uses] charges to compatible devices.</span>"
else
. += "<span class='warning'>The crystal is gone.</span>"
/obj/item/bluespacerecharge/attackby(obj/item/I, mob/user, params)
..()
if(!istype(I, /obj/item/stack/ore/bluespace_crystal) || uses)
return
var/obj/item/stack/ore/bluespace_crystal/B = I
if (B.amount < 10)
return
uses += 3
to_chat(user, "<span class='notice'>You insert [I] into [src].</span>")
B.use(10)
icon_state = initial(icon_state)
@@ -83,4 +83,10 @@
name = "Thieving Gloves"
desc = "A pair of gloves that are insulated and frictionless, allowing you to steal easily from anyone you see."
item = /obj/item/clothing/gloves/thief
cost = 4
cost = 4
/datum/uplink_item/suits/wallwalkers
name = "Wall Walking Boots"
desc = "Through bluespace magic stolen from an organisation that hoards technology, these boots simply allow you to slip through the atoms that make up anything, but only while walking, for safety reasons. As well as this, they unfortunately cause minor breath loss as the majority of atoms in your lungs are sucked out into any solid object you walk through."
item = /obj/item/clothing/shoes/wallwalkers
cost = 6
@@ -20,6 +20,12 @@
item = /obj/item/emagrecharge
cost = 2
/datum/uplink_item/device_tools/bluespacerecharge
name = "Bluespace Crystal Recharging Device"
desc = "A small device intended for recharging Wall Walking boots. Using it will add six charges to them. Use ten bluespace crystals on this recharger to add three more charges to it. "
item = /obj/item/bluespacerecharge
cost = 2
/datum/uplink_item/device_tools/phantomthief
name = "Syndicate Mask"
desc = "A cheap plastic mask fitted with an adrenaline autoinjector, which can be used by simply tensing your muscles"