Merge branch 'master' into upstream-merge-31045

This commit is contained in:
LetterJay
2017-10-01 01:17:52 -04:00
committed by GitHub
260 changed files with 7134 additions and 5672 deletions

View File

@@ -157,11 +157,27 @@
/obj/effect/landmark/start/wizard
name = "wizard"
/obj/effect/landmark/start/wizard/Initialize(mapload)
/obj/effect/landmark/start/wizard/Initialize()
..()
GLOB.wizardstart += loc
return INITIALIZE_HINT_QDEL
/obj/effect/landmark/start/nukeop
name = "nukeop"
/obj/effect/landmark/start/nukeop/Initialize()
..()
GLOB.nukeop_start += loc
return INITIALIZE_HINT_QDEL
/obj/effect/landmark/start/nukeop_leader
name = "nukeop leader"
/obj/effect/landmark/start/nukeop_leader/Initialize()
..()
GLOB.nukeop_leader_start += loc
return INITIALIZE_HINT_QDEL
/obj/effect/landmark/start/new_player
name = "New Player"
@@ -205,23 +221,6 @@
/obj/effect/landmark/tripai
name = "tripai"
// marauder entry (XXX WTF IS MAURADER ENTRY???)
/obj/effect/landmark/marauder_entry
name = "Marauder Entry"
// syndicate breach area (XXX I DON'T KNOW WHAT THIS IS EITHER)
/obj/effect/landmark/syndicate_breach_area
name = "Syndicate Breach Area"
// teleport scroll landmark, XXX DOES THIS DO ANYTHING?
/obj/effect/landmark/teleport_scroll
name = "Teleport-Scroll"
/obj/effect/landmark/syndicate_spawn
name = "Syndicate-Spawn"
// xenos.
/obj/effect/landmark/xeno_spawn
name = "xeno_spawn"
@@ -304,6 +303,25 @@
GLOB.tdomeadmin += loc
return INITIALIZE_HINT_QDEL
//Servant spawn locations
/obj/effect/landmark/servant_of_ratvar
name = "servant of ratvar spawn"
/obj/effect/landmark/servant_of_ratvar/Initialize(mapload)
..()
GLOB.servant_spawns += loc
qdel(src)
//City of Cogs entrances
/obj/effect/landmark/city_of_cogs
name = "city of cogs entrance"
icon_state = "x4"
/obj/effect/landmark/city_of_cogs/Initialize(mapload)
..()
GLOB.city_of_cogs_spawns += loc
qdel(src)
//generic event spawns
/obj/effect/landmark/event_spawn
name = "generic event spawn"

View File

@@ -33,7 +33,7 @@
if(!force_rebuild && range == current_range)
return FALSE
. = TRUE
current_range = range
var/list/checkers_local = checkers

View File

@@ -52,6 +52,7 @@
icon_state = "eggs"
var/amount_grown = 0
var/player_spiders = 0
var/directive = "" //Message from the mother
var/poison_type = "toxin"
var/poison_per_bite = 5
var/list/faction = list("spiders")
@@ -71,6 +72,7 @@
S.poison_type = poison_type
S.poison_per_bite = poison_per_bite
S.faction = faction.Copy()
S.directive = directive
if(player_spiders)
S.player_spiders = 1
qdel(src)
@@ -87,6 +89,7 @@
var/obj/machinery/atmospherics/components/unary/vent_pump/entry_vent
var/travelling_in_vent = 0
var/player_spiders = 0
var/directive = "" //Message from the mother
var/poison_type = "toxin"
var/poison_per_bite = 5
var/list/faction = list("spiders")
@@ -192,6 +195,7 @@
S.poison_per_bite = poison_per_bite
S.poison_type = poison_type
S.faction = faction.Copy()
S.directive = directive
if(player_spiders)
S.playable_spider = TRUE
notify_ghosts("Spider [S.name] can be controlled", null, enter_link="<a href=?src=\ref[S];activate=1>(Click to play)</a>", source=S, action=NOTIFY_ATTACK)

View File

@@ -199,3 +199,57 @@
duration = 80
icon_state = "sigilactiveoverlay"
alpha = 0
/obj/effect/temp_visual/steam
name = "steam"
desc = "Steam! It's hot. It also serves as a game distribution platform."
icon_state = "smoke"
duration = 15
/obj/effect/temp_visual/steam/Initialize(mapload, steam_direction)
. = ..()
setDir(steam_direction)
var/x_offset = 0
var/y_offset = 0
switch(dir)
if(NORTH)
y_offset = 8
if(EAST)
x_offset = 4
y_offset = 4
if(SOUTH)
y_offset = 2
if(WEST)
x_offset = -4
y_offset = 4
animate(src, pixel_x = x_offset, pixel_y = y_offset, alpha = 50, time = 15)
/obj/effect/temp_visual/steam_release
name = "all the steam"
/obj/effect/temp_visual/steam_release/Initialize()
..()
for(var/V in GLOB.cardinals)
var/turf/T = get_step(src, V)
new/obj/effect/temp_visual/steam(T, V)
return INITIALIZE_HINT_QDEL
//Foreshadows a servant warping in.
/obj/effect/temp_visual/ratvar/warp_marker
name = "illuminant marker"
desc = "A silhouette of dim light. It's getting brighter!"
resistance_flags = INDESTRUCTIBLE
icon = 'icons/effects/genetics.dmi'
icon_state = "servitude"
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
anchored = TRUE
alpha = 0
light_color = "#FFE48E"
light_range = 2
light_power = 0.7
duration = 55
/obj/effect/temp_visual/ratvar/warp_marker/Initialize(mapload, mob/living/servant)
. = ..()
animate(src, alpha = 255, time = 50)

View File

@@ -123,6 +123,7 @@ obj/item/construction
lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi'
max_matter = 160
flags_2 = NO_MAT_REDEMPTION_2
var/mode = 1
var/canRturf = 0
var/ranged = FALSE

View File

@@ -1,70 +1,71 @@
/obj/item/bodybag
name = "body bag"
desc = "A folded bag designed for the storage and transportation of cadavers."
icon = 'icons/obj/bodybag.dmi'
icon_state = "bodybag_folded"
var/unfoldedbag_path = /obj/structure/closet/body_bag
w_class = WEIGHT_CLASS_SMALL
/obj/item/bodybag/attack_self(mob/user)
deploy_bodybag(user, user.loc)
/obj/item/bodybag/afterattack(atom/target, mob/user, proximity)
if(proximity)
if(isopenturf(target))
deploy_bodybag(user, target)
/obj/item/bodybag/proc/deploy_bodybag(mob/user, atom/location)
var/obj/structure/closet/body_bag/R = new unfoldedbag_path(location)
R.open(user)
R.add_fingerprint(user)
qdel(src)
// Bluespace bodybag
/obj/item/bodybag/bluespace
name = "bluespace body bag"
desc = "A folded bluespace body bag designed for the storage and transportation of cadavers."
icon = 'icons/obj/bodybag.dmi'
icon_state = "bluebodybag_folded"
unfoldedbag_path = /obj/structure/closet/body_bag/bluespace
w_class = WEIGHT_CLASS_SMALL
origin_tech = "bluespace=4;materials=4;plasmatech=4"
/obj/item/bodybag/bluespace/examine(mob/user)
..()
if(contents.len)
to_chat(user, "<span class='notice'>You can make out the shapes of [contents.len] objects through the fabric.</span>")
/obj/item/bodybag/bluespace/Destroy()
for(var/atom/movable/A in contents)
A.forceMove(get_turf(src))
if(isliving(A))
to_chat(A, "<span class='notice'>You suddenly feel the space around you torn apart! You're free!</span>")
return ..()
/obj/item/bodybag/bluespace/deploy_bodybag(mob/user, atom/location)
var/obj/structure/closet/body_bag/R = new unfoldedbag_path(location)
for(var/atom/movable/A in contents)
A.forceMove(R)
if(isliving(A))
to_chat(A, "<span class='notice'>You suddenly feel air around you! You're free!</span>")
R.open(user)
R.add_fingerprint(user)
qdel(src)
/obj/item/bodybag/bluespace/container_resist(mob/living/user)
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't get out while you're restrained like this!</span>")
return
user.changeNext_move(CLICK_CD_BREAKOUT)
user.last_special = world.time + CLICK_CD_BREAKOUT
to_chat(user, "<span class='notice'>You claw at the fabric of [src], trying to tear it open...</span>")
to_chat(loc, "<span class='warning'>Someone starts trying to break free of [src]!</span>")
if(!do_after(user, 200, target = src))
to_chat(loc, "<span class='warning'>The pressure subsides. It seems that they've stopped resisting...</span>")
return
loc.visible_message("<span class='warning'>[user] suddenly appears in front of [loc]!</span>", "<span class='userdanger'>[user] breaks free of [src]!</span>")
qdel(src)
/obj/item/bodybag
name = "body bag"
desc = "A folded bag designed for the storage and transportation of cadavers."
icon = 'icons/obj/bodybag.dmi'
icon_state = "bodybag_folded"
var/unfoldedbag_path = /obj/structure/closet/body_bag
w_class = WEIGHT_CLASS_SMALL
/obj/item/bodybag/attack_self(mob/user)
deploy_bodybag(user, user.loc)
/obj/item/bodybag/afterattack(atom/target, mob/user, proximity)
if(proximity)
if(isopenturf(target))
deploy_bodybag(user, target)
/obj/item/bodybag/proc/deploy_bodybag(mob/user, atom/location)
var/obj/structure/closet/body_bag/R = new unfoldedbag_path(location)
R.open(user)
R.add_fingerprint(user)
qdel(src)
// Bluespace bodybag
/obj/item/bodybag/bluespace
name = "bluespace body bag"
desc = "A folded bluespace body bag designed for the storage and transportation of cadavers."
icon = 'icons/obj/bodybag.dmi'
icon_state = "bluebodybag_folded"
unfoldedbag_path = /obj/structure/closet/body_bag/bluespace
w_class = WEIGHT_CLASS_SMALL
flags_2 = NO_MAT_REDEMPTION_2
origin_tech = "bluespace=4;materials=4;plasmatech=4"
/obj/item/bodybag/bluespace/examine(mob/user)
..()
if(contents.len)
to_chat(user, "<span class='notice'>You can make out the shapes of [contents.len] objects through the fabric.</span>")
/obj/item/bodybag/bluespace/Destroy()
for(var/atom/movable/A in contents)
A.forceMove(get_turf(src))
if(isliving(A))
to_chat(A, "<span class='notice'>You suddenly feel the space around you torn apart! You're free!</span>")
return ..()
/obj/item/bodybag/bluespace/deploy_bodybag(mob/user, atom/location)
var/obj/structure/closet/body_bag/R = new unfoldedbag_path(location)
for(var/atom/movable/A in contents)
A.forceMove(R)
if(isliving(A))
to_chat(A, "<span class='notice'>You suddenly feel air around you! You're free!</span>")
R.open(user)
R.add_fingerprint(user)
qdel(src)
/obj/item/bodybag/bluespace/container_resist(mob/living/user)
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't get out while you're restrained like this!</span>")
return
user.changeNext_move(CLICK_CD_BREAKOUT)
user.last_special = world.time + CLICK_CD_BREAKOUT
to_chat(user, "<span class='notice'>You claw at the fabric of [src], trying to tear it open...</span>")
to_chat(loc, "<span class='warning'>Someone starts trying to break free of [src]!</span>")
if(!do_after(user, 200, target = src))
to_chat(loc, "<span class='warning'>The pressure subsides. It seems that they've stopped resisting...</span>")
return
loc.visible_message("<span class='warning'>[user] suddenly appears in front of [loc]!</span>", "<span class='userdanger'>[user] breaks free of [src]!</span>")
qdel(src)

View File

@@ -234,6 +234,9 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/clothing/mask/cigarette/attack(mob/living/carbon/M, mob/living/carbon/user)
if(!istype(M))
return ..()
if(M.on_fire && !lit)
light("<span class='notice'>[user] lights [src] with [M]'s burning body. What a cold-blooded badass.</span>")
return
var/obj/item/clothing/mask/cigarette/cig = help_light_cig(M)
if(lit && cig && user.a_intent == INTENT_HELP)
if(cig.lit)

View File

@@ -26,6 +26,14 @@ GLOBAL_LIST_EMPTY(PDAs)
var/obj/item/cartridge/cartridge = null //current cartridge
var/mode = 0 //Controls what menu the PDA will display. 0 is hub; the rest are either built in or based on cartridge.
var/icon_alert = "pda-r" //Icon to be overlayed for message alerts. Taken from the pda icon file.
var/font_index = 0 //This int tells DM which font is currently selected and lets DM know when the last font has been selected so that it can cycle back to the first font when "toggle font" is pressed again.
var/font_mode = "font-family:\"VT323\", monospace;letter-spacing:1px;" //The currently selected font.
var/background_color = "#808000" //The currently selected background color.
#define FONT_VT 0
#define FONT_SHARE 1
#define FONT_ORBITRON 2
#define FONT_MONO 3
//Secondary variables
var/scanmode = 0 //1 is medical scanner, 2 is forensics, 3 is reagent scanner.
@@ -58,6 +66,13 @@ GLOBAL_LIST_EMPTY(PDAs)
var/obj/item/inserted_item //Used for pen, crayon, and lipstick insertion or removal. Same as above.
var/overlays_x_offset = 0 //x offset to use for certain overlays
/obj/item/device/pda/examine(mob/user)
..()
if(!id && !inserted_item)
return
else
to_chat(user, "<span class='notice'>Alt-click to remove contents.</span>")
/obj/item/device/pda/Initialize()
. = ..()
if(fon)
@@ -121,7 +136,8 @@ GLOBAL_LIST_EMPTY(PDAs)
hidden_uplink.interact(user)
return
var/dat = "<html><head><title>Personal Data Assistant</title></head><body bgcolor=\"#808000\"><style>a, a:link, a:visited, a:active, a:hover { color: #000000; }img {border-style:none;}</style>"
var/dat = "<!DOCTYPE html><html><head><title>Personal Data Assistant</title><link href=\"https://fonts.googleapis.com/css?family=Orbitron|Share+Tech+Mono|VT323\" rel=\"stylesheet\"></head><body bgcolor=\"" + background_color + "\"><style>body{" + font_mode + "}ul,ol{list-style-type: none;}a, a:link, a:visited, a:active, a:hover { color: #000000;text-decoration:none; }img {border-style:none;}</style>"
dat += "<a href='byond://?src=\ref[src];choice=Refresh'><img src=pda_refresh.png> Refresh</a>"
@@ -130,6 +146,12 @@ GLOBAL_LIST_EMPTY(PDAs)
if (mode)
dat += " | <a href='byond://?src=\ref[src];choice=Return'><img src=pda_menu.png> Return</a>"
if (mode == 0)
dat += "<div align=\"center\">"
dat += "<br><a href='byond://?src=\ref[src];choice=Toggle_Font'>Toggle Font</a>"
dat += " | <a href='byond://?src=\ref[src];choice=Change_Color'>Change Color</a>"
dat += "</div>"
dat += "<br>"
if (!owner)
@@ -307,6 +329,24 @@ GLOBAL_LIST_EMPTY(PDAs)
//BASIC FUNCTIONS===================================
if("Refresh")//Refresh, goes to the end of the proc.
if ("Toggle_Font")
//CODE REVISION 2
font_index = (font_index + 1) % 4
switch(font_index)
if (FONT_VT)
font_mode = "font-family:\"VT323\", monospace;letter-spacing:1px;"
if (FONT_SHARE)
font_mode = "font-family:\"Share Tech Mono\", monospace;letter-spacing:0px;"
if (FONT_ORBITRON)
font_mode = "font-family:\"Orbitron\", monospace;letter-spacing:0px; font-size:15px"
if (FONT_MONO)
font_mode = "font-family:monospace;"
if ("Change_Color")
var/new_color = input("Please enter a color name or hex value (Default is \'#808000\').")as color
background_color = new_color
if("Return")//Return
if(mode<=9)
mode = 0
@@ -400,7 +440,7 @@ GLOBAL_LIST_EMPTY(PDAs)
if (in_range(src, U) && loc == U)
if (mode == 1 && n)
note = n
notehtml = parsepencode(n, U, SIGNFONT)
notehtml = parsemarkdown(n, U)
notescanned = 0
else
U << browse(null, "window=pda")
@@ -538,7 +578,7 @@ GLOBAL_LIST_EMPTY(PDAs)
P.show_recieved_message(msg,src)
if(!multiple)
show_to_ghosts(user,msg)
log_talk(user,"[key_name(user)] (PDA: [name]) sent \"[message]\" to [key_name(P,null,TRUE)]",LOGPDA)
log_talk(user,"[key_name(user)] (PDA: [initial(name)]) sent \"[message]\" to [key_name(P,null,TRUE)]",LOGPDA)
else
if(!multiple)
to_chat(user, "<span class='notice'>ERROR: Server isn't responding.</span>")
@@ -548,7 +588,7 @@ GLOBAL_LIST_EMPTY(PDAs)
if(multiple)
show_to_sender(last_sucessful_msg,1)
show_to_ghosts(user,last_sucessful_msg,1)
log_talk(user,"[user] (PDA: [name]) sent \"[message]\" to Everyone",LOGPDA)
log_talk(user,"[user] (PDA: [initial(name)]) sent \"[message]\" to Everyone",LOGPDA)
/obj/item/device/pda/proc/show_to_sender(datum/data_pda_msg/msg,multiple = 0)
tnote += "<i><b>&rarr; To [multiple ? "Everyone" : msg.recipient]:</b></i><br>[msg.message][msg.get_photo_ref()]<br>"

View File

@@ -1,7 +1,7 @@
GLOBAL_LIST_EMPTY(GPS_list)
/obj/item/device/gps
name = "global positioning system"
desc = "Helping lost spacemen find their way through the planets since 2016. Alt+click to toggle power."
desc = "Helping lost spacemen find their way through the planets since 2016."
icon = 'icons/obj/telescience.dmi'
icon_state = "gps-c"
w_class = WEIGHT_CLASS_SMALL
@@ -15,6 +15,9 @@ GLOBAL_LIST_EMPTY(GPS_list)
var/updating = TRUE //Automatic updating of GPS list. Can be set to manual by user.
var/global_mode = TRUE //If disabled, only GPS signals of the same Z level are shown
/obj/item/device/gps/examine(mob/user)
..()
to_chat(user, "<span class='notice'>Alt-click to switch it [tracking ? "off":"on"].</span>")
/obj/item/device/gps/Initialize()
. = ..()
@@ -209,4 +212,4 @@ GLOBAL_LIST_EMPTY(GPS_list)
clear()
tagged = null
STOP_PROCESSING(SSfastprocess, src)
. = ..()
. = ..()

View File

@@ -1,6 +1,6 @@
/obj/item/device/radio/headset
name = "radio headset"
desc = "An updated, modular intercom that fits over the head. Takes encryption keys. \nTo speak on the general radio frequency, use ; before speaking."
desc = "An updated, modular intercom that fits over the head. Takes encryption keys."
icon_state = "headset"
item_state = "headset"
materials = list(MAT_METAL=75)
@@ -11,6 +11,12 @@
var/obj/item/device/encryptionkey/keyslot2 = null
dog_fashion = null
/obj/item/device/radio/headset/examine(mob/user)
..()
to_chat(user, "<span class='notice'>To speak on the general radio frequency, use ; before speaking.</span>")
if (command)
to_chat(user, "<span class='notice'>Alt-click to toggle the high-volume mode.</span>")
/obj/item/device/radio/headset/Initialize()
. = ..()
recalculateChannels()

View File

@@ -15,6 +15,29 @@
/obj/item/device/radio/intercom/unscrewed
unfastened = TRUE
/obj/item/device/radio/intercom/ratvar
name = "hierophant intercom"
desc = "A modified intercom that uses the Hierophant network instead of subspace tech. Can listen to and broadcast on any frequency."
icon_state = "intercom_ratvar"
freerange = TRUE
/obj/item/device/radio/intercom/ratvar/attackby(obj/item/I, mob/living/user, params)
if(istype(I, /obj/item/screwdriver))
to_chat(user, "<span class='danger'>[src] is fastened to the wall with [is_servant_of_ratvar(user) ? "replicant alloy" : "some material you've never seen"], and can't be removed.</span>")
return //no unfastening!
. = ..()
/obj/item/device/radio/intercom/ratvar/process()
if(!istype(SSticker.mode, /datum/game_mode/clockwork_cult))
invisibility = INVISIBILITY_OBSERVER
alpha = 125
emped = TRUE
else
invisibility = initial(invisibility)
alpha = initial(alpha)
emped = FALSE
..()
/obj/item/device/radio/intercom/Initialize(mapload, ndir, building)
. = ..()
if(building)
@@ -114,7 +137,7 @@
if(!on)
icon_state = "intercom-p"
else
icon_state = "intercom"
icon_state = initial(icon_state)
/obj/item/device/radio/intercom/add_blood(list/blood_dna)
return 0

View File

@@ -214,7 +214,7 @@ MASS SPECTROMETER
var/cyberimp_detect
for(var/obj/item/organ/cyberimp/CI in C.internal_organs)
if(CI.status == ORGAN_ROBOTIC)
if(CI.status == ORGAN_ROBOTIC && !CI.syndicate_implant)
cyberimp_detect += "[C.name] is modified with a [CI.name].<br>"
if(cyberimp_detect)
to_chat(user, "<span class='notice'>Detected cybernetic modifications:</span>")

View File

@@ -38,10 +38,14 @@
/obj/item/toy/eightball/Initialize(mapload)
. = ..()
if(prob(1))
new /obj/item/toy/eightball/haunted(get_turf(src))
if(MakeHaunted())
return INITIALIZE_HINT_QDEL
/obj/item/toy/eightball/proc/MakeHaunted()
. = prob(1)
if(.)
new /obj/item/toy/eightball/haunted(loc)
/obj/item/toy/eightball/attack_self(mob/user)
if(shaking)
return
@@ -105,6 +109,9 @@
GLOB.poi_list -= src
. = ..()
/obj/item/toy/eightball/haunted/MakeHaunted()
return FALSE
/obj/item/toy/eightball/haunted/attack_ghost(mob/user)
if(!shaking)
to_chat(user, "<span class='warning'>[src] is not currently being shaken.</span>")

View File

@@ -1,188 +1,190 @@
/obj/item/extinguisher
name = "fire extinguisher"
desc = "A traditional red fire extinguisher."
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "fire_extinguisher0"
item_state = "fire_extinguisher"
hitsound = 'sound/weapons/smash.ogg'
flags_1 = CONDUCT_1
throwforce = 10
w_class = WEIGHT_CLASS_NORMAL
throw_speed = 2
throw_range = 7
force = 10
materials = list(MAT_METAL=90)
attack_verb = list("slammed", "whacked", "bashed", "thunked", "battered", "bludgeoned", "thrashed")
dog_fashion = /datum/dog_fashion/back
resistance_flags = FIRE_PROOF
var/max_water = 50
var/last_use = 1
var/safety = TRUE
var/refilling = FALSE
var/sprite_name = "fire_extinguisher"
var/power = 5 //Maximum distance launched water will travel
var/precision = 0 //By default, turfs picked from a spray are random, set to 1 to make it always have at least one water effect per row
var/cooling_power = 2 //Sets the cooling_temperature of the water reagent datum inside of the extinguisher when it is refilled
/obj/item/extinguisher/mini
name = "pocket fire extinguisher"
desc = "A light and compact fibreglass-framed model fire extinguisher."
icon_state = "miniFE0"
item_state = "miniFE"
hitsound = null //it is much lighter, after all.
flags_1 = null //doesn't CONDUCT_1
throwforce = 2
w_class = WEIGHT_CLASS_SMALL
force = 3
materials = list()
max_water = 30
sprite_name = "miniFE"
dog_fashion = null
/obj/item/extinguisher/New()
..()
create_reagents(max_water)
reagents.add_reagent("water", max_water)
/obj/item/extinguisher/attack_self(mob/user)
safety = !safety
src.icon_state = "[sprite_name][!safety]"
src.desc = "The safety is [safety ? "on" : "off"]."
to_chat(user, "The safety is [safety ? "on" : "off"].")
return
/obj/item/extinguisher/attack(mob/M, mob/user)
if(user.a_intent == INTENT_HELP && !safety) //If we're on help intent and going to spray people, don't bash them.
return FALSE
else
return ..()
/obj/item/extinguisher/attack_obj(obj/O, mob/living/user)
if(AttemptRefill(O, user))
refilling = TRUE
return FALSE
else
return ..()
/obj/item/extinguisher/examine(mob/user)
..()
if(reagents.total_volume)
to_chat(user, "It contains [round(reagents.total_volume)] units.")
else
to_chat(user, "It is empty.")
/obj/item/extinguisher/proc/AttemptRefill(atom/target, mob/user)
if(istype(target, /obj/structure/reagent_dispensers/watertank) && target.Adjacent(user))
var/safety_save = safety
safety = TRUE
if(reagents.total_volume == reagents.maximum_volume)
to_chat(user, "<span class='warning'>\The [src] is already full!</span>")
safety = safety_save
return 1
var/obj/structure/reagent_dispensers/watertank/W = target
var/transferred = W.reagents.trans_to(src, max_water)
if(transferred > 0)
to_chat(user, "<span class='notice'>\The [src] has been refilled by [transferred] units.</span>")
playsound(src.loc, 'sound/effects/refill.ogg', 50, 1, -6)
for(var/datum/reagent/water/R in reagents.reagent_list)
R.cooling_temperature = cooling_power
else
to_chat(user, "<span class='warning'>\The [W] is empty!</span>")
safety = safety_save
return 1
else
return 0
/obj/item/extinguisher/afterattack(atom/target, mob/user , flag)
// Make it so the extinguisher doesn't spray yourself when you click your inventory items
if (target.loc == user)
return
//TODO; Add support for reagents in water.
if(refilling)
refilling = FALSE
return
if (!safety)
if (src.reagents.total_volume < 1)
to_chat(usr, "<span class='warning'>\The [src] is empty!</span>")
return
if (world.time < src.last_use + 12)
return
src.last_use = world.time
playsound(src.loc, 'sound/effects/extinguish.ogg', 75, 1, -3)
var/direction = get_dir(src,target)
if(user.buckled && isobj(user.buckled) && !user.buckled.anchored)
spawn(0)
var/obj/B = user.buckled
var/movementdirection = turn(direction,180)
step(B, movementdirection)
sleep(1)
step(B, movementdirection)
sleep(1)
step(B, movementdirection)
sleep(1)
step(B, movementdirection)
sleep(2)
step(B, movementdirection)
sleep(2)
step(B, movementdirection)
sleep(3)
step(B, movementdirection)
sleep(3)
step(B, movementdirection)
sleep(3)
step(B, movementdirection)
else user.newtonian_move(turn(direction, 180))
var/turf/T = get_turf(target)
var/turf/T1 = get_step(T,turn(direction, 90))
var/turf/T2 = get_step(T,turn(direction, -90))
var/list/the_targets = list(T,T1,T2)
if(precision)
var/turf/T3 = get_step(T1, turn(direction, 90))
var/turf/T4 = get_step(T2,turn(direction, -90))
the_targets = list(T,T1,T2,T3,T4)
for(var/a=0, a<5, a++)
spawn(0)
var/obj/effect/particle_effect/water/W = new /obj/effect/particle_effect/water(get_turf(src))
var/turf/my_target = pick(the_targets)
if(precision)
the_targets -= my_target
var/datum/reagents/R = new/datum/reagents(5)
if(!W) return
W.reagents = R
R.my_atom = W
if(!W || !src) return
src.reagents.trans_to(W,1)
for(var/b=0, b<power, b++)
step_towards(W,my_target)
if(!W || !W.reagents) return
W.reagents.reaction(get_turf(W))
for(var/A in get_turf(W))
if(!W) return
W.reagents.reaction(A)
if(W.loc == my_target) break
sleep(2)
else
return ..()
/obj/item/extinguisher/AltClick(mob/user)
EmptyExtinguisher(user)
/obj/item/extinguisher/proc/EmptyExtinguisher(var/mob/user)
if(loc == user && reagents.total_volume)
reagents.clear_reagents()
var/turf/T = get_turf(loc)
if(isopenturf(T))
var/turf/open/theturf = T
theturf.MakeSlippery(min_wet_time = 10, wet_time_to_add = 5)
user.visible_message("[user] empties out \the [src] onto the floor using the release valve.", "<span class='info'>You quietly empty out \the [src] using its release valve.</span>")
/obj/item/extinguisher
name = "fire extinguisher"
desc = "A traditional red fire extinguisher."
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "fire_extinguisher0"
item_state = "fire_extinguisher"
hitsound = 'sound/weapons/smash.ogg'
flags_1 = CONDUCT_1
throwforce = 10
w_class = WEIGHT_CLASS_NORMAL
throw_speed = 2
throw_range = 7
force = 10
materials = list(MAT_METAL=90)
attack_verb = list("slammed", "whacked", "bashed", "thunked", "battered", "bludgeoned", "thrashed")
dog_fashion = /datum/dog_fashion/back
resistance_flags = FIRE_PROOF
var/max_water = 50
var/last_use = 1
var/safety = TRUE
var/refilling = FALSE
var/sprite_name = "fire_extinguisher"
var/power = 5 //Maximum distance launched water will travel
var/precision = 0 //By default, turfs picked from a spray are random, set to 1 to make it always have at least one water effect per row
var/cooling_power = 2 //Sets the cooling_temperature of the water reagent datum inside of the extinguisher when it is refilled
/obj/item/extinguisher/mini
name = "pocket fire extinguisher"
desc = "A light and compact fibreglass-framed model fire extinguisher."
icon_state = "miniFE0"
item_state = "miniFE"
hitsound = null //it is much lighter, after all.
flags_1 = null //doesn't CONDUCT_1
throwforce = 2
w_class = WEIGHT_CLASS_SMALL
force = 3
materials = list()
max_water = 30
sprite_name = "miniFE"
dog_fashion = null
/obj/item/extinguisher/New()
..()
create_reagents(max_water)
reagents.add_reagent("water", max_water)
/obj/item/extinguisher/attack_self(mob/user)
safety = !safety
src.icon_state = "[sprite_name][!safety]"
src.desc = "The safety is [safety ? "on" : "off"]."
to_chat(user, "The safety is [safety ? "on" : "off"].")
return
/obj/item/extinguisher/attack(mob/M, mob/user)
if(user.a_intent == INTENT_HELP && !safety) //If we're on help intent and going to spray people, don't bash them.
return FALSE
else
return ..()
/obj/item/extinguisher/attack_obj(obj/O, mob/living/user)
if(AttemptRefill(O, user))
refilling = TRUE
return FALSE
else
return ..()
/obj/item/extinguisher/examine(mob/user)
..()
if(reagents.total_volume)
to_chat(user, "It contains [round(reagents.total_volume)] units.")
to_chat(user, "<span class='notice'>Alt-click to empty it.</span>")
else
to_chat(user, "It is empty.")
/obj/item/extinguisher/proc/AttemptRefill(atom/target, mob/user)
if(istype(target, /obj/structure/reagent_dispensers/watertank) && target.Adjacent(user))
var/safety_save = safety
safety = TRUE
if(reagents.total_volume == reagents.maximum_volume)
to_chat(user, "<span class='warning'>\The [src] is already full!</span>")
safety = safety_save
return 1
var/obj/structure/reagent_dispensers/watertank/W = target
var/transferred = W.reagents.trans_to(src, max_water)
if(transferred > 0)
to_chat(user, "<span class='notice'>\The [src] has been refilled by [transferred] units.</span>")
playsound(src.loc, 'sound/effects/refill.ogg', 50, 1, -6)
for(var/datum/reagent/water/R in reagents.reagent_list)
R.cooling_temperature = cooling_power
else
to_chat(user, "<span class='warning'>\The [W] is empty!</span>")
safety = safety_save
return 1
else
return 0
/obj/item/extinguisher/afterattack(atom/target, mob/user , flag)
// Make it so the extinguisher doesn't spray yourself when you click your inventory items
if (target.loc == user)
return
//TODO; Add support for reagents in water.
if(refilling)
refilling = FALSE
return
if (!safety)
if (src.reagents.total_volume < 1)
to_chat(usr, "<span class='warning'>\The [src] is empty!</span>")
return
if (world.time < src.last_use + 12)
return
src.last_use = world.time
playsound(src.loc, 'sound/effects/extinguish.ogg', 75, 1, -3)
var/direction = get_dir(src,target)
if(user.buckled && isobj(user.buckled) && !user.buckled.anchored)
spawn(0)
var/obj/B = user.buckled
var/movementdirection = turn(direction,180)
step(B, movementdirection)
sleep(1)
step(B, movementdirection)
sleep(1)
step(B, movementdirection)
sleep(1)
step(B, movementdirection)
sleep(2)
step(B, movementdirection)
sleep(2)
step(B, movementdirection)
sleep(3)
step(B, movementdirection)
sleep(3)
step(B, movementdirection)
sleep(3)
step(B, movementdirection)
else user.newtonian_move(turn(direction, 180))
var/turf/T = get_turf(target)
var/turf/T1 = get_step(T,turn(direction, 90))
var/turf/T2 = get_step(T,turn(direction, -90))
var/list/the_targets = list(T,T1,T2)
if(precision)
var/turf/T3 = get_step(T1, turn(direction, 90))
var/turf/T4 = get_step(T2,turn(direction, -90))
the_targets = list(T,T1,T2,T3,T4)
for(var/a=0, a<5, a++)
spawn(0)
var/obj/effect/particle_effect/water/W = new /obj/effect/particle_effect/water(get_turf(src))
var/turf/my_target = pick(the_targets)
if(precision)
the_targets -= my_target
var/datum/reagents/R = new/datum/reagents(5)
if(!W) return
W.reagents = R
R.my_atom = W
if(!W || !src) return
src.reagents.trans_to(W,1)
for(var/b=0, b<power, b++)
step_towards(W,my_target)
if(!W || !W.reagents) return
W.reagents.reaction(get_turf(W))
for(var/A in get_turf(W))
if(!W) return
W.reagents.reaction(A)
if(W.loc == my_target) break
sleep(2)
else
return ..()
/obj/item/extinguisher/AltClick(mob/user)
EmptyExtinguisher(user)
/obj/item/extinguisher/proc/EmptyExtinguisher(var/mob/user)
if(loc == user && reagents.total_volume)
reagents.clear_reagents()
var/turf/T = get_turf(loc)
if(isopenturf(T))
var/turf/open/theturf = T
theturf.MakeSlippery(min_wet_time = 10, wet_time_to_add = 5)
user.visible_message("[user] empties out \the [src] onto the floor using the release valve.", "<span class='info'>You quietly empty out \the [src] using its release valve.</span>")

View File

@@ -317,6 +317,7 @@ GLOBAL_LIST_INIT(brass_recipes, list ( \
null,
new/datum/stack_recipe("directional brass window", /obj/structure/window/reinforced/clockwork/unanchored, time = 0, on_floor = TRUE, window_checks = TRUE), \
new/datum/stack_recipe("fulltile brass window", /obj/structure/window/reinforced/clockwork/fulltile/unanchored, 2, time = 0, on_floor = TRUE, window_checks = TRUE), \
new/datum/stack_recipe("brass chair", /obj/structure/chair/brass, 1, time = 0, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("brass table frame", /obj/structure/table_frame/brass, 1, time = 5, one_per_turf = TRUE, on_floor = TRUE) \
))
@@ -338,12 +339,21 @@ GLOBAL_LIST_INIT(brass_recipes, list ( \
new /obj/item/stack/sheet/runed_metal(loc, amount)
qdel(src)
/obj/item/stack/tile/brass/attack_self(mob/living/user)
if(!is_servant_of_ratvar(user))
to_chat(user, "<span class='danger'>[src] seems far too fragile and rigid to build with.</span>") //haha that's because it's actually replicant alloy you DUMMY
return
..()
/obj/item/stack/tile/brass/Initialize(mapload, new_amount, merge = TRUE)
recipes = GLOB.brass_recipes
. = ..()
pixel_x = 0
pixel_y = 0
/obj/item/stack/tile/brass/fifty
amount = 50
/obj/item/stack/sheet/lessergem
name = "lesser gems"
desc = "Rare kind of gems which are only gained by blood sacrifice to minor deities. They are needed in crafting powerful objects."

View File

@@ -76,6 +76,7 @@
to_chat(user, "There are [get_amount()] in the stack.")
else
to_chat(user, "There is [get_amount()] in the stack.")
to_chat(user, "<span class='notice'>Alt-click to take a custom amount.</span>")
/obj/item/stack/proc/get_amount()
if(is_cyborg)

View File

@@ -40,6 +40,7 @@
max_w_class = WEIGHT_CLASS_GIGANTIC
max_combined_w_class = 35
resistance_flags = FIRE_PROOF
flags_2 = NO_MAT_REDEMPTION_2
var/pshoom = 'sound/items/pshoom.ogg'
var/alt_sound = 'sound/items/pshoom_2.ogg'
armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0, fire = 60, acid = 50)

View File

@@ -1,381 +1,382 @@
/*
* These absorb the functionality of the plant bag, ore satchel, etc.
* They use the use_to_pickup, quick_gather, and quick_empty functions
* that were already defined in weapon/storage, but which had been
* re-implemented in other classes.
*
* Contains:
* Trash Bag
* Mining Satchel
* Plant Bag
* Sheet Snatcher
* Book Bag
* Biowaste Bag
*
* -Sayu
*/
// Generic non-item
/obj/item/storage/bag
allow_quick_gather = 1
allow_quick_empty = 1
display_contents_with_number = 1 // should work fine now
use_to_pickup = 1
slot_flags = SLOT_BELT
// -----------------------------
// Trash bag
// -----------------------------
/obj/item/storage/bag/trash
name = "trash bag"
desc = "It's the heavy-duty black polymer kind. Time to take out the trash!"
icon = 'icons/obj/janitor.dmi'
icon_state = "trashbag"
item_state = "trashbag"
lefthand_file = 'icons/mob/inhands/equipment/custodial_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/custodial_righthand.dmi'
w_class = WEIGHT_CLASS_BULKY
max_w_class = WEIGHT_CLASS_SMALL
max_combined_w_class = 30
storage_slots = 30
can_hold = list() // any
cant_hold = list(/obj/item/disk/nuclear)
/obj/item/storage/bag/trash/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] puts [src] over [user.p_their()] head and starts chomping at the insides! Disgusting!</span>")
playsound(loc, 'sound/items/eatfood.ogg', 50, 1, -1)
return (TOXLOSS)
/obj/item/storage/bag/trash/update_icon()
if(contents.len == 0)
icon_state = "[initial(icon_state)]"
else if(contents.len < 12)
icon_state = "[initial(icon_state)]1"
else if(contents.len < 21)
icon_state = "[initial(icon_state)]2"
else icon_state = "[initial(icon_state)]3"
/obj/item/storage/bag/trash/cyborg
/obj/item/storage/bag/trash/proc/janicart_insert(mob/user, obj/structure/janitorialcart/J)
J.put_in_cart(src, user)
J.mybag=src
J.update_icon()
/obj/item/storage/bag/trash/cyborg/janicart_insert(mob/user, obj/structure/janitorialcart/J)
return
/obj/item/storage/bag/trash/bluespace
name = "trash bag of holding"
desc = "The latest and greatest in custodial convenience, a trashbag that is capable of holding vast quantities of garbage."
icon_state = "bluetrashbag"
origin_tech = "materials=4;bluespace=4;engineering=4;plasmatech=3"
max_combined_w_class = 60
storage_slots = 60
// -----------------------------
// Mining Satchel
// -----------------------------
/obj/item/storage/bag/ore
name = "mining satchel"
desc = "This little bugger can be used to store and transport ores."
icon = 'icons/obj/mining.dmi'
icon_state = "satchel"
origin_tech = "engineering=2"
slot_flags = SLOT_BELT | SLOT_POCKET
w_class = WEIGHT_CLASS_NORMAL
storage_slots = 50
max_combined_w_class = 200 //Doesn't matter what this is, so long as it's more or equal to storage_slots * ore.w_class
max_w_class = WEIGHT_CLASS_NORMAL
can_hold = list(/obj/item/ore)
var/spam_protection = FALSE //If this is TRUE, the holder won't receive any messages when they fail to pick up ore through crossing it
/obj/item/storage/bag/ore/cyborg
name = "cyborg mining satchel"
/obj/item/storage/bag/ore/holding //miners, your messiah has arrived
name = "mining satchel of holding"
desc = "A revolution in convenience, this satchel allows for huge amounts of ore storage. It's been outfitted with anti-malfunction safety measures."
storage_slots = INFINITY
max_combined_w_class = INFINITY
origin_tech = "bluespace=4;materials=3;engineering=3"
icon_state = "satchel_bspace"
// -----------------------------
// Plant bag
// -----------------------------
/obj/item/storage/bag/plants
name = "plant bag"
icon = 'icons/obj/hydroponics/equipment.dmi'
icon_state = "plantbag"
storage_slots = 100; //the number of plant pieces it can carry.
max_combined_w_class = 100 //Doesn't matter what this is, so long as it's more or equal to storage_slots * plants.w_class
max_w_class = WEIGHT_CLASS_NORMAL
w_class = WEIGHT_CLASS_TINY
can_hold = list(/obj/item/reagent_containers/food/snacks/grown, /obj/item/seeds, /obj/item/grown, /obj/item/reagent_containers/honeycomb)
resistance_flags = FLAMMABLE
////////
/obj/item/storage/bag/plants/portaseeder
name = "portable seed extractor"
desc = "For the enterprising botanist on the go. Less efficient than the stationary model, it creates one seed per plant."
icon_state = "portaseeder"
origin_tech = "biotech=3;engineering=2"
/obj/item/storage/bag/plants/portaseeder/verb/dissolve_contents()
set name = "Activate Seed Extraction"
set category = "Object"
set desc = "Activate to convert your plants into plantable seeds."
if(usr.stat || !usr.canmove || usr.restrained())
return
for(var/obj/item/O in contents)
seedify(O, 1)
close_all()
// -----------------------------
// Sheet Snatcher
// -----------------------------
// Because it stacks stacks, this doesn't operate normally.
// However, making it a storage/bag allows us to reuse existing code in some places. -Sayu
/obj/item/storage/bag/sheetsnatcher
name = "sheet snatcher"
desc = "A patented Nanotrasen storage system designed for any kind of mineral sheet."
icon = 'icons/obj/mining.dmi'
icon_state = "sheetsnatcher"
var/capacity = 300; //the number of sheets it can carry.
w_class = WEIGHT_CLASS_NORMAL
allow_quick_empty = 1 // this function is superceded
/obj/item/storage/bag/sheetsnatcher/can_be_inserted(obj/item/W, stop_messages = 0)
if(!istype(W, /obj/item/stack/sheet) || istype(W, /obj/item/stack/sheet/mineral/sandstone) || istype(W, /obj/item/stack/sheet/mineral/wood))
if(!stop_messages)
to_chat(usr, "The snatcher does not accept [W].")
return 0 //I don't care, but the existing code rejects them for not being "sheets" *shrug* -Sayu
var/current = 0
for(var/obj/item/stack/sheet/S in contents)
current += S.amount
if(capacity == current)//If it's full, you're done
if(!stop_messages)
to_chat(usr, "<span class='danger'>The snatcher is full.</span>")
return 0
return 1
// Modified handle_item_insertion. Would prefer not to, but...
/obj/item/storage/bag/sheetsnatcher/handle_item_insertion(obj/item/W, prevent_warning = 0)
var/obj/item/stack/sheet/S = W
if(!istype(S)) return 0
var/amount
var/inserted = 0
var/current = 0
for(var/obj/item/stack/sheet/S2 in contents)
current += S2.amount
if(capacity < current + S.amount)//If the stack will fill it up
amount = capacity - current
else
amount = S.amount
for(var/obj/item/stack/sheet/sheet in contents)
if(S.type == sheet.type) // we are violating the amount limitation because these are not sane objects
sheet.amount += amount // they should only be removed through procs in this file, which split them up.
S.amount -= amount
inserted = 1
break
if(!inserted || !S.amount)
usr.dropItemToGround(S)
if (usr.client && usr.s_active != src)
usr.client.screen -= S
S.dropped(usr)
if(!S.amount)
qdel(S)
else
if(S.pulledby)
S.pulledby.stop_pulling()
S.loc = src
orient2hud(usr)
if(usr.s_active)
usr.s_active.show_to(usr)
update_icon()
return 1
// Sets up numbered display to show the stack size of each stored mineral
// NOTE: numbered display is turned off currently because it's broken
/obj/item/storage/bag/sheetsnatcher/orient2hud(mob/user)
var/adjusted_contents = contents.len
//Numbered contents display
var/list/datum/numbered_display/numbered_contents
if(display_contents_with_number)
numbered_contents = list()
adjusted_contents = 0
for(var/obj/item/stack/sheet/I in contents)
adjusted_contents++
var/datum/numbered_display/D = new/datum/numbered_display(I)
D.number = I.amount
numbered_contents.Add( D )
var/row_num = 0
var/col_count = min(7,storage_slots) -1
if (adjusted_contents > 7)
row_num = round((adjusted_contents-1) / 7) // 7 is the maximum allowed width.
src.standard_orient_objs(row_num, col_count, numbered_contents)
return
// Modified quick_empty verb drops appropriate sized stacks
/obj/item/storage/bag/sheetsnatcher/quick_empty()
var/location = get_turf(src)
for(var/obj/item/stack/sheet/S in contents)
while(S.amount)
var/obj/item/stack/sheet/N = new S.type(location)
var/stacksize = min(S.amount,N.max_amount)
N.amount = stacksize
S.amount -= stacksize
if(!S.amount)
qdel(S)// todo: there's probably something missing here
orient2hud(usr)
if(usr.s_active)
usr.s_active.show_to(usr)
update_icon()
// Instead of removing
/obj/item/storage/bag/sheetsnatcher/remove_from_storage(obj/item/W, atom/new_location)
var/obj/item/stack/sheet/S = W
if(!istype(S)) return 0
//I would prefer to drop a new stack, but the item/attack_hand code
// that calls this can't recieve a different object than you clicked on.
//Therefore, make a new stack internally that has the remainder.
// -Sayu
if(S.amount > S.max_amount)
var/obj/item/stack/sheet/temp = new S.type(src)
temp.amount = S.amount - S.max_amount
S.amount = S.max_amount
return ..(S,new_location)
// -----------------------------
// Sheet Snatcher (Cyborg)
// -----------------------------
/obj/item/storage/bag/sheetsnatcher/borg
name = "sheet snatcher 9000"
desc = ""
capacity = 500//Borgs get more because >specialization
// -----------------------------
// Book bag
// -----------------------------
/obj/item/storage/bag/books
name = "book bag"
desc = "A bag for books."
icon = 'icons/obj/library.dmi'
icon_state = "bookbag"
display_contents_with_number = 0 //This would look really stupid otherwise
storage_slots = 7
max_combined_w_class = 21
max_w_class = WEIGHT_CLASS_NORMAL
w_class = WEIGHT_CLASS_BULKY //Bigger than a book because physics
can_hold = list(/obj/item/book, /obj/item/storage/book, /obj/item/spellbook)
resistance_flags = FLAMMABLE
/*
* Trays - Agouri
*/
/obj/item/storage/bag/tray
name = "tray"
icon = 'icons/obj/food/containers.dmi'
icon_state = "tray"
desc = "A metal tray to lay food on."
force = 5
throwforce = 10
throw_speed = 3
throw_range = 5
w_class = WEIGHT_CLASS_BULKY
flags_1 = CONDUCT_1
materials = list(MAT_METAL=3000)
preposition = "on"
/obj/item/storage/bag/tray/attack(mob/living/M, mob/living/user)
..()
// Drop all the things. All of them.
var/list/obj/item/oldContents = contents.Copy()
quick_empty()
// Make each item scatter a bit
for(var/obj/item/I in oldContents)
spawn()
for(var/i = 1, i <= rand(1,2), i++)
if(I)
step(I, pick(NORTH,SOUTH,EAST,WEST))
sleep(rand(2,4))
if(prob(50))
playsound(M, 'sound/items/trayhit1.ogg', 50, 1)
else
playsound(M, 'sound/items/trayhit2.ogg', 50, 1)
if(ishuman(M) || ismonkey(M))
if(prob(10))
M.Knockdown(40)
/obj/item/storage/bag/tray/proc/rebuild_overlays()
cut_overlays()
for(var/obj/item/I in contents)
add_overlay(mutable_appearance(I.icon, I.icon_state))
/obj/item/storage/bag/tray/remove_from_storage(obj/item/W as obj, atom/new_location)
..()
rebuild_overlays()
/obj/item/storage/bag/tray/handle_item_insertion(obj/item/I, prevent_warning = 0)
add_overlay(mutable_appearance(I.icon, I.icon_state))
. = ..()
/*
* Chemistry bag
*/
/obj/item/storage/bag/chemistry
name = "chemistry bag"
icon = 'icons/obj/chemical.dmi'
icon_state = "bag"
desc = "A bag for storing pills, patches, and bottles."
storage_slots = 50
max_combined_w_class = 200
w_class = WEIGHT_CLASS_TINY
preposition = "in"
can_hold = list(/obj/item/reagent_containers/pill, /obj/item/reagent_containers/glass/beaker, /obj/item/reagent_containers/glass/bottle)
resistance_flags = FLAMMABLE
/*
* Biowaste bag (mostly for xenobiologists)
*/
/obj/item/storage/bag/bio
name = "bio bag"
icon = 'icons/obj/chemical.dmi'
icon_state = "biobag"
desc = "A bag for the safe transportation and disposal of biowaste and other biological materials."
storage_slots = 25
max_combined_w_class = 200
w_class = WEIGHT_CLASS_TINY
preposition = "in"
can_hold = list(/obj/item/slime_extract, /obj/item/reagent_containers/syringe, /obj/item/reagent_containers/glass/beaker, /obj/item/reagent_containers/glass/bottle, /obj/item/reagent_containers/blood, /obj/item/reagent_containers/hypospray/medipen, /obj/item/reagent_containers/food/snacks/deadmouse, /obj/item/reagent_containers/food/snacks/monkeycube)
resistance_flags = FLAMMABLE
/*
* These absorb the functionality of the plant bag, ore satchel, etc.
* They use the use_to_pickup, quick_gather, and quick_empty functions
* that were already defined in weapon/storage, but which had been
* re-implemented in other classes.
*
* Contains:
* Trash Bag
* Mining Satchel
* Plant Bag
* Sheet Snatcher
* Book Bag
* Biowaste Bag
*
* -Sayu
*/
// Generic non-item
/obj/item/storage/bag
allow_quick_gather = 1
allow_quick_empty = 1
display_contents_with_number = 1 // should work fine now
use_to_pickup = 1
slot_flags = SLOT_BELT
// -----------------------------
// Trash bag
// -----------------------------
/obj/item/storage/bag/trash
name = "trash bag"
desc = "It's the heavy-duty black polymer kind. Time to take out the trash!"
icon = 'icons/obj/janitor.dmi'
icon_state = "trashbag"
item_state = "trashbag"
lefthand_file = 'icons/mob/inhands/equipment/custodial_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/custodial_righthand.dmi'
w_class = WEIGHT_CLASS_BULKY
max_w_class = WEIGHT_CLASS_SMALL
max_combined_w_class = 30
storage_slots = 30
can_hold = list() // any
cant_hold = list(/obj/item/disk/nuclear)
/obj/item/storage/bag/trash/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] puts [src] over [user.p_their()] head and starts chomping at the insides! Disgusting!</span>")
playsound(loc, 'sound/items/eatfood.ogg', 50, 1, -1)
return (TOXLOSS)
/obj/item/storage/bag/trash/update_icon()
if(contents.len == 0)
icon_state = "[initial(icon_state)]"
else if(contents.len < 12)
icon_state = "[initial(icon_state)]1"
else if(contents.len < 21)
icon_state = "[initial(icon_state)]2"
else icon_state = "[initial(icon_state)]3"
/obj/item/storage/bag/trash/cyborg
/obj/item/storage/bag/trash/proc/janicart_insert(mob/user, obj/structure/janitorialcart/J)
J.put_in_cart(src, user)
J.mybag=src
J.update_icon()
/obj/item/storage/bag/trash/cyborg/janicart_insert(mob/user, obj/structure/janitorialcart/J)
return
/obj/item/storage/bag/trash/bluespace
name = "trash bag of holding"
desc = "The latest and greatest in custodial convenience, a trashbag that is capable of holding vast quantities of garbage."
icon_state = "bluetrashbag"
origin_tech = "materials=4;bluespace=4;engineering=4;plasmatech=3"
max_combined_w_class = 60
storage_slots = 60
flags_2 = NO_MAT_REDEMPTION_2
// -----------------------------
// Mining Satchel
// -----------------------------
/obj/item/storage/bag/ore
name = "mining satchel"
desc = "This little bugger can be used to store and transport ores."
icon = 'icons/obj/mining.dmi'
icon_state = "satchel"
origin_tech = "engineering=2"
slot_flags = SLOT_BELT | SLOT_POCKET
w_class = WEIGHT_CLASS_NORMAL
storage_slots = 50
max_combined_w_class = 200 //Doesn't matter what this is, so long as it's more or equal to storage_slots * ore.w_class
max_w_class = WEIGHT_CLASS_NORMAL
can_hold = list(/obj/item/ore)
var/spam_protection = FALSE //If this is TRUE, the holder won't receive any messages when they fail to pick up ore through crossing it
/obj/item/storage/bag/ore/cyborg
name = "cyborg mining satchel"
/obj/item/storage/bag/ore/holding //miners, your messiah has arrived
name = "mining satchel of holding"
desc = "A revolution in convenience, this satchel allows for huge amounts of ore storage. It's been outfitted with anti-malfunction safety measures."
storage_slots = INFINITY
max_combined_w_class = INFINITY
origin_tech = "bluespace=4;materials=3;engineering=3"
icon_state = "satchel_bspace"
// -----------------------------
// Plant bag
// -----------------------------
/obj/item/storage/bag/plants
name = "plant bag"
icon = 'icons/obj/hydroponics/equipment.dmi'
icon_state = "plantbag"
storage_slots = 100; //the number of plant pieces it can carry.
max_combined_w_class = 100 //Doesn't matter what this is, so long as it's more or equal to storage_slots * plants.w_class
max_w_class = WEIGHT_CLASS_NORMAL
w_class = WEIGHT_CLASS_TINY
can_hold = list(/obj/item/reagent_containers/food/snacks/grown, /obj/item/seeds, /obj/item/grown, /obj/item/reagent_containers/honeycomb)
resistance_flags = FLAMMABLE
////////
/obj/item/storage/bag/plants/portaseeder
name = "portable seed extractor"
desc = "For the enterprising botanist on the go. Less efficient than the stationary model, it creates one seed per plant."
icon_state = "portaseeder"
origin_tech = "biotech=3;engineering=2"
/obj/item/storage/bag/plants/portaseeder/verb/dissolve_contents()
set name = "Activate Seed Extraction"
set category = "Object"
set desc = "Activate to convert your plants into plantable seeds."
if(usr.stat || !usr.canmove || usr.restrained())
return
for(var/obj/item/O in contents)
seedify(O, 1)
close_all()
// -----------------------------
// Sheet Snatcher
// -----------------------------
// Because it stacks stacks, this doesn't operate normally.
// However, making it a storage/bag allows us to reuse existing code in some places. -Sayu
/obj/item/storage/bag/sheetsnatcher
name = "sheet snatcher"
desc = "A patented Nanotrasen storage system designed for any kind of mineral sheet."
icon = 'icons/obj/mining.dmi'
icon_state = "sheetsnatcher"
var/capacity = 300; //the number of sheets it can carry.
w_class = WEIGHT_CLASS_NORMAL
allow_quick_empty = 1 // this function is superceded
/obj/item/storage/bag/sheetsnatcher/can_be_inserted(obj/item/W, stop_messages = 0)
if(!istype(W, /obj/item/stack/sheet) || istype(W, /obj/item/stack/sheet/mineral/sandstone) || istype(W, /obj/item/stack/sheet/mineral/wood))
if(!stop_messages)
to_chat(usr, "The snatcher does not accept [W].")
return 0 //I don't care, but the existing code rejects them for not being "sheets" *shrug* -Sayu
var/current = 0
for(var/obj/item/stack/sheet/S in contents)
current += S.amount
if(capacity == current)//If it's full, you're done
if(!stop_messages)
to_chat(usr, "<span class='danger'>The snatcher is full.</span>")
return 0
return 1
// Modified handle_item_insertion. Would prefer not to, but...
/obj/item/storage/bag/sheetsnatcher/handle_item_insertion(obj/item/W, prevent_warning = 0)
var/obj/item/stack/sheet/S = W
if(!istype(S)) return 0
var/amount
var/inserted = 0
var/current = 0
for(var/obj/item/stack/sheet/S2 in contents)
current += S2.amount
if(capacity < current + S.amount)//If the stack will fill it up
amount = capacity - current
else
amount = S.amount
for(var/obj/item/stack/sheet/sheet in contents)
if(S.type == sheet.type) // we are violating the amount limitation because these are not sane objects
sheet.amount += amount // they should only be removed through procs in this file, which split them up.
S.amount -= amount
inserted = 1
break
if(!inserted || !S.amount)
usr.dropItemToGround(S)
if (usr.client && usr.s_active != src)
usr.client.screen -= S
S.dropped(usr)
if(!S.amount)
qdel(S)
else
if(S.pulledby)
S.pulledby.stop_pulling()
S.loc = src
orient2hud(usr)
if(usr.s_active)
usr.s_active.show_to(usr)
update_icon()
return 1
// Sets up numbered display to show the stack size of each stored mineral
// NOTE: numbered display is turned off currently because it's broken
/obj/item/storage/bag/sheetsnatcher/orient2hud(mob/user)
var/adjusted_contents = contents.len
//Numbered contents display
var/list/datum/numbered_display/numbered_contents
if(display_contents_with_number)
numbered_contents = list()
adjusted_contents = 0
for(var/obj/item/stack/sheet/I in contents)
adjusted_contents++
var/datum/numbered_display/D = new/datum/numbered_display(I)
D.number = I.amount
numbered_contents.Add( D )
var/row_num = 0
var/col_count = min(7,storage_slots) -1
if (adjusted_contents > 7)
row_num = round((adjusted_contents-1) / 7) // 7 is the maximum allowed width.
src.standard_orient_objs(row_num, col_count, numbered_contents)
return
// Modified quick_empty verb drops appropriate sized stacks
/obj/item/storage/bag/sheetsnatcher/quick_empty()
var/location = get_turf(src)
for(var/obj/item/stack/sheet/S in contents)
while(S.amount)
var/obj/item/stack/sheet/N = new S.type(location)
var/stacksize = min(S.amount,N.max_amount)
N.amount = stacksize
S.amount -= stacksize
if(!S.amount)
qdel(S)// todo: there's probably something missing here
orient2hud(usr)
if(usr.s_active)
usr.s_active.show_to(usr)
update_icon()
// Instead of removing
/obj/item/storage/bag/sheetsnatcher/remove_from_storage(obj/item/W, atom/new_location)
var/obj/item/stack/sheet/S = W
if(!istype(S)) return 0
//I would prefer to drop a new stack, but the item/attack_hand code
// that calls this can't recieve a different object than you clicked on.
//Therefore, make a new stack internally that has the remainder.
// -Sayu
if(S.amount > S.max_amount)
var/obj/item/stack/sheet/temp = new S.type(src)
temp.amount = S.amount - S.max_amount
S.amount = S.max_amount
return ..(S,new_location)
// -----------------------------
// Sheet Snatcher (Cyborg)
// -----------------------------
/obj/item/storage/bag/sheetsnatcher/borg
name = "sheet snatcher 9000"
desc = ""
capacity = 500//Borgs get more because >specialization
// -----------------------------
// Book bag
// -----------------------------
/obj/item/storage/bag/books
name = "book bag"
desc = "A bag for books."
icon = 'icons/obj/library.dmi'
icon_state = "bookbag"
display_contents_with_number = 0 //This would look really stupid otherwise
storage_slots = 7
max_combined_w_class = 21
max_w_class = WEIGHT_CLASS_NORMAL
w_class = WEIGHT_CLASS_BULKY //Bigger than a book because physics
can_hold = list(/obj/item/book, /obj/item/storage/book, /obj/item/spellbook)
resistance_flags = FLAMMABLE
/*
* Trays - Agouri
*/
/obj/item/storage/bag/tray
name = "tray"
icon = 'icons/obj/food/containers.dmi'
icon_state = "tray"
desc = "A metal tray to lay food on."
force = 5
throwforce = 10
throw_speed = 3
throw_range = 5
w_class = WEIGHT_CLASS_BULKY
flags_1 = CONDUCT_1
materials = list(MAT_METAL=3000)
preposition = "on"
/obj/item/storage/bag/tray/attack(mob/living/M, mob/living/user)
..()
// Drop all the things. All of them.
var/list/obj/item/oldContents = contents.Copy()
quick_empty()
// Make each item scatter a bit
for(var/obj/item/I in oldContents)
spawn()
for(var/i = 1, i <= rand(1,2), i++)
if(I)
step(I, pick(NORTH,SOUTH,EAST,WEST))
sleep(rand(2,4))
if(prob(50))
playsound(M, 'sound/items/trayhit1.ogg', 50, 1)
else
playsound(M, 'sound/items/trayhit2.ogg', 50, 1)
if(ishuman(M) || ismonkey(M))
if(prob(10))
M.Knockdown(40)
/obj/item/storage/bag/tray/proc/rebuild_overlays()
cut_overlays()
for(var/obj/item/I in contents)
add_overlay(mutable_appearance(I.icon, I.icon_state))
/obj/item/storage/bag/tray/remove_from_storage(obj/item/W as obj, atom/new_location)
..()
rebuild_overlays()
/obj/item/storage/bag/tray/handle_item_insertion(obj/item/I, prevent_warning = 0)
add_overlay(mutable_appearance(I.icon, I.icon_state))
. = ..()
/*
* Chemistry bag
*/
/obj/item/storage/bag/chemistry
name = "chemistry bag"
icon = 'icons/obj/chemical.dmi'
icon_state = "bag"
desc = "A bag for storing pills, patches, and bottles."
storage_slots = 50
max_combined_w_class = 200
w_class = WEIGHT_CLASS_TINY
preposition = "in"
can_hold = list(/obj/item/reagent_containers/pill, /obj/item/reagent_containers/glass/beaker, /obj/item/reagent_containers/glass/bottle)
resistance_flags = FLAMMABLE
/*
* Biowaste bag (mostly for xenobiologists)
*/
/obj/item/storage/bag/bio
name = "bio bag"
icon = 'icons/obj/chemical.dmi'
icon_state = "biobag"
desc = "A bag for the safe transportation and disposal of biowaste and other biological materials."
storage_slots = 25
max_combined_w_class = 200
w_class = WEIGHT_CLASS_TINY
preposition = "in"
can_hold = list(/obj/item/slime_extract, /obj/item/reagent_containers/syringe, /obj/item/reagent_containers/glass/beaker, /obj/item/reagent_containers/glass/bottle, /obj/item/reagent_containers/blood, /obj/item/reagent_containers/hypospray/medipen, /obj/item/reagent_containers/food/snacks/deadmouse, /obj/item/reagent_containers/food/snacks/monkeycube)
resistance_flags = FLAMMABLE

File diff suppressed because it is too large Load Diff

View File

@@ -125,13 +125,21 @@
icon_type = "cigarette"
spawn_type = /obj/item/clothing/mask/cigarette/space_cigarette
/obj/item/storage/fancy/cigarettes/examine(mob/user)
..()
to_chat(user, "<span class='notice'>Alt-click to extract contents.</span>")
/obj/item/storage/fancy/cigarettes/AltClick(mob/user)
if(user.get_active_held_item())
if(user.stat || user.restrained())
return
for(var/obj/item/lighter/lighter in src)
remove_from_storage(lighter, user.loc)
user.put_in_active_hand(lighter)
break
var/obj/item/clothing/mask/cigarette/W = locate(/obj/item/clothing/mask/cigarette) in contents
if(W && contents.len > 0)
remove_from_storage(W, user)
user.put_in_hands(W)
contents -= W
to_chat(user, "<span class='notice'>You take a [icon_type] out of the pack.</span>")
else
to_chat(user, "<span class='notice'>There are no [icon_type]s left in the pack.</span>")
/obj/item/storage/fancy/cigarettes/update_icon()
if(fancy_open || !contents.len)

View File

@@ -123,6 +123,11 @@
icon_broken = "medalbox+b"
can_hold = list(/obj/item/clothing/accessory/medal)
/obj/item/storage/lockbox/medal/examine(mob/user)
..()
if(!locked)
to_chat(user, "<span class='notice'>Alt-click to [open ? "close":"open"] it.</span>")
/obj/item/storage/lockbox/medal/AltClick()
if(!locked)
open = (open ? FALSE : TRUE)
@@ -179,4 +184,4 @@
/obj/item/storage/lockbox/medal/sci/PopulateContents()
for(var/i in 1 to 3)
new /obj/item/clothing/accessory/medal/plasma/nobel_science(src)
new /obj/item/clothing/accessory/medal/plasma/nobel_science(src)

View File

@@ -28,31 +28,29 @@
/obj/item/storage/secure/examine(mob/user)
..()
to_chat(user, text("The service panel is [src.open ? "open" : "closed"]."))
to_chat(user, text("The service panel is currently <b>[open ? "unscrewed" : "screwed shut"]</b>."))
/obj/item/storage/secure/attackby(obj/item/W, mob/user, params)
if(locked)
if (istype(W, /obj/item/screwdriver))
if (do_after(user, 20*W.toolspeed, target = src))
src.open =! src.open
user.show_message("<span class='notice'>You [open ? "open" : "close"] the service panel.</span>", 1)
if (do_after(user, 20*W.toolspeed, target = user))
open =! open
to_chat(user, "<span class='notice'>You [open ? "open" : "close"] the service panel.</span>")
return
if ((istype(W, /obj/item/device/multitool)) && (src.open == 1)&& (!src.l_hacking))
user.show_message("<span class='danger'>Now attempting to reset internal memory, please hold.</span>", 1)
src.l_hacking = 1
if (do_after(usr, 100*W.toolspeed, target = src))
if (prob(33))
src.l_setshort = 1
if (istype(W, /obj/item/wirecutters) || istype(W, /obj/item/card/emag))
to_chat(user, "<span class='danger'>[src] is protected from this sort of tampering, yet it appears the internal memory wires can still be <b>pulsed</b>.</span>")
if ((istype(W, /obj/item/device/multitool)) && (!l_hacking))
if(src.open == 1)
to_chat(user, "<span class='danger'>Now attempting to reset internal memory, please hold.</span>")
src.l_hacking = 1
if (do_after(usr, 400*W.toolspeed, target = user))
to_chat(user, "<span class='danger'>Internal memory reset - lock has been disengaged.</span>")
src.l_set = 0
user.show_message("<span class='danger'>Internal memory reset. Please give it a few seconds to reinitialize.</span>", 1)
sleep(80)
src.l_setshort = 0
src.l_hacking = 0
else
user.show_message("<span class='danger'>Unable to reset internal memory.</span>", 1)
src.l_hacking = 0
else
src.l_hacking = 0
to_chat(user, "<span class='notice'>You must <b>unscrew</b> the service panel before you can pulse the wiring.</span>")
return
//At this point you have exhausted all the special things to do when locked
// ... but it's still locked.

View File

@@ -1,186 +1,190 @@
/obj/item/storage/toolbox
name = "toolbox"
desc = "Danger. Very robust."
icon_state = "red"
item_state = "toolbox_red"
lefthand_file = 'icons/mob/inhands/equipment/toolbox_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/toolbox_righthand.dmi'
flags_1 = CONDUCT_1
force = 12
throwforce = 12
throw_speed = 2
throw_range = 7
w_class = WEIGHT_CLASS_BULKY
materials = list(MAT_METAL = 500)
origin_tech = "combat=1;engineering=1"
attack_verb = list("robusted")
hitsound = 'sound/weapons/smash.ogg'
var/latches = "single_latch"
var/has_latches = TRUE
/obj/item/storage/toolbox/Initialize()
. = ..()
if(has_latches)
if(prob(10))
latches = "double_latch"
if(prob(1))
latches = "triple_latch"
update_icon()
/obj/item/storage/toolbox/update_icon()
..()
cut_overlays()
if(has_latches)
add_overlay(latches)
/obj/item/storage/toolbox/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] robusts [user.p_them()]self with [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
return (BRUTELOSS)
/obj/item/storage/toolbox/emergency
name = "emergency toolbox"
icon_state = "red"
item_state = "toolbox_red"
/obj/item/storage/toolbox/emergency/PopulateContents()
new /obj/item/crowbar/red(src)
new /obj/item/weldingtool/mini(src)
new /obj/item/extinguisher/mini(src)
switch(rand(1,3))
if(1)
new /obj/item/device/flashlight(src)
if(2)
new /obj/item/device/flashlight/glowstick(src)
if(3)
new /obj/item/device/flashlight/flare(src)
new /obj/item/device/radio/off(src)
/obj/item/storage/toolbox/emergency/old
name = "rusty red toolbox"
icon_state = "toolbox_red_old"
has_latches = FALSE
/obj/item/storage/toolbox/mechanical
name = "mechanical toolbox"
icon_state = "blue"
item_state = "toolbox_blue"
/obj/item/storage/toolbox/mechanical/PopulateContents()
new /obj/item/screwdriver(src)
new /obj/item/wrench(src)
new /obj/item/weldingtool(src)
new /obj/item/crowbar(src)
new /obj/item/device/analyzer(src)
new /obj/item/wirecutters(src)
/obj/item/storage/toolbox/mechanical/old
name = "rusty blue toolbox"
icon_state = "toolbox_blue_old"
has_latches = FALSE
/obj/item/storage/toolbox/electrical
name = "electrical toolbox"
icon_state = "yellow"
item_state = "toolbox_yellow"
/obj/item/storage/toolbox/electrical/PopulateContents()
var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white")
new /obj/item/screwdriver(src)
new /obj/item/wirecutters(src)
new /obj/item/device/t_scanner(src)
new /obj/item/crowbar(src)
new /obj/item/stack/cable_coil(src,30,pickedcolor)
new /obj/item/stack/cable_coil(src,30,pickedcolor)
if(prob(5))
new /obj/item/clothing/gloves/color/yellow(src)
else
new /obj/item/stack/cable_coil(src,30,pickedcolor)
/obj/item/storage/toolbox/syndicate
name = "suspicious looking toolbox"
icon_state = "syndicate"
item_state = "toolbox_syndi"
origin_tech = "combat=2;syndicate=1;engineering=2"
silent = 1
force = 15
throwforce = 18
/obj/item/storage/toolbox/syndicate/PopulateContents()
new /obj/item/screwdriver/nuke(src)
new /obj/item/wrench(src)
new /obj/item/weldingtool/largetank(src)
new /obj/item/crowbar/red(src)
new /obj/item/wirecutters(src, "red")
new /obj/item/device/multitool(src)
new /obj/item/clothing/gloves/combat(src)
/obj/item/storage/toolbox/drone
name = "mechanical toolbox"
icon_state = "blue"
item_state = "toolbox_blue"
/obj/item/storage/toolbox/drone/PopulateContents()
var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white")
new /obj/item/screwdriver(src)
new /obj/item/wrench(src)
new /obj/item/weldingtool(src)
new /obj/item/crowbar(src)
new /obj/item/stack/cable_coil(src,30,pickedcolor)
new /obj/item/wirecutters(src)
new /obj/item/device/multitool(src)
/obj/item/storage/toolbox/brass
name = "brass box"
desc = "A huge brass box with several indentations in its surface."
icon_state = "brassbox"
item_state = null
has_latches = FALSE
resistance_flags = FIRE_PROOF | ACID_PROOF
w_class = WEIGHT_CLASS_HUGE
max_w_class = WEIGHT_CLASS_NORMAL
max_combined_w_class = 28
storage_slots = 28
attack_verb = list("robusted", "crushed", "smashed")
var/fabricator_type = /obj/item/clockwork/replica_fabricator/scarab
/obj/item/storage/toolbox/brass/prefilled/PopulateContents()
new fabricator_type(src)
new /obj/item/screwdriver/brass(src)
new /obj/item/wirecutters/brass(src)
new /obj/item/wrench/brass(src)
new /obj/item/crowbar/brass(src)
new /obj/item/weldingtool/experimental/brass(src)
/obj/item/storage/toolbox/brass/prefilled/ratvar
var/slab_type = /obj/item/clockwork/slab
/obj/item/storage/toolbox/brass/prefilled/ratvar/PopulateContents()
..()
new slab_type(src)
/obj/item/storage/toolbox/brass/prefilled/ratvar/admin
slab_type = /obj/item/clockwork/slab/debug
fabricator_type = /obj/item/clockwork/replica_fabricator/scarab/debug
/obj/item/storage/toolbox/artistic
name = "artistic toolbox"
desc = "A toolbox painted bright green. Why anyone would store art supplies in a toolbox is beyond you, but it has plenty of extra space."
icon_state = "green"
item_state = "artistic_toolbox"
max_combined_w_class = 20
storage_slots = 10
w_class = WEIGHT_CLASS_GIGANTIC //Holds more than a regular toolbox!
/obj/item/storage/toolbox/artistic/PopulateContents()
new/obj/item/storage/crayons(src)
new/obj/item/crowbar(src)
new/obj/item/stack/cable_coil/red(src)
new/obj/item/stack/cable_coil/yellow(src)
new/obj/item/stack/cable_coil/blue(src)
new/obj/item/stack/cable_coil/green(src)
new/obj/item/stack/cable_coil/pink(src)
new/obj/item/stack/cable_coil/orange(src)
new/obj/item/stack/cable_coil/cyan(src)
new/obj/item/stack/cable_coil/white(src)
/obj/item/storage/toolbox
name = "toolbox"
desc = "Danger. Very robust."
icon_state = "red"
item_state = "toolbox_red"
lefthand_file = 'icons/mob/inhands/equipment/toolbox_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/toolbox_righthand.dmi'
flags_1 = CONDUCT_1
force = 12
throwforce = 12
throw_speed = 2
throw_range = 7
w_class = WEIGHT_CLASS_BULKY
materials = list(MAT_METAL = 500)
origin_tech = "combat=1;engineering=1"
attack_verb = list("robusted")
hitsound = 'sound/weapons/smash.ogg'
var/latches = "single_latch"
var/has_latches = TRUE
/obj/item/storage/toolbox/Initialize()
. = ..()
if(has_latches)
if(prob(10))
latches = "double_latch"
if(prob(1))
latches = "triple_latch"
update_icon()
/obj/item/storage/toolbox/update_icon()
..()
cut_overlays()
if(has_latches)
add_overlay(latches)
/obj/item/storage/toolbox/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] robusts [user.p_them()]self with [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
return (BRUTELOSS)
/obj/item/storage/toolbox/emergency
name = "emergency toolbox"
icon_state = "red"
item_state = "toolbox_red"
/obj/item/storage/toolbox/emergency/PopulateContents()
new /obj/item/crowbar/red(src)
new /obj/item/weldingtool/mini(src)
new /obj/item/extinguisher/mini(src)
switch(rand(1,3))
if(1)
new /obj/item/device/flashlight(src)
if(2)
new /obj/item/device/flashlight/glowstick(src)
if(3)
new /obj/item/device/flashlight/flare(src)
new /obj/item/device/radio/off(src)
/obj/item/storage/toolbox/emergency/old
name = "rusty red toolbox"
icon_state = "toolbox_red_old"
has_latches = FALSE
/obj/item/storage/toolbox/mechanical
name = "mechanical toolbox"
icon_state = "blue"
item_state = "toolbox_blue"
/obj/item/storage/toolbox/mechanical/PopulateContents()
new /obj/item/screwdriver(src)
new /obj/item/wrench(src)
new /obj/item/weldingtool(src)
new /obj/item/crowbar(src)
new /obj/item/device/analyzer(src)
new /obj/item/wirecutters(src)
/obj/item/storage/toolbox/mechanical/old
name = "rusty blue toolbox"
icon_state = "toolbox_blue_old"
has_latches = FALSE
/obj/item/storage/toolbox/electrical
name = "electrical toolbox"
icon_state = "yellow"
item_state = "toolbox_yellow"
/obj/item/storage/toolbox/electrical/PopulateContents()
var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white")
new /obj/item/screwdriver(src)
new /obj/item/wirecutters(src)
new /obj/item/device/t_scanner(src)
new /obj/item/crowbar(src)
new /obj/item/stack/cable_coil(src,30,pickedcolor)
new /obj/item/stack/cable_coil(src,30,pickedcolor)
if(prob(5))
new /obj/item/clothing/gloves/color/yellow(src)
else
new /obj/item/stack/cable_coil(src,30,pickedcolor)
/obj/item/storage/toolbox/syndicate
name = "suspicious looking toolbox"
icon_state = "syndicate"
item_state = "toolbox_syndi"
origin_tech = "combat=2;syndicate=1;engineering=2"
silent = 1
force = 15
throwforce = 18
/obj/item/storage/toolbox/syndicate/PopulateContents()
new /obj/item/screwdriver/nuke(src)
new /obj/item/wrench(src)
new /obj/item/weldingtool/largetank(src)
new /obj/item/crowbar/red(src)
new /obj/item/wirecutters(src, "red")
new /obj/item/device/multitool(src)
new /obj/item/clothing/gloves/combat(src)
/obj/item/storage/toolbox/drone
name = "mechanical toolbox"
icon_state = "blue"
item_state = "toolbox_blue"
/obj/item/storage/toolbox/drone/PopulateContents()
var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white")
new /obj/item/screwdriver(src)
new /obj/item/wrench(src)
new /obj/item/weldingtool(src)
new /obj/item/crowbar(src)
new /obj/item/stack/cable_coil(src,30,pickedcolor)
new /obj/item/wirecutters(src)
new /obj/item/device/multitool(src)
/obj/item/storage/toolbox/brass
name = "brass box"
desc = "A huge brass box with several indentations in its surface."
icon_state = "brassbox"
item_state = null
has_latches = FALSE
resistance_flags = FIRE_PROOF | ACID_PROOF
w_class = WEIGHT_CLASS_HUGE
max_w_class = WEIGHT_CLASS_NORMAL
max_combined_w_class = 28
storage_slots = 28
attack_verb = list("robusted", "crushed", "smashed")
var/fabricator_type = /obj/item/clockwork/replica_fabricator/scarab
/obj/item/storage/toolbox/brass/prefilled/PopulateContents()
new fabricator_type(src)
new /obj/item/screwdriver/brass(src)
new /obj/item/wirecutters/brass(src)
new /obj/item/wrench/brass(src)
new /obj/item/crowbar/brass(src)
new /obj/item/weldingtool/experimental/brass(src)
/obj/item/storage/toolbox/brass/prefilled/servant
slot_flags = SLOT_BELT
fabricator_type = null
/obj/item/storage/toolbox/brass/prefilled/ratvar
var/slab_type = /obj/item/clockwork/slab
/obj/item/storage/toolbox/brass/prefilled/ratvar/PopulateContents()
..()
new slab_type(src)
/obj/item/storage/toolbox/brass/prefilled/ratvar/admin
slab_type = /obj/item/clockwork/slab/debug
fabricator_type = /obj/item/clockwork/replica_fabricator/scarab/debug
/obj/item/storage/toolbox/artistic
name = "artistic toolbox"
desc = "A toolbox painted bright green. Why anyone would store art supplies in a toolbox is beyond you, but it has plenty of extra space."
icon_state = "green"
item_state = "artistic_toolbox"
max_combined_w_class = 20
storage_slots = 10
w_class = WEIGHT_CLASS_GIGANTIC //Holds more than a regular toolbox!
/obj/item/storage/toolbox/artistic/PopulateContents()
new/obj/item/storage/crayons(src)
new/obj/item/crowbar(src)
new/obj/item/stack/cable_coil/red(src)
new/obj/item/stack/cable_coil/yellow(src)
new/obj/item/stack/cable_coil/blue(src)
new/obj/item/stack/cable_coil/green(src)
new/obj/item/stack/cable_coil/pink(src)
new/obj/item/stack/cable_coil/orange(src)
new/obj/item/stack/cable_coil/cyan(src)
new/obj/item/stack/cable_coil/white(src)

View File

@@ -1,183 +1,184 @@
/* Types of tanks!
* Contains:
* Oxygen
* Anesthetic
* Air
* Plasma
* Emergency Oxygen
*/
/*
* Oxygen
*/
/obj/item/tank/internals/oxygen
name = "oxygen tank"
desc = "A tank of oxygen."
icon_state = "oxygen"
distribute_pressure = TANK_DEFAULT_RELEASE_PRESSURE
force = 10
dog_fashion = /datum/dog_fashion/back
/obj/item/tank/internals/oxygen/New()
..()
air_contents.assert_gas("o2")
air_contents.gases["o2"][MOLES] = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/oxygen/yellow
desc = "A tank of oxygen, this one is yellow."
icon_state = "oxygen_f"
dog_fashion = null
/obj/item/tank/internals/oxygen/red
desc = "A tank of oxygen, this one is red."
icon_state = "oxygen_fr"
dog_fashion = null
/*
* Anesthetic
*/
/obj/item/tank/internals/anesthetic
name = "anesthetic tank"
desc = "A tank with an N2O/O2 gas mix."
icon_state = "anesthetic"
item_state = "an_tank"
force = 10
/obj/item/tank/internals/anesthetic/New()
..()
air_contents.assert_gases("o2", "n2o")
air_contents.gases["o2"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * O2STANDARD
air_contents.gases["n2o"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * N2STANDARD
return
/*
* Air
*/
/obj/item/tank/internals/air
name = "air tank"
desc = "Mixed anyone?"
icon_state = "oxygen"
force = 10
dog_fashion = /datum/dog_fashion/back
/obj/item/tank/internals/air/New()
..()
air_contents.assert_gases("o2","n2")
air_contents.gases["o2"][MOLES] = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * O2STANDARD
air_contents.gases["n2"][MOLES] = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * N2STANDARD
return
/*
* Plasma
*/
/obj/item/tank/internals/plasma
name = "plasma tank"
desc = "Contains dangerous plasma. Do not inhale. Warning: extremely flammable."
icon_state = "plasma"
flags_1 = CONDUCT_1
slot_flags = null //they have no straps!
force = 8
/obj/item/tank/internals/plasma/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/plasma/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/flamethrower))
var/obj/item/flamethrower/F = W
if ((!F.status)||(F.ptank))
return
if(!user.transferItemToLoc(src, F))
return
src.master = F
F.ptank = src
F.update_icon()
else
return ..()
/obj/item/tank/internals/plasma/full/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (10*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/*
* Plasmaman Plasma Tank
*/
/obj/item/tank/internals/plasmaman
name = "plasma internals tank"
desc = "A tank of plasma gas designed specifically for use as internals, particularly for plasma-based lifeforms. If you're not a Plasmaman, you probably shouldn't use this."
icon_state = "plasmaman_tank"
item_state = "plasmaman_tank"
force = 10
distribute_pressure = TANK_DEFAULT_RELEASE_PRESSURE
/obj/item/tank/internals/plasmaman/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/plasmaman/full/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (10*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/plasmaman/belt
icon_state = "plasmaman_tank_belt"
item_state = "plasmaman_tank_belt"
slot_flags = SLOT_BELT
force = 5
volume = 6
w_class = WEIGHT_CLASS_SMALL //thanks i forgot this
/obj/item/tank/internals/plasmaman/belt/full/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (10*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/*
* Emergency Oxygen
*/
/obj/item/tank/internals/emergency_oxygen
name = "emergency oxygen tank"
desc = "Used for emergencies. Contains very little oxygen, so try to conserve it until you actually need it."
icon_state = "emergency"
flags_1 = CONDUCT_1
slot_flags = SLOT_BELT
w_class = WEIGHT_CLASS_SMALL
force = 4
distribute_pressure = TANK_DEFAULT_RELEASE_PRESSURE
volume = 3 //Tiny. Real life equivalents only have 21 breaths of oxygen in them. They're EMERGENCY tanks anyway -errorage (dangercon 2011)
/obj/item/tank/internals/emergency_oxygen/New()
..()
air_contents.assert_gas("o2")
air_contents.gases["o2"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/emergency_oxygen/engi
name = "extended-capacity emergency oxygen tank"
icon_state = "emergency_engi"
volume = 6
/obj/item/tank/internals/emergency_oxygen/double
name = "double emergency oxygen tank"
icon_state = "emergency_engi"
volume = 10
/* Types of tanks!
* Contains:
* Oxygen
* Anesthetic
* Air
* Plasma
* Emergency Oxygen
*/
/*
* Oxygen
*/
/obj/item/tank/internals/oxygen
name = "oxygen tank"
desc = "A tank of oxygen."
icon_state = "oxygen"
distribute_pressure = TANK_DEFAULT_RELEASE_PRESSURE
force = 10
dog_fashion = /datum/dog_fashion/back
/obj/item/tank/internals/oxygen/New()
..()
air_contents.assert_gas("o2")
air_contents.gases["o2"][MOLES] = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/oxygen/yellow
desc = "A tank of oxygen, this one is yellow."
icon_state = "oxygen_f"
dog_fashion = null
/obj/item/tank/internals/oxygen/red
desc = "A tank of oxygen, this one is red."
icon_state = "oxygen_fr"
dog_fashion = null
/*
* Anesthetic
*/
/obj/item/tank/internals/anesthetic
name = "anesthetic tank"
desc = "A tank with an N2O/O2 gas mix."
icon_state = "anesthetic"
item_state = "an_tank"
force = 10
/obj/item/tank/internals/anesthetic/New()
..()
air_contents.assert_gases("o2", "n2o")
air_contents.gases["o2"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * O2STANDARD
air_contents.gases["n2o"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * N2STANDARD
return
/*
* Air
*/
/obj/item/tank/internals/air
name = "air tank"
desc = "Mixed anyone?"
icon_state = "air"
item_state = "air"
force = 10
dog_fashion = /datum/dog_fashion/back
/obj/item/tank/internals/air/New()
..()
air_contents.assert_gases("o2","n2")
air_contents.gases["o2"][MOLES] = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * O2STANDARD
air_contents.gases["n2"][MOLES] = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * N2STANDARD
return
/*
* Plasma
*/
/obj/item/tank/internals/plasma
name = "plasma tank"
desc = "Contains dangerous plasma. Do not inhale. Warning: extremely flammable."
icon_state = "plasma"
flags_1 = CONDUCT_1
slot_flags = null //they have no straps!
force = 8
/obj/item/tank/internals/plasma/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/plasma/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/flamethrower))
var/obj/item/flamethrower/F = W
if ((!F.status)||(F.ptank))
return
if(!user.transferItemToLoc(src, F))
return
src.master = F
F.ptank = src
F.update_icon()
else
return ..()
/obj/item/tank/internals/plasma/full/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (10*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/*
* Plasmaman Plasma Tank
*/
/obj/item/tank/internals/plasmaman
name = "plasma internals tank"
desc = "A tank of plasma gas designed specifically for use as internals, particularly for plasma-based lifeforms. If you're not a Plasmaman, you probably shouldn't use this."
icon_state = "plasmaman_tank"
item_state = "plasmaman_tank"
force = 10
distribute_pressure = TANK_DEFAULT_RELEASE_PRESSURE
/obj/item/tank/internals/plasmaman/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/plasmaman/full/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (10*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/plasmaman/belt
icon_state = "plasmaman_tank_belt"
item_state = "plasmaman_tank_belt"
slot_flags = SLOT_BELT
force = 5
volume = 6
w_class = WEIGHT_CLASS_SMALL //thanks i forgot this
/obj/item/tank/internals/plasmaman/belt/full/New()
..()
air_contents.assert_gas("plasma")
air_contents.gases["plasma"][MOLES] = (10*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/*
* Emergency Oxygen
*/
/obj/item/tank/internals/emergency_oxygen
name = "emergency oxygen tank"
desc = "Used for emergencies. Contains very little oxygen, so try to conserve it until you actually need it."
icon_state = "emergency"
flags_1 = CONDUCT_1
slot_flags = SLOT_BELT
w_class = WEIGHT_CLASS_SMALL
force = 4
distribute_pressure = TANK_DEFAULT_RELEASE_PRESSURE
volume = 3 //Tiny. Real life equivalents only have 21 breaths of oxygen in them. They're EMERGENCY tanks anyway -errorage (dangercon 2011)
/obj/item/tank/internals/emergency_oxygen/New()
..()
air_contents.assert_gas("o2")
air_contents.gases["o2"][MOLES] = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/tank/internals/emergency_oxygen/engi
name = "extended-capacity emergency oxygen tank"
icon_state = "emergency_engi"
volume = 6
/obj/item/tank/internals/emergency_oxygen/double
name = "double emergency oxygen tank"
icon_state = "emergency_engi"
volume = 10

View File

@@ -177,7 +177,7 @@
if("pressure")
var/pressure = params["pressure"]
if(pressure == "reset")
pressure = TANK_DEFAULT_RELEASE_PRESSURE
pressure = initial(distribute_pressure)
. = TRUE
else if(pressure == "min")
pressure = TANK_MIN_RELEASE_PRESSURE

View File

@@ -104,11 +104,11 @@
/obj/item/paper/guides/antag/supermatter_sliver
info = "How to safely extract a supermatter sliver:<br>\
<ul>\
<li>Approach an active supermatter crystal with proper protective gear. DO NOT MAKE PHYSICAL CONTACT.</li>\
<li>Approach an active supermatter crystal with radiation shielded personal protective equipment. DO NOT MAKE PHYSICAL CONTACT.</li>\
<li>Use a supermatter scalpel (provided) to slice off a sliver of the crystal.</li>\
<li>Use supermatter extraction tongs (also provided) to safely remove the sliver.</li>\
<li>Use supermatter extraction tongs (also provided) to safely pick up the sliver you sliced off.</li>\
<li>Physical contact of any object with the sliver will dust the object, as well as yourself.</li>\
<li>Use the tongs to place the sliver into the provided container, which will take some time to seal</li>\
<li>Use the tongs to place the sliver into the provided container, which will take some time to seal.</li>\
<li>Get the hell out before the crystal delaminates.</li>\
<li>???</li>\
</ul>"

View File

@@ -427,6 +427,11 @@
var/obj/item/grenade/explosive = null
var/war_cry = "AAAAARGH!!!"
/obj/item/twohanded/spear/examine(mob/user)
..()
if(explosive)
to_chat(user, "<span class='notice'>Alt-click to set your war cry.</span>")
/obj/item/twohanded/spear/update_icon()
if(explosive)
icon_state = "spearbomb[wielded]"
@@ -475,7 +480,7 @@
if(G)
explosive = G
name = "explosive lance"
desc = "A makeshift spear with [G] attached to it. Alt+click on the spear to set your war cry!"
desc = "A makeshift spear with [G] attached to it."
update_icon()
// CHAINSAW

View File

@@ -0,0 +1,531 @@
/obj/item/weapon/storage/belt
name = "belt"
desc = "Can hold various things."
icon = 'icons/obj/clothing/belts.dmi'
icon_state = "utilitybelt"
item_state = "utility"
slot_flags = SLOT_BELT
attack_verb = list("whipped", "lashed", "disciplined")
max_integrity = 300
var/content_overlays = FALSE //If this is true, the belt will gain overlays based on what it's holding
/obj/item/weapon/storage/belt/update_icon()
cut_overlays()
if(content_overlays)
for(var/obj/item/I in contents)
var/mutable_appearance/M = I.get_belt_overlay()
add_overlay(M)
..()
/obj/item/weapon/storage/belt/Initialize()
. = ..()
update_icon()
/obj/item/weapon/storage/belt/utility
name = "toolbelt" //Carn: utility belt is nicer, but it bamboozles the text parsing.
desc = "Holds tools."
icon_state = "utilitybelt"
item_state = "utility"
can_hold = list(
/obj/item/weapon/crowbar,
/obj/item/weapon/screwdriver,
/obj/item/weapon/weldingtool,
/obj/item/weapon/wirecutters,
/obj/item/weapon/wrench,
/obj/item/device/multitool,
/obj/item/device/flashlight,
/obj/item/stack/cable_coil,
/obj/item/device/t_scanner,
/obj/item/device/analyzer,
/obj/item/weapon/extinguisher/mini,
/obj/item/device/radio,
/obj/item/clothing/gloves
)
content_overlays = TRUE
/obj/item/weapon/storage/belt/utility/chief
name = "\improper Chief Engineer's toolbelt" //"the Chief Engineer's toolbelt", because "Chief Engineer's toolbelt" is not a proper noun
desc = "Holds tools, looks snazzy."
icon_state = "utilitybelt_ce"
item_state = "utility_ce"
/obj/item/weapon/storage/belt/utility/chief/full/PopulateContents()
new /obj/item/weapon/screwdriver/power(src)
new /obj/item/weapon/crowbar/power(src)
new /obj/item/weapon/weldingtool/experimental(src)//This can be changed if this is too much
new /obj/item/device/multitool(src)
new /obj/item/stack/cable_coil(src,30,pick("red","yellow","orange"))
new /obj/item/weapon/extinguisher/mini(src)
new /obj/item/device/analyzer(src)
//much roomier now that we've managed to remove two tools
/obj/item/weapon/storage/belt/utility/full/PopulateContents()
new /obj/item/weapon/screwdriver(src)
new /obj/item/weapon/wrench(src)
new /obj/item/weapon/weldingtool(src)
new /obj/item/weapon/crowbar(src)
new /obj/item/weapon/wirecutters(src)
new /obj/item/device/multitool(src)
new /obj/item/stack/cable_coil(src,30,pick("red","yellow","orange"))
/obj/item/weapon/storage/belt/utility/full/engi/PopulateContents()
new /obj/item/weapon/screwdriver(src)
new /obj/item/weapon/wrench(src)
new /obj/item/weapon/weldingtool/largetank(src)
new /obj/item/weapon/crowbar(src)
new /obj/item/weapon/wirecutters(src)
new /obj/item/device/multitool(src)
new /obj/item/stack/cable_coil(src,30,pick("red","yellow","orange"))
/obj/item/weapon/storage/belt/utility/atmostech/PopulateContents()
new /obj/item/weapon/screwdriver(src)
new /obj/item/weapon/wrench(src)
new /obj/item/weapon/weldingtool(src)
new /obj/item/weapon/crowbar(src)
new /obj/item/weapon/wirecutters(src)
new /obj/item/device/t_scanner(src)
new /obj/item/weapon/extinguisher/mini(src)
/obj/item/weapon/storage/belt/utility/servant/PopulateContents()
new /obj/item/weapon/screwdriver/brass(src)
new /obj/item/weapon/wirecutters/brass(src)
new /obj/item/weapon/wrench/brass(src)
new /obj/item/weapon/crowbar/brass(src)
new /obj/item/weapon/weldingtool/experimental/brass(src)
new /obj/item/device/multitool(src)
new /obj/item/stack/cable_coil(src, 30, "yellow")
/obj/item/weapon/storage/belt/medical
name = "medical belt"
desc = "Can hold various medical equipment."
icon_state = "medicalbelt"
item_state = "medical"
max_w_class = WEIGHT_CLASS_BULKY
can_hold = list(
/obj/item/device/healthanalyzer,
/obj/item/weapon/dnainjector,
/obj/item/weapon/reagent_containers/dropper,
/obj/item/weapon/reagent_containers/glass/beaker,
/obj/item/weapon/reagent_containers/glass/bottle,
/obj/item/weapon/reagent_containers/pill,
/obj/item/weapon/reagent_containers/syringe,
/obj/item/weapon/lighter,
/obj/item/weapon/storage/fancy/cigarettes,
/obj/item/weapon/storage/pill_bottle,
/obj/item/stack/medical,
/obj/item/device/flashlight/pen,
/obj/item/weapon/extinguisher/mini,
/obj/item/weapon/reagent_containers/hypospray,
/obj/item/device/sensor_device,
/obj/item/device/radio,
/obj/item/clothing/gloves/,
/obj/item/weapon/lazarus_injector,
/obj/item/weapon/bikehorn/rubberducky,
/obj/item/clothing/mask/surgical,
/obj/item/clothing/mask/breath,
/obj/item/clothing/mask/breath/medical,
/obj/item/weapon/surgical_drapes, //for true paramedics
/obj/item/weapon/scalpel,
/obj/item/weapon/circular_saw,
/obj/item/weapon/surgicaldrill,
/obj/item/weapon/retractor,
/obj/item/weapon/cautery,
/obj/item/weapon/hemostat,
/obj/item/device/geiger_counter,
/obj/item/clothing/neck/stethoscope,
/obj/item/weapon/stamp,
/obj/item/clothing/glasses,
/obj/item/weapon/wrench/medical,
/obj/item/clothing/mask/muzzle,
/obj/item/weapon/storage/bag/chemistry,
/obj/item/weapon/storage/bag/bio,
/obj/item/weapon/reagent_containers/blood,
/obj/item/weapon/tank/internals/emergency_oxygen
)
/obj/item/weapon/storage/belt/security
name = "security belt"
desc = "Can hold security gear like handcuffs and flashes."
icon_state = "securitybelt"
item_state = "security"//Could likely use a better one.
storage_slots = 5
max_w_class = WEIGHT_CLASS_NORMAL //Because the baton wouldn't fit otherwise. - Neerti
can_hold = list(
/obj/item/weapon/melee/baton,
/obj/item/weapon/melee/classic_baton,
/obj/item/weapon/grenade,
/obj/item/weapon/reagent_containers/spray/pepper,
/obj/item/weapon/restraints/handcuffs,
/obj/item/device/assembly/flash/handheld,
/obj/item/clothing/glasses,
/obj/item/ammo_casing/shotgun,
/obj/item/ammo_box,
/obj/item/weapon/reagent_containers/food/snacks/donut,
/obj/item/weapon/reagent_containers/food/snacks/donut/jelly,
/obj/item/weapon/kitchen/knife/combat,
/obj/item/device/flashlight/seclite,
/obj/item/weapon/melee/classic_baton/telescopic,
/obj/item/device/radio,
/obj/item/clothing/gloves/,
/obj/item/weapon/restraints/legcuffs/bola
)
content_overlays = TRUE
/obj/item/weapon/storage/belt/security/full/PopulateContents()
new /obj/item/weapon/reagent_containers/spray/pepper(src)
new /obj/item/weapon/restraints/handcuffs(src)
new /obj/item/weapon/grenade/flashbang(src)
new /obj/item/device/assembly/flash/handheld(src)
new /obj/item/weapon/melee/baton/loaded(src)
update_icon()
/obj/item/weapon/storage/belt/mining
name = "explorer's webbing"
desc = "A versatile chest rig, cherished by miners and hunters alike."
icon_state = "explorer1"
item_state = "explorer1"
storage_slots = 6
w_class = WEIGHT_CLASS_BULKY
max_w_class = WEIGHT_CLASS_BULKY //Pickaxes are big.
max_combined_w_class = 20 //Not an issue with this whitelist, probably.
can_hold = list(
/obj/item/weapon/crowbar,
/obj/item/weapon/screwdriver,
/obj/item/weapon/weldingtool,
/obj/item/weapon/wirecutters,
/obj/item/weapon/wrench,
/obj/item/device/flashlight,
/obj/item/stack/cable_coil,
/obj/item/device/analyzer,
/obj/item/weapon/extinguisher/mini,
/obj/item/device/radio,
/obj/item/clothing/gloves,
/obj/item/weapon/resonator,
/obj/item/device/mining_scanner,
/obj/item/weapon/pickaxe,
/obj/item/stack/sheet/animalhide,
/obj/item/stack/sheet/sinew,
/obj/item/stack/sheet/bone,
/obj/item/weapon/lighter,
/obj/item/weapon/storage/fancy/cigarettes,
/obj/item/weapon/reagent_containers/food/drinks/bottle,
/obj/item/stack/medical,
/obj/item/weapon/kitchen/knife,
/obj/item/weapon/reagent_containers/hypospray,
/obj/item/device/gps,
/obj/item/weapon/storage/bag/ore,
/obj/item/weapon/survivalcapsule,
/obj/item/device/t_scanner/adv_mining_scanner,
/obj/item/weapon/reagent_containers/pill,
/obj/item/weapon/storage/pill_bottle,
/obj/item/weapon/ore,
/obj/item/weapon/reagent_containers/food/drinks,
/obj/item/organ/regenerative_core,
/obj/item/device/wormhole_jaunter,
/obj/item/weapon/storage/bag/plants,
/obj/item/stack/marker_beacon
)
/obj/item/weapon/storage/belt/mining/vendor
contents = newlist(/obj/item/weapon/survivalcapsule)
/obj/item/weapon/storage/belt/mining/alt
icon_state = "explorer2"
item_state = "explorer2"
/obj/item/weapon/storage/belt/mining/primitive
name = "hunter's belt"
desc = "A versatile belt, woven from sinew."
storage_slots = 5
icon_state = "ebelt"
item_state = "ebelt"
/obj/item/weapon/storage/belt/soulstone
name = "soul stone belt"
desc = "Designed for ease of access to the shards during a fight, as to not let a single enemy spirit slip away"
icon_state = "soulstonebelt"
item_state = "soulstonebelt"
storage_slots = 6
can_hold = list(
/obj/item/device/soulstone
)
/obj/item/weapon/storage/belt/soulstone/full/PopulateContents()
for(var/i in 1 to 6)
new /obj/item/device/soulstone(src)
/obj/item/weapon/storage/belt/champion
name = "championship belt"
desc = "Proves to the world that you are the strongest!"
icon_state = "championbelt"
item_state = "champion"
materials = list(MAT_GOLD=400)
storage_slots = 1
can_hold = list(
/obj/item/clothing/mask/luchador
)
/obj/item/weapon/storage/belt/military
name = "chest rig"
desc = "A set of tactical webbing worn by Syndicate boarding parties."
icon_state = "militarywebbing"
item_state = "militarywebbing"
max_w_class = WEIGHT_CLASS_SMALL
/obj/item/weapon/storage/belt/military/abductor
name = "agent belt"
desc = "A belt used by abductor agents."
icon = 'icons/obj/abductor.dmi'
icon_state = "belt"
item_state = "security"
/obj/item/weapon/storage/belt/military/abductor/full/PopulateContents()
new /obj/item/weapon/screwdriver/abductor(src)
new /obj/item/weapon/wrench/abductor(src)
new /obj/item/weapon/weldingtool/abductor(src)
new /obj/item/weapon/crowbar/abductor(src)
new /obj/item/weapon/wirecutters/abductor(src)
new /obj/item/device/multitool/abductor(src)
new /obj/item/stack/cable_coil(src,30,"white")
/obj/item/weapon/storage/belt/military/army
name = "army belt"
desc = "A belt used by military forces."
icon_state = "grenadebeltold"
item_state = "security"
/obj/item/weapon/storage/belt/military/assault
name = "assault belt"
desc = "A tactical assault belt."
icon_state = "assaultbelt"
item_state = "security"
storage_slots = 6
/obj/item/weapon/storage/belt/grenade
name = "grenadier belt"
desc = "A belt for holding grenades."
icon_state = "grenadebeltnew"
item_state = "security"
max_w_class = WEIGHT_CLASS_BULKY
display_contents_with_number = TRUE
storage_slots = 30
max_combined_w_class = 60 //needs to be this high
can_hold = list(
/obj/item/weapon/grenade,
/obj/item/weapon/screwdriver,
/obj/item/weapon/lighter,
/obj/item/device/multitool,
/obj/item/weapon/reagent_containers/food/drinks/bottle/molotov,
/obj/item/weapon/grenade/plastic/c4,
)
/obj/item/weapon/storage/belt/grenade/full/PopulateContents()
new /obj/item/weapon/grenade/flashbang(src)
new /obj/item/weapon/grenade/smokebomb(src)
new /obj/item/weapon/grenade/smokebomb(src)
new /obj/item/weapon/grenade/smokebomb(src)
new /obj/item/weapon/grenade/smokebomb(src)
new /obj/item/weapon/grenade/empgrenade(src)
new /obj/item/weapon/grenade/empgrenade(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/syndieminibomb/concussion/frag(src)
new /obj/item/weapon/grenade/gluon(src)
new /obj/item/weapon/grenade/gluon(src)
new /obj/item/weapon/grenade/gluon(src)
new /obj/item/weapon/grenade/gluon(src)
new /obj/item/weapon/grenade/chem_grenade/incendiary(src)
new /obj/item/weapon/grenade/chem_grenade/incendiary(src)
new /obj/item/weapon/grenade/chem_grenade/facid(src)
new /obj/item/weapon/grenade/syndieminibomb(src)
new /obj/item/weapon/grenade/syndieminibomb(src)
new /obj/item/weapon/screwdriver(src)
new /obj/item/device/multitool(src)
/obj/item/weapon/storage/belt/wands
name = "wand belt"
desc = "A belt designed to hold various rods of power. A veritable fanny pack of exotic magic."
icon_state = "soulstonebelt"
item_state = "soulstonebelt"
storage_slots = 6
can_hold = list(
/obj/item/weapon/gun/magic/wand
)
/obj/item/weapon/storage/belt/wands/full/PopulateContents()
new /obj/item/weapon/gun/magic/wand/death(src)
new /obj/item/weapon/gun/magic/wand/resurrection(src)
new /obj/item/weapon/gun/magic/wand/polymorph(src)
new /obj/item/weapon/gun/magic/wand/teleport(src)
new /obj/item/weapon/gun/magic/wand/door(src)
new /obj/item/weapon/gun/magic/wand/fireball(src)
for(var/obj/item/weapon/gun/magic/wand/W in contents) //All wands in this pack come in the best possible condition
W.max_charges = initial(W.max_charges)
W.charges = W.max_charges
/obj/item/weapon/storage/belt/janitor
name = "janibelt"
desc = "A belt used to hold most janitorial supplies."
icon_state = "janibelt"
item_state = "janibelt"
storage_slots = 6
max_w_class = WEIGHT_CLASS_BULKY // Set to this so the light replacer can fit.
can_hold = list(
/obj/item/weapon/grenade/chem_grenade,
/obj/item/device/lightreplacer,
/obj/item/device/flashlight,
/obj/item/weapon/reagent_containers/spray,
/obj/item/weapon/soap,
/obj/item/weapon/holosign_creator,
/obj/item/key/janitor,
/obj/item/clothing/gloves
)
/obj/item/weapon/storage/belt/bandolier
name = "bandolier"
desc = "A bandolier for holding shotgun ammunition."
icon_state = "bandolier"
item_state = "bandolier"
storage_slots = 18
display_contents_with_number = TRUE
can_hold = list(
/obj/item/ammo_casing/shotgun
)
/obj/item/weapon/storage/belt/holster
name = "shoulder holster"
desc = "A holster to carry a handgun and ammo. WARNING: Badasses only."
icon_state = "holster"
item_state = "holster"
storage_slots = 3
max_w_class = WEIGHT_CLASS_NORMAL
can_hold = list(
/obj/item/weapon/gun/ballistic/automatic/pistol,
/obj/item/weapon/gun/ballistic/revolver,
/obj/item/ammo_box,
)
alternate_worn_layer = UNDER_SUIT_LAYER
/obj/item/weapon/storage/belt/holster/full/PopulateContents()
new /obj/item/weapon/gun/ballistic/revolver/detective(src)
new /obj/item/ammo_box/c38(src)
new /obj/item/ammo_box/c38(src)
/obj/item/weapon/storage/belt/fannypack
name = "fannypack"
desc = "A dorky fannypack for keeping small items in."
icon_state = "fannypack_leather"
item_state = "fannypack_leather"
storage_slots = 3
max_w_class = WEIGHT_CLASS_SMALL
/obj/item/weapon/storage/belt/fannypack/black
name = "black fannypack"
icon_state = "fannypack_black"
item_state = "fannypack_black"
/obj/item/weapon/storage/belt/fannypack/red
name = "red fannypack"
icon_state = "fannypack_red"
item_state = "fannypack_red"
/obj/item/weapon/storage/belt/fannypack/purple
name = "purple fannypack"
icon_state = "fannypack_purple"
item_state = "fannypack_purple"
/obj/item/weapon/storage/belt/fannypack/blue
name = "blue fannypack"
icon_state = "fannypack_blue"
item_state = "fannypack_blue"
/obj/item/weapon/storage/belt/fannypack/orange
name = "orange fannypack"
icon_state = "fannypack_orange"
item_state = "fannypack_orange"
/obj/item/weapon/storage/belt/fannypack/white
name = "white fannypack"
icon_state = "fannypack_white"
item_state = "fannypack_white"
/obj/item/weapon/storage/belt/fannypack/green
name = "green fannypack"
icon_state = "fannypack_green"
item_state = "fannypack_green"
/obj/item/weapon/storage/belt/fannypack/pink
name = "pink fannypack"
icon_state = "fannypack_pink"
item_state = "fannypack_pink"
/obj/item/weapon/storage/belt/fannypack/cyan
name = "cyan fannypack"
icon_state = "fannypack_cyan"
item_state = "fannypack_cyan"
/obj/item/weapon/storage/belt/fannypack/yellow
name = "yellow fannypack"
icon_state = "fannypack_yellow"
item_state = "fannypack_yellow"
/obj/item/weapon/storage/belt/sabre
name = "sabre sheath"
desc = "An ornate sheath designed to hold an officer's blade."
icon_state = "sheath"
item_state = "sheath"
storage_slots = 1
rustle_jimmies = FALSE
w_class = WEIGHT_CLASS_BULKY
max_w_class = WEIGHT_CLASS_BULKY
can_hold = list(
/obj/item/weapon/melee/sabre
)
/obj/item/weapon/storage/belt/sabre/examine(mob/user)
..()
if(contents.len)
to_chat(user, "<span class='notice'>Alt-click it to quickly draw the blade.</span>")
/obj/item/weapon/storage/belt/sabre/AltClick(mob/user)
if(!ishuman(user) || !user.canUseTopic(src, be_close=TRUE))
return
if(contents.len)
var/obj/item/I = contents[1]
user.visible_message("[user] takes [I] out of [src].", "<span class='notice'>You take [I] out of [src].</span>",\
)
user.put_in_hands(I)
update_icon()
else
to_chat(user, "[src] is empty.")
/obj/item/weapon/storage/belt/sabre/update_icon()
icon_state = "sheath"
item_state = "sheath"
if(contents.len)
icon_state += "-sabre"
item_state += "-sabre"
if(loc && isliving(loc))
var/mob/living/L = loc
L.regenerate_icons()
..()
/obj/item/weapon/storage/belt/sabre/PopulateContents()
new /obj/item/weapon/melee/sabre(src)
update_icon()

View File

@@ -40,6 +40,11 @@
W.setDir(dir)
qdel(src)
/obj/structure/chair/ratvar_act()
var/obj/structure/chair/brass/B = new(get_turf(src))
B.setDir(dir)
qdel(src)
/obj/structure/chair/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/wrench) && !(flags_1&NODECONSTRUCT_1))
playsound(src.loc, W.usesound, 50, 1)
@@ -331,3 +336,34 @@
desc = "You sit in this. Either by will or force. Looks REALLY uncomfortable."
icon_state = "chairold"
item_chair = null
/obj/structure/chair/brass
name = "brass chair"
desc = "A spinny chair made of brass. It looks uncomfortable."
icon_state = "brass_chair"
max_integrity = 150
buildstacktype = /obj/item/stack/tile/brass
buildstackamount = 1
/obj/structure/chair/brass/Destroy()
STOP_PROCESSING(SSfastprocess, src)
. = ..()
/obj/structure/chair/brass/process()
spin()
playsound(src, 'sound/effects/servostep.ogg', 50, FALSE)
/obj/structure/chair/brass/ratvar_act()
return
/obj/structure/chair/brass/AltClick(mob/living/user)
if(!user.canUseTopic(src, be_close = TRUE))
return
if(!isprocessing)
user.visible_message("<span class='notice'>[user] spins [src] around, and Ratvarian technology keeps it spinning FOREVER.</span>", \
"<span class='notice'>Automated spinny chairs. The pinnacle of Ratvarian technology.</span>")
START_PROCESSING(SSfastprocess, src)
else
user.visible_message("<span class='notice'>[user] stops [src]'s uncontrollable spinning.</span>", \
"<span class='notice'>You grab [src] and stop its wild spinning.</span>")
STOP_PROCESSING(SSfastprocess, src)

View File

@@ -13,6 +13,8 @@
if(do_after(user, 20, target = src))
to_chat(user, "<span class='notice'>You successfully [anchored ? "unwrench" : "wrench"] [src].</span>")
anchored = !anchored
else
return ..()
/obj/structure/dresser/deconstruct(disassembled = TRUE)
new /obj/item/stack/sheet/mineral/wood (get_turf(src), 10)

View File

@@ -10,6 +10,10 @@
var/obj/item/extinguisher/stored_extinguisher
var/opened = 0
/obj/structure/extinguisher_cabinet/examine(mob/user)
..()
to_chat(user, "<span class='notice'>Alt-click to [opened ? "close":"open"] it.</span>")
/obj/structure/extinguisher_cabinet/New(loc, ndir, building)
..()
if(building)

View File

@@ -13,6 +13,10 @@
var/buildstacktype = /obj/item/stack/sheet/metal
var/buildstackamount = 0
/obj/structure/reflector/examine(mob/user)
..()
to_chat(user, "<span class='notice'>Alt-click to adjust its direction.</span>")
/obj/structure/reflector/bullet_act(obj/item/projectile/P)
var/turf/reflector_turf = get_turf(src)
var/turf/reflect_turf