Cloud IX Crate (#29100)
* Cloud IX Crate * add atom * and removes duplicates * progress * Just changing a couple more files * finished * fixes
@@ -61,3 +61,13 @@
|
||||
if(result == BLOCKED)
|
||||
return BLOCKED
|
||||
return result
|
||||
|
||||
/atom/proc/update_nearby_tiles(var/turf/T)
|
||||
if(!SS_READY(SSair))
|
||||
return 0
|
||||
|
||||
if(!T)
|
||||
T = get_turf(src)
|
||||
if(isturf(T))
|
||||
SSair.mark_for_update(T)
|
||||
return 1
|
||||
@@ -128,7 +128,7 @@ var/list/wireColours = list("red", "blue", "green", "black", "orange", "brown",
|
||||
I = L.get_active_hand()
|
||||
holder.add_hiddenprint(L)
|
||||
if(href_list["cut"]) // Toggles the cut/mend status
|
||||
if(iswirecutter(I) || isswitchtool(I))
|
||||
if(I.is_wirecutter(L) || isswitchtool(I))
|
||||
var/colour = href_list["cut"]
|
||||
CutWireColour(colour)
|
||||
holder.investigation_log(I_WIRES, "|| [GetWireName(wires[colour]) || colour] wire [IsColourCut(colour) ? "cut" : "mended"] by [key_name(usr)] ([src.type])")
|
||||
@@ -136,7 +136,7 @@ var/list/wireColours = list("red", "blue", "green", "black", "orange", "brown",
|
||||
to_chat(L, "<span class='error'>You need wirecutters!</span>")
|
||||
|
||||
else if(href_list["pulse"])
|
||||
if(ismultitool(I) || isswitchtool(I))
|
||||
if(I.is_multitool(L) || isswitchtool(I))
|
||||
var/colour = href_list["pulse"]
|
||||
PulseColour(colour)
|
||||
holder.investigation_log(I_WIRES, "|| [GetWireName(wires[colour]) || colour] wire pulsed by [key_name(usr)] ([src.type])")
|
||||
|
||||
@@ -320,7 +320,7 @@
|
||||
var/obj/item/I = O
|
||||
if(istype(O, /obj/item/weapon/legcuffs/bolas)) //don't stack into infinity
|
||||
return
|
||||
if(iswirecutter(I)) //allows you to convert the wire back to a cable coil
|
||||
if(I.is_wirecutter(user)) //allows you to convert the wire back to a cable coil
|
||||
if(!weight1 && !weight2) //if there's nothing attached
|
||||
user.show_message("<span class='notice'>You cut the knot in the [src].</span>")
|
||||
I.playtoolsound(usr, 50)
|
||||
@@ -879,7 +879,7 @@
|
||||
slot_flags = SLOT_HEAD
|
||||
|
||||
/obj/item/weapon/caution/attackby(obj/item/I as obj, mob/user as mob)
|
||||
if(iswirecutter(I))
|
||||
if(I.is_wirecutter(user))
|
||||
to_chat(user, "<span class='info'>You cut apart the cone into plastic.</span>")
|
||||
drop_stack(/obj/item/stack/sheet/mineral/plastic, user.loc, 2, user)
|
||||
qdel(src)
|
||||
|
||||
@@ -1065,7 +1065,7 @@ var/global/list/airalarm_presets = list(
|
||||
|
||||
if(wiresexposed && !wires.IsAllCut() && iswiretool(W))
|
||||
return attack_hand(user)
|
||||
else if(wiresexposed && wires.IsAllCut() && iswirecutter(W))
|
||||
else if(wiresexposed && wires.IsAllCut() && W.is_wirecutter(user))
|
||||
buildstage = 1
|
||||
update_icon()
|
||||
user.visible_message("<span class='attack'>[user] has cut the wiring from \the [src]!</span>", "You have cut the last of the wiring from \the [src].")
|
||||
@@ -1149,6 +1149,14 @@ var/global/list/airalarm_presets = list(
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/machinery/alarm/is_in_range(var/mob/user)
|
||||
if((!in_range(src, user) || !istype(loc, /turf)) && !istype(user, /mob/living/silicon))
|
||||
var/obj/item/device/multitool/omnitool/O = user.get_active_hand()
|
||||
if(istype(O))
|
||||
return O.can_connect(src,user)
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/*
|
||||
FIRE ALARM
|
||||
*/
|
||||
@@ -1266,11 +1274,11 @@ FIRE ALARM
|
||||
if(wiresexposed)
|
||||
switch(buildstage)
|
||||
if(2)
|
||||
if (ismultitool(W))
|
||||
if (W.is_multitool(user))
|
||||
src.detecting = !( src.detecting )
|
||||
user.visible_message("<span class='attack'>[user] has [detecting ? "re" : "dis"]connected [src]'s detecting unit!</span>", "You have [detecting ? "re" : "dis"]connected [src]'s detecting unit.")
|
||||
playsound(src, 'sound/items/healthanalyzer.ogg', 50, 1)
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
to_chat(user, "You begin to cut the wiring...")
|
||||
W.playtoolsound(src, 50)
|
||||
if (do_after(user, src, 50) && buildstage == 2 && wiresexposed)
|
||||
|
||||
@@ -113,7 +113,7 @@
|
||||
break
|
||||
return
|
||||
|
||||
else if(iswirecutter(W))
|
||||
else if(W.is_wirecutter(user))
|
||||
|
||||
new/obj/item/stack/cable_coil(get_turf(src), 2)
|
||||
W.playtoolsound(src, 50)
|
||||
|
||||
@@ -78,7 +78,7 @@
|
||||
to_chat(user, "<span class='notice'>You add cables to the frame.</span>")
|
||||
state = WIREDFRAME
|
||||
if(WIREDFRAME)
|
||||
if(iswirecutter(P))
|
||||
if(P.is_wirecutter(user))
|
||||
if(brain)
|
||||
to_chat(user, "Get that brain out of there first!")
|
||||
else
|
||||
|
||||
@@ -481,7 +481,7 @@
|
||||
|
||||
return 1
|
||||
if(3)
|
||||
if(iswirecutter(P))
|
||||
if(P.is_wirecutter(user))
|
||||
P.playtoolsound(src, 50)
|
||||
user.visible_message("[user] unplugs the wires from the frame.", "You unplug the wires from the frame.", "You hear metallic sounds.")
|
||||
src.state = 2
|
||||
|
||||
@@ -147,7 +147,7 @@
|
||||
else
|
||||
to_chat(user, "<span class='warning'>This frame does not accept circuit boards of this type!</span>")
|
||||
else
|
||||
if(iswirecutter(P))
|
||||
if(P.is_wirecutter(user))
|
||||
P.playtoolsound(src, 50)
|
||||
to_chat(user, "<span class='notice'>You remove the cables.</span>")
|
||||
set_build_state(1)
|
||||
@@ -307,7 +307,7 @@ to destroy them and players will be able to make replacements.
|
||||
//local_fuses = new(src)
|
||||
|
||||
/obj/item/weapon/circuitboard/blank/attackby(obj/item/O as obj, mob/user as mob)
|
||||
/*if(ismultitool(O))
|
||||
/*if(O.is_multitool(user))
|
||||
var/boardType = local_fuses.assigned_boards["[local_fuses.localbit]"] //Localbit is an int, but this is an associative list organized by strings
|
||||
if(boardType)
|
||||
if(ispath(boardType))
|
||||
@@ -800,7 +800,7 @@ obj/item/weapon/circuitboard/rdserver
|
||||
return
|
||||
if(!Adjacent(user) || user.incapacitated())
|
||||
return
|
||||
|
||||
|
||||
var/to_spawn = smartfridge_choices[choice]
|
||||
if(src.type == to_spawn)
|
||||
to_chat(user, "<span class = 'notice'>This board is already this type.</span>")
|
||||
|
||||
@@ -330,7 +330,7 @@ var/global/list/cryo_health_indicator = list( "full" = image("icon" = 'icons/obj
|
||||
investigation_log(I_CHEMS, "was loaded with \a [G] by [key_name(user)], containing [G.reagents.get_reagent_ids(1)]")
|
||||
update_icon()
|
||||
|
||||
if(ismultitool(G) && Adjacent(user))
|
||||
if(G.is_multitool(user) && Adjacent(user))
|
||||
output_dir = get_dir(src, user)
|
||||
to_chat(user, "<span class='notice'>[bicon(src)]Output location set.</span>")
|
||||
return
|
||||
|
||||
@@ -1221,7 +1221,7 @@ About the new airlock wires panel:
|
||||
welded = null
|
||||
|
||||
update_icon()
|
||||
else if (ismultitool(I))
|
||||
else if (I.is_multitool(user))
|
||||
if (!operating)
|
||||
if(panel_open)
|
||||
wires.Interact(user)
|
||||
|
||||
@@ -404,7 +404,7 @@ var/list/all_doors = list()
|
||||
/obj/machinery/door/proc/requiresID()
|
||||
return 1
|
||||
|
||||
/obj/machinery/door/proc/update_nearby_tiles(var/turf/T)
|
||||
/obj/machinery/door/update_nearby_tiles(var/turf/T)
|
||||
if(!SS_READY(SSair))
|
||||
return 0
|
||||
|
||||
|
||||
@@ -282,7 +282,7 @@
|
||||
return smartwindow
|
||||
|
||||
//If its a multitool and our windoor is smart, open the menu
|
||||
if(ismultitool(I) && smartwindow)
|
||||
if(I.is_multitool(user) && smartwindow)
|
||||
smartwindow.update_multitool_menu(user)
|
||||
return
|
||||
|
||||
|
||||
@@ -89,7 +89,7 @@
|
||||
"<span class='warning'>[user.name] has added cables to \the [src]!</span>",\
|
||||
"You add cables to \the [src].")
|
||||
if(2) // Circuitboard installed, wired.
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
to_chat(usr, "You begin to remove the wiring from \the [src].")
|
||||
if(do_after(user, src, 50))
|
||||
new /obj/item/stack/cable_coil(loc,5)
|
||||
|
||||
@@ -6,7 +6,7 @@ var/list/obj/machinery/flasher/flashers = list()
|
||||
desc = "A wall-mounted flashbulb device."
|
||||
icon = 'icons/obj/stationobjs.dmi'
|
||||
icon_state = "mflash1"
|
||||
|
||||
|
||||
var/range = 2 //this is roughly the size of brig cell
|
||||
var/disable = 0
|
||||
var/last_flash = 0 //Don't want it getting spammed like regular flashes
|
||||
@@ -50,7 +50,7 @@ var/list/obj/machinery/flasher/flashers = list()
|
||||
|
||||
//Don't want to render prison breaks impossible
|
||||
/obj/machinery/flasher/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if (iswirecutter(W))
|
||||
if (W.is_wirecutter(user))
|
||||
add_fingerprint(user)
|
||||
src.disable = !src.disable
|
||||
if (src.disable)
|
||||
|
||||
@@ -525,16 +525,6 @@
|
||||
|
||||
src.updateUsrDialog()
|
||||
|
||||
/obj/machinery/smartfridge/proc/update_nearby_tiles(var/turf/T)
|
||||
if(!SS_READY(SSair))
|
||||
return 0
|
||||
|
||||
if(!T)
|
||||
T = get_turf(src)
|
||||
if(isturf(T))
|
||||
SSair.mark_for_update(T)
|
||||
return 1
|
||||
|
||||
/obj/machinery/smartfridge/Cross(atom/movable/mover, turf/target, height=1.5, air_group = 0)
|
||||
if(!istype(mover))
|
||||
return !anchored
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
buildstage = 2
|
||||
power_change()
|
||||
return
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
to_chat(user, "You begin cutting the wiring from \the [src].")
|
||||
W.playtoolsound(src, 50)
|
||||
if(do_after(user, src,10) && buildstage == 1)
|
||||
|
||||
@@ -622,7 +622,7 @@ Class Procs:
|
||||
else
|
||||
return -1
|
||||
|
||||
if(ismultitool(O) && machine_flags & MULTITOOL_MENU)
|
||||
if(O.is_multitool(user) && machine_flags & MULTITOOL_MENU)
|
||||
update_multitool_menu(user)
|
||||
return 1
|
||||
|
||||
|
||||
@@ -192,7 +192,7 @@ var/list/mass_drivers = list()
|
||||
build++
|
||||
update_icon()
|
||||
if(3) // Wired
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
to_chat(user, "You begin to remove the wiring from \the [src].")
|
||||
if(do_after(user, src, 10) && (build == 3))
|
||||
new /obj/item/stack/cable_coil(loc,3)
|
||||
|
||||
@@ -117,7 +117,7 @@
|
||||
if(..(W, user) == 1)
|
||||
return 1 // resolved for click code!
|
||||
|
||||
/*if (iswirecutter(W))
|
||||
/*if (W.is_wirecutter(user))
|
||||
add_fingerprint(user)
|
||||
src.disable = !src.disable
|
||||
if (src.disable)
|
||||
|
||||
@@ -31,18 +31,6 @@
|
||||
else
|
||||
return ..()
|
||||
|
||||
//Looks like copy/pasted code... I doubt 'need_rebuild' is even used here - Nodrak
|
||||
/obj/machinery/shield/proc/update_nearby_tiles()
|
||||
if (!SS_READY(SSair))
|
||||
return 0
|
||||
|
||||
var/T = loc
|
||||
|
||||
if (isturf(T))
|
||||
SSair.mark_for_update(T)
|
||||
|
||||
return 1
|
||||
|
||||
/obj/machinery/shield/attackby(obj/item/weapon/W as obj, mob/living/user as mob)
|
||||
if(!istype(W))
|
||||
return
|
||||
|
||||
@@ -59,7 +59,8 @@
|
||||
// You need a multitool to use this, or be silicon
|
||||
if(!issilicon(user))
|
||||
// istype returns false if the value is null
|
||||
if(!ismultitool(user.get_active_hand()))
|
||||
var/obj/item/I = user.get_active_hand()
|
||||
if(!I.is_multitool(user))
|
||||
return
|
||||
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
|
||||
@@ -1888,7 +1888,7 @@ var/global/num_vending_terminals = 1
|
||||
"<span class='warning'>[user.name] has added cables to \the [src]!</span>",\
|
||||
"You add cables to \the [src].")
|
||||
if(2) // Circuitboard installed, wired.
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
to_chat(usr, "You begin to remove the wiring from \the [src].")
|
||||
if(do_after(user, src, 50))
|
||||
new /obj/item/stack/cable_coil(loc,5)
|
||||
@@ -3145,17 +3145,16 @@ var/global/num_vending_terminals = 1
|
||||
vend_reply = "Money money money!"
|
||||
icon_state = "voxseed"
|
||||
products = list (
|
||||
/obj/item/vaporizer = 1,
|
||||
/obj/item/weapon/storage/trader_chemistry = 1,
|
||||
/obj/structure/closet/secure_closet/wonderful = 1,
|
||||
/obj/item/weapon/disk/shuttle_coords/vault/mecha_graveyard = 1,
|
||||
/obj/machinery/power/antiquesynth = 1,
|
||||
/obj/structure/closet/crate/shoaljunk = 3,
|
||||
/obj/structure/closet/crate/internals/cloudnine = 3,
|
||||
/obj/item/weapon/storage/trader_chemistry = 1,
|
||||
/obj/structure/closet/crate/chest/alcatraz = 3,
|
||||
/obj/item/weapon/storage/lockbox/advanced/energyshotgun = 1,
|
||||
/obj/item/weapon/storage/lockbox/advanced/ricochettaser = 1,
|
||||
/obj/structure/largecrate/secure = 1,
|
||||
/obj/structure/largecrate/secure/magmaw = 1,
|
||||
/obj/structure/largecrate/secure/frankenstein = 1,
|
||||
/obj/item/weapon/mech_expansion_kit = 3,
|
||||
/obj/structure/wetdryvac = 1,
|
||||
@@ -3171,17 +3170,15 @@ var/global/num_vending_terminals = 1
|
||||
/obj/structure/closet/crate/freezer/bootlegpicnic = 3,
|
||||
)
|
||||
prices = list(
|
||||
/obj/item/vaporizer = 10,
|
||||
/obj/item/weapon/storage/trader_chemistry = 50,
|
||||
/obj/structure/closet/secure_closet/wonderful = 150,
|
||||
/obj/item/weapon/disk/shuttle_coords/vault/mecha_graveyard = 100,
|
||||
/obj/machinery/power/antiquesynth = 150,
|
||||
/obj/structure/closet/crate/shoaljunk = 100,
|
||||
/obj/structure/closet/crate/internals/cloudnine = 150,
|
||||
/obj/structure/closet/crate/chest/alcatraz = 150,
|
||||
/obj/item/weapon/storage/lockbox/advanced/energyshotgun = 100,
|
||||
/obj/item/weapon/storage/lockbox/advanced/ricochettaser = 25,
|
||||
/obj/structure/largecrate/secure = 100,
|
||||
/obj/structure/largecrate/secure/magmaw = 100,
|
||||
/obj/structure/largecrate/secure/frankenstein = 100,
|
||||
/obj/item/weapon/mech_expansion_kit = 50,
|
||||
/obj/structure/wetdryvac = 50,
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
to_chat(user, "You failed to salvage anything valuable from [src].")
|
||||
else
|
||||
return
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
if(isemptylist(wirecutters_salvage))
|
||||
to_chat(user, "You don't see anything that can be cut with [W].")
|
||||
return
|
||||
|
||||
@@ -958,19 +958,6 @@ steam.start() -- spawns the effect
|
||||
return 0
|
||||
return !density
|
||||
|
||||
|
||||
/obj/structure/foamedmetal/proc/update_nearby_tiles()
|
||||
|
||||
if (!SS_READY(SSair))
|
||||
return 0
|
||||
|
||||
var/T = loc
|
||||
|
||||
if (isturf(T))
|
||||
SSair.mark_for_update(T)
|
||||
|
||||
return 1
|
||||
|
||||
/obj/structure/foamedmetal/New()
|
||||
. = ..()
|
||||
update_nearby_tiles()
|
||||
|
||||
@@ -1445,6 +1445,12 @@ var/global/list/image/blood_overlays = list()
|
||||
/obj/item/proc/is_wrench(var/mob/user)
|
||||
return FALSE
|
||||
|
||||
/obj/item/proc/is_wirecutter(var/mob/user)
|
||||
return FALSE
|
||||
|
||||
/obj/item/proc/is_multitool(var/mob/user)
|
||||
return FALSE
|
||||
|
||||
//This proc will be called when the person holding or equipping it talks.
|
||||
/obj/item/proc/affect_speech(var/datum/speech/speech, var/mob/living/L)
|
||||
return
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
density = 0
|
||||
sound_file = 'sound/items/zip.ogg'
|
||||
|
||||
/obj/structure/closet/body_bag/attackby(W as obj, mob/user as mob)
|
||||
/obj/structure/closet/body_bag/attackby(obj/item/W, mob/user as mob)
|
||||
if(istype(W,/obj/item/stack/sheet/metal))
|
||||
var/obj/item/stack/sheet/metal/S = W
|
||||
if(S.amount<5)
|
||||
@@ -51,7 +51,7 @@
|
||||
qdel(src)
|
||||
else if(istype(W, /obj/item/weapon/pen) || istype(W, /obj/item/device/flashlight/pen))
|
||||
set_tiny_label(user, maxlength=32)
|
||||
else if(iswirecutter(W))
|
||||
else if(W.is_wirecutter(user))
|
||||
remove_label()
|
||||
to_chat(user, "<span class='notice'>You cut the tag off the bodybag.</span>")
|
||||
|
||||
|
||||
@@ -111,7 +111,7 @@
|
||||
|
||||
/obj/item/candle/holo/attackby(obj/item/weapon/W, mob/user)
|
||||
var/list/choices = list("red","blue","purple","green","yellow")
|
||||
if(ismultitool(W))
|
||||
if(W.is_multitool(user))
|
||||
wax = input("What color would do you want?","Color Selection") as anything in choices
|
||||
update_icon()
|
||||
..()
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
if(C.lit)
|
||||
lit(user,W)
|
||||
else
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
fuse_lit = 0
|
||||
update_icon()
|
||||
to_chat(user, "<span class='warning'>You extinguish the fuse with [seconds_left] seconds left!</span>")
|
||||
|
||||
@@ -88,7 +88,7 @@
|
||||
W.playtoolsound(src, 50)
|
||||
return 1
|
||||
|
||||
if (ismultitool(W) && panel)
|
||||
if (W.is_multitool(user) && panel)
|
||||
hacked = !hacked
|
||||
to_chat(user, "<span class='notify'>You [hacked ? "disable" : "enable"] the lock on \the [src].</span>")
|
||||
return 1
|
||||
|
||||
@@ -188,7 +188,7 @@
|
||||
decondrop = 2 //determines how many parts to drop if deconstructed
|
||||
|
||||
/obj/item/device/instrument/drum/drum_makeshift/attackby(obj/item/I,mob/user,params)
|
||||
if(iswirecutter(I)) //wirecutters disassembles drums and bongos and gives you proper drops based on [decondrop] defined above
|
||||
if(I.is_wirecutter(user)) //wirecutters disassembles drums and bongos and gives you proper drops based on [decondrop] defined above
|
||||
I.playtoolsound(loc, 50)
|
||||
visible_message("<span class='notice'>[user] cuts the leather face off \the [src] with \the [I]. </span>")
|
||||
for (var/i = 1 to decondrop)
|
||||
|
||||
@@ -33,6 +33,9 @@
|
||||
return 0
|
||||
return istype(buffer,typepath)
|
||||
|
||||
/obj/item/device/multitool/is_multitool(mob/user)
|
||||
return TRUE
|
||||
|
||||
/obj/item/device/multitool/attack_self(var/mob/user)
|
||||
if(!buffer && !clone) // Can't enable cloning without buffer.
|
||||
return
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
/obj/item/device/radio/intercom/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
switch(buildstage)
|
||||
if(3)
|
||||
if(iswirecutter(W) && b_stat && wires.IsAllCut())
|
||||
if(W.is_wirecutter(user) && b_stat && wires.IsAllCut())
|
||||
to_chat(user, "<span class='notice'>You cut out the intercoms wiring and disconnect its electronics.</span>")
|
||||
W.playtoolsound(src, 50)
|
||||
if(do_after(user, src, 10))
|
||||
@@ -240,12 +240,12 @@
|
||||
src.frequency = copy.frequency
|
||||
src.broadcasting = copy.broadcasting
|
||||
src.listening = copy.listening
|
||||
|
||||
|
||||
/obj/item/device/radio/intercom/AIShiftClick(var/mob/living/silicon/ai/clicker)
|
||||
if(clicker.intercom_clipboard)
|
||||
src.frequency = clicker.intercom_clipboard.frequency
|
||||
src.broadcasting = clicker.intercom_clipboard.broadcasting
|
||||
src.listening = clicker.intercom_clipboard.listening
|
||||
src.listening = clicker.intercom_clipboard.listening
|
||||
|
||||
src.updateDialog()
|
||||
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
design = new type
|
||||
|
||||
/obj/structure/sign/poster/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
W.playtoolsound(loc, 100)
|
||||
if(ruined)
|
||||
to_chat(user, "<span class='notice'>You remove the remnants of the poster.</span>")
|
||||
|
||||
@@ -137,7 +137,7 @@ var/global/list/datum/stack_recipe/cable_recipes = list ( \
|
||||
// - Wirecutters : Cut a piece off
|
||||
// - Cable coil : Merge the cables
|
||||
/obj/item/stack/cable_coil/attackby(obj/item/weapon/W, mob/user)
|
||||
if((iswirecutter(W)) && (amount > 1))
|
||||
if(W.is_wirecutter(user) && (amount > 1))
|
||||
use(1)
|
||||
new /obj/item/stack/cable_coil(user.loc, 1, _color)
|
||||
to_chat(user, "<span class='notice'>You cut a piece off the cable coil.</span>")
|
||||
|
||||
@@ -230,7 +230,6 @@ var/global/list/shoal_stuff = list(
|
||||
name = "Alcatraz IV security crate"
|
||||
desc = "It came from Alcatraz IV!"
|
||||
|
||||
//6+6+6=18
|
||||
var/global/list/alcatraz_stuff = list(
|
||||
//3 of a kind
|
||||
/obj/item/weapon/depocket_wand,/obj/item/weapon/depocket_wand,/obj/item/weapon/depocket_wand,
|
||||
@@ -1264,6 +1263,222 @@ var/global/list/alcatraz_stuff = list(
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/obj/structure/closet/crate/internals/cloudnine
|
||||
name = "Cloud IX engineering crate"
|
||||
desc = "The Cloud IX engineering facility hangs in the atmosphere of the eponymous gas giant. But are the workers happy? Nein."
|
||||
|
||||
//3+8+4=15
|
||||
var/global/list/cloudnine_stuff = list(
|
||||
//3 of a kind
|
||||
/obj/item/airshield_projector,/obj/item/airshield_projector,/obj/item/airshield_projector,
|
||||
//2 of a kind
|
||||
/obj/item/vaporizer,/obj/item/vaporizer,
|
||||
/obj/item/device/multitool/omnitool,/obj/item/device/multitool/omnitool,
|
||||
/obj/item/supermatter_shielding/frass,/obj/item/supermatter_shielding/frass,
|
||||
/mob/living/simple_animal/hamster,/mob/living/simple_animal/hamster,
|
||||
//1 of a kind
|
||||
/obj/item/clothing/gloves/golden,
|
||||
/obj/machinery/power/antiquesynth,
|
||||
/obj/item/weapon/am_containment/decelerator,
|
||||
/obj/structure/largecrate/secure/magmaw,
|
||||
)
|
||||
|
||||
/obj/structure/closet/crate/internals/cloudnine/New()
|
||||
..()
|
||||
for(var/i = 1 to 5)
|
||||
if(!cloudnine_stuff.len)
|
||||
return
|
||||
var/path = pick_n_take(cloudnine_stuff)
|
||||
new path(src)
|
||||
|
||||
/obj/item/supermatter_shielding/frass
|
||||
name = "\improper F.R.A.S.S. sphere"
|
||||
desc = "Frequency-reticulated anti-supermatter safeguard. A refinement of the S.A.S.S. design that is reusable but dazes its user more. It should prevent you from getting annihilated by supermatter. It looks like a brown marble floating in a vibrating gas inside a glass orb."
|
||||
stunforce = 30
|
||||
infinite = TRUE
|
||||
|
||||
#define HAMSTER_MOVEDELAY 1
|
||||
/mob/living/simple_animal/hamster
|
||||
name = "colossal hamster"
|
||||
desc = "Cricetus robustus. Roughly the size of a capybara, this species of hamster was bred to power treadmill engines."
|
||||
icon_state = "hammy"
|
||||
icon_living = "hammy"
|
||||
icon_dead = "hammy-dead"
|
||||
response_help = "pets"
|
||||
treadmill_speed = 8
|
||||
health = 100
|
||||
maxHealth = 100
|
||||
min_oxy = 0
|
||||
speak_chance = 2
|
||||
emote_hear = list("squeaks deeply")
|
||||
var/obj/my_wheel
|
||||
|
||||
/mob/living/simple_animal/hamster/Life()
|
||||
if(!..())
|
||||
return 0
|
||||
if(!my_wheel && isturf(loc))
|
||||
var/obj/machinery/power/treadmill/T = locate(/obj/machinery/power/treadmill) in loc
|
||||
if(T)
|
||||
wander = FALSE
|
||||
my_wheel = T
|
||||
else
|
||||
wander = TRUE
|
||||
if(my_wheel)
|
||||
hamsterwheel(20)
|
||||
|
||||
/mob/living/simple_animal/hamster/proc/hamsterwheel(var/repeat)
|
||||
if(repeat < 1 || stat)
|
||||
return
|
||||
if(!my_wheel || my_wheel.loc != loc) //no longer share a tile with our wheel
|
||||
wander = TRUE
|
||||
my_wheel = null
|
||||
return
|
||||
step(src,my_wheel.dir)
|
||||
delayNextMove(HAMSTER_MOVEDELAY)
|
||||
sleep(HAMSTER_MOVEDELAY)
|
||||
hamsterwheel(repeat-1)
|
||||
|
||||
/mob/living/simple_animal/hamster/attack_hand(mob/living/carbon/human/M)
|
||||
. = ..()
|
||||
if(M && !isUnconscious() && M.a_intent == I_HELP)
|
||||
M.delayNextAttack(2 SECONDS)
|
||||
var/image/heart = image('icons/mob/animal.dmi',src,"heart-ani2")
|
||||
heart.plane = ABOVE_HUMAN_PLANE
|
||||
flick_overlay(heart, list(M.client), 20)
|
||||
if(!my_wheel)
|
||||
flick("hammy-rest", src)
|
||||
emote("me", EMOTE_AUDIBLE, pick("flattens amicably.","fluffs up.","puffs out her cheeks.","shuts her eyes contentedly."))
|
||||
|
||||
#undef HAMSTER_MOVEDELAY
|
||||
|
||||
/obj/item/clothing/gloves/golden
|
||||
name = "golden gloves"
|
||||
desc = "An impressive fashion statement. Gold is an excellent conductor, meaning these won't help much against shocks. The insides are lined with strange high-tech sacs filled with an unidentified fluid which lubricates the outside. It comes with a cryptic note reading: touch the supermatter."
|
||||
icon_state = "golden"
|
||||
item_state = "yellow"
|
||||
siemens_coefficient = 2
|
||||
permeability_coefficient = 0.05
|
||||
max_heat_protection_temperature = GLOVES_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
_color = "golden"
|
||||
|
||||
/obj/item/airshield_projector
|
||||
name = "airshield projector"
|
||||
desc = "Exploits Maxwellian Daemons to hold each individual gas particle in place in a defined area. They won't open or close doors for you, though."
|
||||
icon = 'icons/obj/device.dmi'
|
||||
icon_state = "airprojector"
|
||||
var/list/projected = list()
|
||||
var/max_proj = 6
|
||||
|
||||
/obj/item/airshield_projector/preattack(atom/target, mob/user , proximity)
|
||||
var/turf/to_shield = get_turf(target)
|
||||
if(projected.len < max_proj && istype(to_shield) && (!locate(/obj/effect/airshield) in to_shield))
|
||||
playsound(loc, 'sound/machines/hiss.ogg', 75, 1)
|
||||
var/obj/effect/airshield/A = new(to_shield)
|
||||
A.owner = src
|
||||
projected += A
|
||||
visible_message("<span class='notice'>\The [user] deploys \the [A].</span>")
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
//not to be confused with the structure in airshield.dm
|
||||
/obj/effect/airshield
|
||||
name = "airshield"
|
||||
desc = "A shield that allows only non-gasses to pass through."
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
icon_state = "planner"
|
||||
opacity = FALSE
|
||||
mouse_opacity = FALSE
|
||||
density = FALSE
|
||||
anchored = TRUE
|
||||
plane = ABOVE_HUMAN_PLANE
|
||||
maptext_x = 11
|
||||
maptext_y = 8
|
||||
var/obj/item/airshield_projector/owner
|
||||
var/life = 9
|
||||
|
||||
/obj/effect/airshield/New()
|
||||
..()
|
||||
countdown()
|
||||
|
||||
/obj/effect/airshield/proc/countdown()
|
||||
maptext = "<span style=\"color:#FF8C00;font-size:12px;\">[life]</span>"
|
||||
spawn(1 SECONDS)
|
||||
life--
|
||||
if(life>0)
|
||||
countdown()
|
||||
else
|
||||
if(owner)
|
||||
owner.projected -= src
|
||||
update_nearby_tiles(loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/airshield/Cross(atom/movable/mover, turf/target, height=1.5, air_group = 0)
|
||||
if(istype(mover))
|
||||
return ..()
|
||||
return FALSE
|
||||
|
||||
var/list/decelerators = list()
|
||||
/obj/item/weapon/am_containment/decelerator
|
||||
name = "antimatter decelerator"
|
||||
desc = "Acts as a 'filter' to trap antiparticles emitted by radiation. In function, it can be used to power an antimatter engine and refuel itself with nearby radiation."
|
||||
|
||||
/obj/item/weapon/am_containment/decelerator/New()
|
||||
..()
|
||||
decelerators += src
|
||||
|
||||
/obj/item/weapon/am_containment/decelerator/Destroy()
|
||||
decelerators -= src
|
||||
..()
|
||||
|
||||
/obj/item/weapon/am_containment/decelerator/proc/receive_pulse(power)
|
||||
fuel = min(fuel_max, fuel + round(power/100))
|
||||
|
||||
#define OMNIMODE_WIRE 0
|
||||
#define OMNIMODE_TOOL 1
|
||||
/obj/item/device/multitool/omnitool
|
||||
name = "omnitool"
|
||||
desc = "Combining the power of wirecutters and a multitool. For power cables, works as a multitool when you stand on top and use it. It also allows the user to remotely access APCs and air alarms."
|
||||
icon_state = "omnitool"
|
||||
origin_tech = Tc_ENGINEERING + "=4"
|
||||
sharpness = 1
|
||||
force = 6
|
||||
var/mode = OMNIMODE_TOOL
|
||||
|
||||
/obj/item/device/multitool/omnitool/attack_self(mob/user)
|
||||
mode = !mode
|
||||
to_chat(user, "<span class='notice'>You toggle the tool into [mode ? "multitool" : "wirecutter"] mode.</span>")
|
||||
|
||||
/obj/item/device/multitool/omnitool/is_wirecutter()
|
||||
return !mode
|
||||
|
||||
/obj/item/device/multitool/omnitool/is_multitool()
|
||||
return mode
|
||||
|
||||
var/list/omnitoolable = list(/obj/machinery/alarm,/obj/machinery/power/apc)
|
||||
|
||||
/obj/item/device/multitool/omnitool/preattack(atom/target, mob/user, proximity)
|
||||
if(proximity)
|
||||
return FALSE //immediately continue if in reach
|
||||
if(can_connect(target, user) && is_type_in_list(target.type,omnitoolable))
|
||||
target.attack_hand(user)
|
||||
return TRUE
|
||||
|
||||
/obj/item/device/multitool/omnitool/proc/can_connect(atom/target, mob/user)
|
||||
var/client/C
|
||||
if(user)
|
||||
C = user.client
|
||||
else
|
||||
var/mob/M = loc
|
||||
if(!istype(M))
|
||||
return FALSE
|
||||
C = M.client
|
||||
if(!C)
|
||||
return FALSE
|
||||
return get_dist(target,src) <= C.view
|
||||
|
||||
#undef OMNIMODE_WIRE
|
||||
#undef OMNIMODE_TOOL
|
||||
|
||||
//Mystery mob cubes//////////////
|
||||
|
||||
/obj/item/weapon/storage/box/mysterycubes
|
||||
|
||||
@@ -313,7 +313,7 @@
|
||||
to_chat(user, "<span class='notice'>You can't move.</span>")
|
||||
|
||||
/obj/structure/strange_present/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if (iswirecutter(W))
|
||||
if (W.is_wirecutter(user))
|
||||
to_chat(user, "<span class='notice'>You cut open the present.</span>")
|
||||
|
||||
for(var/mob/M in src) //Should only be one but whatever.
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
qdel(I)
|
||||
I = null
|
||||
qdel(src)
|
||||
if(iswirecutter(I))
|
||||
if(I.is_wirecutter(user))
|
||||
to_chat(user, "You cut out the top and bottom of \the [src] with \the [I].")
|
||||
I.playtoolsound(user, 50)
|
||||
if(src.loc == user)
|
||||
|
||||
@@ -49,7 +49,8 @@
|
||||
"/obj/item/device/lightreplacer",
|
||||
"/obj/item/device/device_analyser",
|
||||
"/obj/item/device/silicate_sprayer",
|
||||
"/obj/item/device/geiger_counter"
|
||||
"/obj/item/device/geiger_counter",
|
||||
"/obj/item/airshield_projector"
|
||||
)
|
||||
|
||||
/obj/item/weapon/storage/belt/utility/complete/New()
|
||||
@@ -116,7 +117,8 @@
|
||||
"/obj/item/weapon/rcl",
|
||||
"/obj/item/device/silicate_sprayer",
|
||||
"/obj/item/device/geiger_counter",
|
||||
"/obj/item/weapon/inflatable_dispenser"
|
||||
"/obj/item/weapon/inflatable_dispenser",
|
||||
"/obj/item/airshield_projector"
|
||||
)
|
||||
|
||||
/obj/item/weapon/storage/belt/utility/chief/full/New() //This is mostly for testing I guess
|
||||
|
||||
@@ -204,6 +204,9 @@
|
||||
attack_verb = list("pinches", "nips at")
|
||||
toolsounds = list('sound/items/Wirecutter.ogg')
|
||||
|
||||
/obj/item/tool/wirecutters/is_wirecutter(mob/user)
|
||||
return TRUE
|
||||
|
||||
/obj/item/tool/wirecutters/New()
|
||||
. = ..()
|
||||
|
||||
|
||||
@@ -184,7 +184,7 @@ obj/item/weapon/wirerod/attackby(var/obj/item/I, mob/user as mob)
|
||||
I = null
|
||||
qdel(src)
|
||||
|
||||
else if(iswirecutter(I))
|
||||
else if(I.is_wirecutter(user))
|
||||
var/obj/item/weapon/melee/baton/cattleprod/P = new /obj/item/weapon/melee/baton/cattleprod
|
||||
|
||||
user.before_take_item(I)
|
||||
|
||||
@@ -606,7 +606,7 @@
|
||||
if(user.drop_item(W, src.loc))
|
||||
to_chat(user, "<span class='notice'>You attach [W] to [src].</span>")
|
||||
return
|
||||
else if(iswirecutter(W))
|
||||
else if(W.is_wirecutter(user))
|
||||
if(rigged)
|
||||
to_chat(user, "<span class='notice'>You cut away the wiring.</span>")
|
||||
W.playtoolsound(loc, 100)
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
layer = OPEN_CURTAIN_LAYER
|
||||
|
||||
/obj/structure/curtain/attackby(obj/item/W, mob/user)
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
W.playtoolsound(loc, 50)
|
||||
if(do_after(user, src, 10))
|
||||
to_chat(user, "<span class='notice'>You cut \the [src] down.</span>")
|
||||
|
||||
@@ -247,7 +247,7 @@
|
||||
to_chat(user, "<span class='notice'>You wire the Airlock!</span>")
|
||||
busy = 0
|
||||
|
||||
else if(iswirecutter(W) && state == 1 )
|
||||
else if(W.is_wirecutter(user) && state == 1 )
|
||||
busy = 1
|
||||
W.playtoolsound(src, 100)
|
||||
user.visible_message("[user] cuts the wires from the airlock assembly.", "You start to cut the wires from airlock assembly.")
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
hole_size = LARGE_HOLE
|
||||
|
||||
/obj/structure/fence/attackby(obj/item/W, mob/user)
|
||||
if(iswirecutter(W) && !shock(user, 100, W.siemens_coefficient))
|
||||
if(W.is_wirecutter(user) && !shock(user, 100, W.siemens_coefficient))
|
||||
if(!cuttable)
|
||||
to_chat(user, "<span class='notice'>This section of the fence can't be cut.</span>")
|
||||
return
|
||||
|
||||
@@ -113,7 +113,7 @@
|
||||
state = 2
|
||||
update_icon()
|
||||
|
||||
else if(iswirecutter(W) && state == 1) //Removing support struts, stage 1 to 0 (normal girder)
|
||||
else if(W.is_wirecutter(user) && state == 1) //Removing support struts, stage 1 to 0 (normal girder)
|
||||
W.playtoolsound(src, 100)
|
||||
user.visible_message("<span class='warning'>[user] starts removing \the [src]'s internal support struts.</span>", \
|
||||
"<span class='notice'>You start removing \the [src]'s internal support struts.</span>")
|
||||
|
||||
@@ -171,7 +171,7 @@
|
||||
S.dir = get_dir(src, user)
|
||||
return
|
||||
return
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
if(!shock(user, 100, W.siemens_coefficient)) //Prevent user from doing it if he gets shocked
|
||||
W.playtoolsound(loc, 100)
|
||||
drop_stack(grille_material, get_turf(src), broken ? 1 : 2, user) //Drop the rods, taking account on whenever the grille is broken or not !
|
||||
|
||||
@@ -243,16 +243,6 @@
|
||||
verbs -= /obj/structure/inflatable/verb/hand_deflate
|
||||
deflate()
|
||||
|
||||
/obj/structure/inflatable/proc/update_nearby_tiles(var/turf/T)
|
||||
if(!SS_READY(SSair))
|
||||
return 0
|
||||
|
||||
if(!T)
|
||||
T = get_turf(src)
|
||||
if(isturf(T))
|
||||
SSair.mark_for_update(T)
|
||||
return 1
|
||||
|
||||
/obj/structure/inflatable/Cross(atom/movable/mover, turf/target, height=1.5, air_group = 0)
|
||||
if(air_group)
|
||||
return 0
|
||||
|
||||
@@ -103,7 +103,7 @@ obj/structure/windoor_assembly/Destroy()
|
||||
return
|
||||
created_name = t
|
||||
return
|
||||
|
||||
|
||||
if(iswelder(W) && (!anchored && !wired && !electronics))
|
||||
var/obj/item/tool/weldingtool/WT = W
|
||||
user.visible_message("[user] dissassembles [src].", "You start to dissassemble [src].")
|
||||
@@ -165,7 +165,7 @@ obj/structure/windoor_assembly/Destroy()
|
||||
update_name()
|
||||
|
||||
//Removing wire from the assembly. Step 5 undone.
|
||||
if(iswirecutter(W) && (anchored && wired))
|
||||
if(W.is_wirecutter(user) && (anchored && wired))
|
||||
W.playtoolsound(src, 100)
|
||||
user.visible_message("[user] is cutting the wires from [src].", "You start to cut the wires from [src].")
|
||||
|
||||
@@ -264,15 +264,6 @@ obj/structure/windoor_assembly/Destroy()
|
||||
to_chat(usr, "The windoor will now slide to the [facing == "l" ? "left":"right"].")
|
||||
update_icon()
|
||||
|
||||
|
||||
/obj/structure/windoor_assembly/proc/update_nearby_tiles()
|
||||
if(!SS_READY(SSair))
|
||||
return FALSE
|
||||
var/T = loc
|
||||
if (isturf(T))
|
||||
SSair.mark_for_update(T)
|
||||
return TRUE
|
||||
|
||||
/obj/structure/windoor_assembly/clockworkify()
|
||||
GENERIC_CLOCKWORK_CONVERSION(src, /obj/structure/windoor_assembly/clockwork, BRASS_WINDOOR_GLOW)
|
||||
|
||||
|
||||
@@ -377,7 +377,7 @@ var/list/one_way_windows
|
||||
return 1
|
||||
|
||||
|
||||
if(ismultitool(W) && smartwindow)
|
||||
if(W.is_multitool(user) && smartwindow)
|
||||
smartwindow.update_multitool_menu(user)
|
||||
return
|
||||
|
||||
@@ -578,21 +578,6 @@ var/list/one_way_windows
|
||||
..()
|
||||
update_nearby_tiles()
|
||||
|
||||
//This proc has to do with airgroups and atmos, it has nothing to do with smoothwindows, that's update_nearby_icons().
|
||||
/obj/structure/window/proc/update_nearby_tiles(var/turf/T)
|
||||
|
||||
|
||||
if(!SS_READY(SSair))
|
||||
return 0
|
||||
|
||||
if(!T)
|
||||
T = get_turf(src)
|
||||
|
||||
if(isturf(T))
|
||||
SSair.mark_for_update(T)
|
||||
|
||||
return 1
|
||||
|
||||
//This proc is used to update the icons of nearby windows. It should not be confused with update_nearby_tiles(), which is an atmos proc!
|
||||
/obj/structure/window/proc/update_nearby_icons(var/turf/T)
|
||||
|
||||
|
||||
@@ -111,7 +111,7 @@
|
||||
//Deconstruction and reconstruction
|
||||
switch(d_state)
|
||||
if(WALLCOMPLETED)
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
W.playtoolsound(src, 100)
|
||||
src.d_state = WALLCOVEREXPOSED
|
||||
update_icon()
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
|
||||
|
||||
/obj/item/device/assembly/voice/attackby(obj/item/W, mob/user)
|
||||
if(ismultitool(W))
|
||||
if(W.is_multitool(user))
|
||||
muted = !muted
|
||||
|
||||
if(muted)
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
else
|
||||
to_chat(user, "<span class='notice'>[src] already have a cell.</span>")
|
||||
|
||||
else if(iswirecutter(W))
|
||||
else if(W.is_wirecutter(user))
|
||||
if(cell)
|
||||
cell.updateicon()
|
||||
cell.forceMove(get_turf(src.loc))
|
||||
|
||||
@@ -222,7 +222,7 @@ var/list/fish_items_list = list("goldfish" = /obj/item/weapon/fish/goldfish,
|
||||
icon = 'icons/obj/fish_items.dmi'
|
||||
|
||||
/obj/item/weapon/lobster/attackby(var/obj/item/O, var/mob/user) // extracting tail and claw meat from a sea cockroach
|
||||
if(iswirecutter(O))
|
||||
if(O.is_wirecutter(user))
|
||||
to_chat(user, "<span class='notice'>You crack open the shell of \the [src] and pull out the claw meat while separating the tail!")
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/raw_lobster_meat(get_turf(src))
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/raw_lobster_meat(get_turf(src))
|
||||
@@ -232,7 +232,7 @@ var/list/fish_items_list = list("goldfish" = /obj/item/weapon/fish/goldfish,
|
||||
..()
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/snacks/raw_lobster_tail/attackby(var/obj/item/O, var/mob/user) // extracting the meat from the tail, just makes normal lobster meat
|
||||
if(iswirecutter(O))
|
||||
if(O.is_wirecutter(user))
|
||||
to_chat(user, "<span class='notice'>You crack open the remains of the shell from \the [src] and pull out the meat!")
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/raw_lobster_meat(get_turf(src))
|
||||
qdel(src)
|
||||
|
||||
@@ -161,7 +161,7 @@
|
||||
update_icon()
|
||||
update_on(TRUE)
|
||||
return 1
|
||||
else if(iswirecutter(W))
|
||||
else if(W.is_wirecutter(user))
|
||||
W.playtoolsound(src, 50)
|
||||
if(do_after(user, src, 10) && buildstage==SYSTEMISKINDADONE)
|
||||
new /obj/item/stack/cable_coil(get_turf(src), 5)
|
||||
|
||||
@@ -112,6 +112,7 @@
|
||||
var/damage = shock_damage * siemens_coeff
|
||||
|
||||
if(damage <= 0)
|
||||
adjustFireLoss(damage) //Heal burns equal to the negative value
|
||||
return 0
|
||||
|
||||
var/mob/living/carbon/human/H = src
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
|
||||
//LOOK AT THIS - ..()??
|
||||
/mob/living/simple_animal/crab/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
if(iswirecutter(O))
|
||||
if(O.is_wirecutter(user))
|
||||
if(stat == DEAD)
|
||||
return ..()
|
||||
if(prob(50))
|
||||
|
||||
@@ -264,7 +264,7 @@ proc/cardinalrange(var/center)
|
||||
w_type = RECYK_METAL
|
||||
|
||||
/obj/item/device/am_shielding_container/attackby(var/obj/item/I, var/mob/user)
|
||||
if(ismultitool(I) && isturf(loc))
|
||||
if(I.is_multitool(user) && isturf(loc))
|
||||
if(locate(/obj/machinery/am_shielding/) in loc)
|
||||
to_chat(user, "<span class='warning'>[bicon(src)]There is already an antimatter reactor section there.</span>")
|
||||
return
|
||||
|
||||
@@ -527,7 +527,7 @@
|
||||
C.use(10)
|
||||
terminal.connect_to_network()
|
||||
|
||||
else if (iswirecutter(W) && opened && terminal && has_electronics!=2)
|
||||
else if (W.is_wirecutter(user) && opened && terminal && has_electronics!=2)
|
||||
var/turf/T = get_turf(src)
|
||||
if (T.intact)
|
||||
to_chat(user, "<span class='warning'>You must remove the floor plating in front of the APC first.</span>")
|
||||
@@ -872,6 +872,14 @@
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/machinery/power/apc/is_in_range(var/mob/user)
|
||||
if((!in_range(src, usr) || !istype(src.loc, /turf)) && !istype(usr, /mob/living/silicon))
|
||||
var/obj/item/device/multitool/omnitool/O = user.get_active_hand()
|
||||
if(istype(O))
|
||||
return O.can_connect(src,user)
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/power/apc/Topic(href, href_list)
|
||||
if(..())
|
||||
return 0
|
||||
|
||||
@@ -195,7 +195,10 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
if(T.intact)
|
||||
return
|
||||
|
||||
if(W.sharpness >= 1)
|
||||
if(istype(W,/obj/item/device/multitool/omnitool) && (loc == user.loc))
|
||||
//unlike a normal multitool, only do this if we're directly on top, otherwise cut as per sharpness
|
||||
report_load(user)
|
||||
else if(W.sharpness >= 1 && !W.is_multitool(user))
|
||||
if(shock(user, 50, W.siemens_coefficient))
|
||||
return
|
||||
cut(user, T)
|
||||
@@ -208,12 +211,8 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
if(R.loaded)
|
||||
R.loaded.cable_join(src, user)
|
||||
R.is_empty()
|
||||
else if(istype(W, /obj/item/device/multitool))
|
||||
if((powernet) && (powernet.avail > 0)) // is it powered?
|
||||
to_chat(user, "<SPAN CLASS='warning'>Power network status report - Load: [format_watts(powernet.load)] - Available: [format_watts(powernet.avail)].</SPAN>")
|
||||
else
|
||||
to_chat(user, "<SPAN CLASS='notice'>The cable is not powered.</SPAN>")
|
||||
|
||||
else if(W.is_multitool(user))
|
||||
report_load(user)
|
||||
shock(user, 5, 0.2)
|
||||
else
|
||||
if(src.d1 && W.is_conductor()) // d1 determines if this is a cable end
|
||||
@@ -221,6 +220,12 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
|
||||
src.add_fingerprint(user)
|
||||
|
||||
/obj/structure/cable/proc/report_load(mob/user)
|
||||
if((powernet) && (powernet.avail > 0)) // is it powered?
|
||||
to_chat(user, "<SPAN CLASS='warning'>Power network status report - Load: [format_watts(powernet.load)] - Available: [format_watts(powernet.avail)].</SPAN>")
|
||||
else
|
||||
to_chat(user, "<SPAN CLASS='notice'>The cable is not powered.</SPAN>")
|
||||
|
||||
/obj/structure/cable/attack_animal(mob/M)
|
||||
if(isanimal(M))
|
||||
if(ismouse(M))
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
if(T.intact)
|
||||
return
|
||||
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
to_chat(user, "<span class='notice'>These cables are too tough to be cut with those [W.name].</span>")
|
||||
return
|
||||
else if(W.type == /obj/item/stack/cable_coil)
|
||||
|
||||
@@ -371,7 +371,7 @@ var/global/list/obj/machinery/light/alllights = list()
|
||||
to_chat(user, "You hit the light!")
|
||||
// attempt to deconstruct / stick weapon into light socket
|
||||
else if(!current_bulb)
|
||||
if(iswirecutter(W)) //If it's a wirecutter take out the wires
|
||||
if(W.is_wirecutter(user)) //If it's a wirecutter take out the wires
|
||||
W.playtoolsound(src, 75)
|
||||
user.visible_message("[user.name] removes \the [src]'s wires.", \
|
||||
"You remove \the [src]'s wires.", "You hear a noise.")
|
||||
|
||||
@@ -83,7 +83,7 @@
|
||||
has_electronics &= 2
|
||||
return
|
||||
|
||||
else if (iswirecutter(W) && opened && (has_electronics & 2))
|
||||
else if (W.is_wirecutter(user) && opened && (has_electronics & 2))
|
||||
to_chat(user, "You begin to cut the cables...")
|
||||
playsound(src, 'sound/items/Deconstruct.ogg', 50, 1)
|
||||
if(do_after(user, src, 50))
|
||||
|
||||
@@ -110,7 +110,7 @@
|
||||
has_electronics &= 2
|
||||
return
|
||||
|
||||
else if (iswirecutter(W) && opened && (has_electronics & 2))
|
||||
else if (W.is_wirecutter(user) && opened && (has_electronics & 2))
|
||||
to_chat(user, "You begin to cut the cables...")
|
||||
playsound(src, 'sound/items/Deconstruct.ogg', 50, 1)
|
||||
if(do_after(user, src, 50))
|
||||
|
||||
@@ -127,6 +127,9 @@ var/global/list/rad_collectors = list()
|
||||
for(var/obj/machinery/power/rad_collector/R in rad_collectors)
|
||||
if(get_dist(R, center) <= range) //Better than using orange() every process.
|
||||
R.receive_pulse(power)
|
||||
for(var/obj/item/weapon/am_containment/decelerator/D in decelerators)
|
||||
if(get_dist(D, center) <= range)
|
||||
D.receive_pulse(power)
|
||||
|
||||
//Pulse_strength is multiplied by around 70 (less or more depending on the air tank setup) to get the amount of watts generated
|
||||
/obj/machinery/power/rad_collector/proc/receive_pulse(const/pulse_strength)
|
||||
|
||||
@@ -224,7 +224,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
"You add some wires.")
|
||||
temp_state++
|
||||
if(2)
|
||||
if(iswirecutter(O))//TODO:Shock user if its on?
|
||||
if(O.is_wirecutter(user))//TODO:Shock user if its on?
|
||||
user.visible_message("[user.name] removes some wires from the [src.name].", \
|
||||
"You remove some wires.")
|
||||
temp_state--
|
||||
@@ -366,7 +366,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
"You add some wires.")
|
||||
temp_state++
|
||||
if(2)
|
||||
if(iswirecutter(O))//TODO:Shock user if its on?
|
||||
if(O.is_wirecutter(user))//TODO:Shock user if its on?
|
||||
user.visible_message("[user.name] removes some wires from the [src.name].", \
|
||||
"You remove some wires.")
|
||||
temp_state--
|
||||
|
||||
@@ -84,7 +84,7 @@ var/list/smes_list = list()
|
||||
"You made a terminal for the SMES.")
|
||||
src.stat = 0
|
||||
return 1
|
||||
else if(iswirecutter(W) && terminal)
|
||||
else if(W.is_wirecutter(user) && terminal)
|
||||
var/turf/T = get_turf(terminal)
|
||||
if(T.intact)
|
||||
to_chat(user, "<span class='warning'>You must remove the floor plating in front of the SMES first.</span>")
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
..()
|
||||
|
||||
/obj/machinery/power/terminal/attackby(obj/item/W, mob/user)
|
||||
if(iswirecutter(W) && !master) //Sanity in the rare case something destroys a machine and leaves a terminal
|
||||
if(W.is_wirecutter(user) && !master) //Sanity in the rare case something destroys a machine and leaves a terminal
|
||||
new /obj/item/stack/cable_coil(get_turf(src), 10)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
@@ -188,7 +188,7 @@
|
||||
to_chat(user, "You tighten the lens assembly inside \the [src].")
|
||||
W.playtoolsound(src, 50)
|
||||
lens_secure = !lens_secure
|
||||
else if(iswirecutter(W))
|
||||
else if(W.is_wirecutter(user))
|
||||
if(flawless)
|
||||
to_chat(user, "\The [src] is too flawless to dismantle!")
|
||||
return
|
||||
|
||||
@@ -190,7 +190,7 @@
|
||||
to_chat(user, "<span class='notice'>There's no room in \the [src]'s film chamber with the [cell ? "power cell" : "wire"] inside it.</span>")
|
||||
return
|
||||
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
if(cell)
|
||||
to_chat(user, "<span class='warning'>You can't reach the wires with the power cell in the way.</span>")
|
||||
return
|
||||
|
||||
@@ -548,7 +548,7 @@
|
||||
W.playtoolsound(src, 50)
|
||||
state = "stock_capacitorbank"
|
||||
update_assembly()
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
to_chat(user, "You cut the wires out of the capacitor bank.")
|
||||
W.playtoolsound(user, 50)
|
||||
state = "stock_reservoir"
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
to_chat(user, "<span class='notice'>You remove the containers from the electrolyzer.</span>")
|
||||
|
||||
/obj/item/weapon/electrolyzer/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(iswirecutter(W))
|
||||
if(W.is_wirecutter(user))
|
||||
if(beakers.len)
|
||||
to_chat(user, "<span class='warning'>The electrolyzer contains beakers!</span>")
|
||||
return
|
||||
|
||||
@@ -265,7 +265,7 @@ obj/item/weapon/reagent_containers/chempack/verb/set_fill()
|
||||
user.update_inv_hands()
|
||||
return
|
||||
if(2)
|
||||
if (iswirecutter(W))
|
||||
if (W.is_wirecutter(user))
|
||||
stage = 3
|
||||
primed = 1
|
||||
to_chat(user, "<span class='notice'>You reroute the connections within \the [src].</span>")
|
||||
@@ -277,7 +277,7 @@ obj/item/weapon/reagent_containers/chempack/verb/set_fill()
|
||||
user.update_inv_hands()
|
||||
return
|
||||
if(3)
|
||||
if (ismultitool(W))
|
||||
if (W.is_multitool(user))
|
||||
if (safety == 0)
|
||||
to_chat(user, "<span class='warning'>You activate the manual safety override of \the [src]!</span>")
|
||||
to_chat(user, "<span class='warning'>The bolts for the auxiliary chamber of \the [src] have been exposed!</span>")
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
update_icon()
|
||||
return 1
|
||||
|
||||
if(ismultitool(W) && panel)
|
||||
if(W.is_multitool(user) && panel)
|
||||
mode = !mode
|
||||
to_chat(user, "<span class='notify'>You [mode ? "disable" : "enable"] the lock on \the [src].</span>")
|
||||
return 1
|
||||
|
||||
@@ -169,8 +169,8 @@
|
||||
if(L.code == code)
|
||||
L.toggle_lock()
|
||||
|
||||
/obj/item/device/pod_key/attackby(var/obj/O, mob/user)
|
||||
if(ismultitool(O))
|
||||
/obj/item/device/pod_key/attackby(var/obj/item/O, mob/user)
|
||||
if(O.is_multitool(user))
|
||||
code = input(user,"Enter a number:","Key Code",code) as num
|
||||
return
|
||||
.=..()
|
||||
|
||||
@@ -375,6 +375,15 @@
|
||||
|
||||
|
||||
/obj/machinery/power/supermatter/attack_hand(mob/user as mob)
|
||||
var/obj/item/clothing/gloves/golden/G = user.get_item_by_slot(slot_gloves)
|
||||
if(istype(G))
|
||||
to_chat(user,"<span class='warning'>Carefully extending a single finger, you nearly touch the supermatter before the gloves stop you -- repulsed by and absorbing some kind of charge.</span>")
|
||||
if(G.siemens_coefficient > -1)
|
||||
G.siemens_coefficient = -1
|
||||
G.icon_state = "golden-awakened"
|
||||
G.desc = "Gloves imbued with the power of the supermatter. They absorb electrical shocks to heal the wearer."
|
||||
to_chat(user, "<span class='good'>Some of the power of the supermatter remains trapped in the gloves, changing their properties!</span>")
|
||||
return
|
||||
user.visible_message("<span class=\"warning\">\The [user] reaches out and touches \the [src], inducing a resonance... \his body starts to glow and bursts into flames before flashing into ash.</span>",\
|
||||
"<span class=\"danger\">You reach out and touch \the [src]. Everything starts burning and all you can hear is ringing. Your last thought is \"That was not a wise decision.\"</span>",\
|
||||
"<span class=\"warning\">You hear an unearthly noise as a wave of heat washes over you.</span>")
|
||||
|
||||
|
Before Width: | Height: | Size: 563 KiB After Width: | Height: | Size: 565 KiB |
|
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 13 KiB |
|
Before Width: | Height: | Size: 19 KiB After Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 42 KiB After Width: | Height: | Size: 43 KiB |