Merge remote-tracking branch 'upstream/master' into fix-cqc

# Conflicts:
#	code/game/objects/items.dm
This commit is contained in:
Fox McCloud
2019-04-07 19:54:14 -04:00
1409 changed files with 1712308 additions and 63928 deletions
@@ -192,7 +192,7 @@ var/global/list/image/splatter_cache = list()
icon = 'icons/effects/blood.dmi'
icon_state = "gibbl5"
random_icon_states = list("gib1", "gib2", "gib3", "gib4", "gib5", "gib6")
noclear = TRUE
no_clear = TRUE
var/fleshcolor = "#FFFFFF"
/obj/effect/decal/cleanable/blood/gibs/update_icon()
@@ -221,18 +221,11 @@ var/global/list/image/splatter_cache = list()
/obj/effect/decal/cleanable/blood/gibs/core
random_icon_states = list("gibmid1", "gibmid2", "gibmid3")
/obj/effect/decal/cleanable/blood/gibs/Initialize()
. = ..()
reagents.add_reagent("liquidgibs", 5)
scoop_reagents = list("liquidgibs" = 5)
/obj/effect/decal/cleanable/blood/gibs/cleangibs //most ironic name ever...
/obj/effect/decal/cleanable/blood/gibs/cleangibs/Initialize() //no reagent!
. = ..()
reagents.remove_reagent("liquidgibs",5)
scoop_reagents = null
/obj/effect/decal/cleanable/blood/gibs/proc/streak(var/list/directions)
set waitfor = 0
@@ -15,10 +15,7 @@
icon = 'icons/obj/objects.dmi'
icon_state = "ash"
anchored = TRUE
/obj/effect/decal/cleanable/ash/Initialize()
. = ..()
reagents.add_reagent("ash", 10)
scoop_reagents = list("ash" = 10)
/obj/effect/decal/cleanable/dirt
name = "dirt"
@@ -40,11 +37,8 @@
/obj/effect/decal/cleanable/dirt/blackpowder
name = "black powder"
mouse_opacity = TRUE
noscoop = TRUE
/obj/effect/decal/cleanable/dirt/blackpowder/Initialize()
. = ..()
reagents.add_reagent("blackpowder", 40) // size 2 explosion when activated
no_scoop = TRUE
scoop_reagents = list("blackpowder" = 40) // size 2 explosion when activated
/obj/effect/decal/cleanable/flour
name = "flour"
@@ -90,7 +84,8 @@
icon_state = "cobweb1"
burntime = 1
/obj/effect/decal/cleanable/cobweb/fire_act()
/obj/effect/decal/cleanable/cobweb/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
qdel(src)
/obj/effect/decal/cleanable/molten_object
@@ -126,22 +121,15 @@
icon = 'icons/effects/blood.dmi'
icon_state = "vomit_1"
random_icon_states = list("vomit_1", "vomit_2", "vomit_3", "vomit_4")
noclear = TRUE
/obj/effect/decal/cleanable/vomit/Initialize()
. = ..()
reagents.add_reagent("vomit", 5)
no_clear = TRUE
scoop_reagents = list("vomit" = 5)
/obj/effect/decal/cleanable/vomit/green
name = "green vomit"
desc = "It's all gummy. Ew."
icon_state = "gvomit_1"
random_icon_states = list("gvomit_1", "gvomit_2", "gvomit_3", "gvomit_4")
/obj/effect/decal/cleanable/vomit/green/Initialize()
. = ..()
reagents.remove_reagent("vomit", 5)
reagents.add_reagent("green_vomit", 5)
scoop_reagents = list("green_vomit" = 5)
/obj/effect/decal/cleanable/tomato_smudge
name = "tomato smudge"
@@ -188,10 +176,7 @@
icon = 'icons/effects/effects.dmi'
icon_state = "flour"
color = "#D5820B"
/obj/effect/decal/cleanable/fungus/Initialize()
. = ..()
reagents.add_reagent("fungus", 10)
scoop_reagents = list("fungus" = 10)
/obj/effect/decal/cleanable/confetti //PARTY TIME!
name = "confetti"
+1 -38
View File
@@ -1,8 +1,6 @@
/obj/effect/decal/cleanable
anchored = TRUE
var/list/random_icon_states = list()
var/noscoop = FALSE //if it has this, don't let it be scooped up
var/noclear = FALSE //if it has this, don't delete it when its' scooped up
/obj/effect/decal/cleanable/proc/can_bloodcrawl_in()
return FALSE
@@ -10,7 +8,6 @@
/obj/effect/decal/cleanable/New()
if(random_icon_states && length(src.random_icon_states) > 0)
src.icon_state = pick(src.random_icon_states)
create_reagents(100)
if(smooth)
queue_smooth(src)
queue_smooth_neighbors(src)
@@ -19,38 +16,4 @@
/obj/effect/decal/cleanable/Destroy()
if(smooth)
queue_smooth_neighbors(src)
return ..()
/obj/effect/decal/cleanable/attackby(obj/item/W as obj, mob/user as mob,)
if(istype(W, /obj/item/reagent_containers/glass) || istype(W, /obj/item/reagent_containers/food/drinks))
if(src.reagents && W.reagents && !noscoop)
if(!src.reagents.total_volume)
to_chat(user, "<span class='notice'>There isn't enough [src] to scoop up!</span>")
return
if(W.reagents.total_volume >= W.reagents.maximum_volume)
to_chat(user, "<span class='notice'>[W] is full!</span>")
return
to_chat(user, "<span class='notice'>You scoop the [src] into [W]!</span>")
reagents.trans_to(W, reagents.total_volume)
if(!reagents.total_volume && !noclear) //scooped up all of it
qdel(src)
return
if(is_hot(W)) //todo: make heating a reagent holder proc
if(istype(W, /obj/item/clothing/mask/cigarette))
return
else
src.reagents.chem_temp += 15
src.reagents.handle_reactions()
to_chat(user, "<span class='notice'>You heat [src] with [W]!</span>")
/obj/effect/decal/cleanable/ex_act()
if(reagents)
for(var/datum/reagent/R in reagents.reagent_list)
R.on_ex_act()
..()
/obj/effect/decal/cleanable/fire_act()
if(reagents)
reagents.chem_temp += 30
reagents.handle_reactions()
..()
return ..()
+14
View File
@@ -16,6 +16,7 @@
anchored = TRUE
layer = TURF_DECAL_LAYER
icon = 'icons/turf/snow.dmi'
icon_state = "snow"
/obj/effect/decal/snow/clean/edge
icon_state = "snow_corner"
@@ -53,3 +54,16 @@
/obj/effect/decal/straw/edge
icon_state = "strawscatterededge"
/obj/effect/decal/ants
name = "space ants"
desc = "A bunch of space ants."
icon = 'icons/goonstation/effects/effects.dmi'
icon_state = "spaceants"
scoop_reagents = list("ants" = 20)
/obj/effect/decal/ants/Initialize(mapload)
. = ..()
var/scale = (rand(2, 10) / 10) + (rand(0, 5) / 100)
transform = matrix(transform, scale, scale, MATRIX_SCALE)
setDir(pick(NORTH, SOUTH, EAST, WEST))
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,126 @@
/////////////////////////////////////////////
// Chem smoke
/////////////////////////////////////////////
/obj/effect/particle_effect/chem_smoke
icon = 'icons/goonstation/effects/64x64.dmi'
icon_state = "smoke"
density = FALSE
opacity = FALSE
layer = ABOVE_MOB_LAYER
animate_movement = NO_STEPS
var/matrix/first = matrix()
var/matrix/second = matrix()
var/matrix/third = matrix()
var/first_scale = 0.1
var/second_scale = 5
var/third_scale = 2
var/spread_amount = 96
/obj/effect/particle_effect/chem_smoke/New(location, chem_color)
..(location)
color = chem_color
pixel_x += -16 + rand(-3, 3)
pixel_y += -16 + rand(-3, 3)
first = turn(first, rand(-90, 90))
first.Scale(first_scale, first_scale)
transform = first
second = first
second.Scale(second_scale, second_scale)
third.Scale(third_scale, third_scale)
animate(src,transform = second, time = 5, alpha = 200)
animate(transform = third, time = 20, pixel_y = rand(-spread_amount, spread_amount), pixel_x = rand(-spread_amount, spread_amount), alpha = 1)
QDEL_IN(src, 26)
/obj/effect/particle_effect/chem_smoke/small
first_scale = 0.05
second_scale = 2.5
third_scale = 1
spread_amount = 48
/datum/effect_system/smoke_spread/chem
var/obj/chemholder
var/list/smoked_atoms = list()
/datum/effect_system/smoke_spread/chem/New()
..()
chemholder = new
chemholder.create_reagents(1000)
chemholder.reagents.set_reacting(FALSE) // Just in case
/datum/effect_system/smoke_spread/chem/Destroy()
QDEL_NULL(chemholder)
smoked_atoms.Cut()
return ..()
/datum/effect_system/smoke_spread/chem/set_up(datum/reagents/carry = null, loca, silent = FALSE)
if(isturf(loca))
location = loca
else
location = get_turf(loca)
carry.copy_to(chemholder, carry.total_volume)
carry.clear_reagents()
if(!silent)
var/contained = ""
for(var/reagent in carry.reagent_list)
contained += " [reagent] "
if(contained)
contained = "\[[contained]\]"
var/area/A = get_area(location)
var/where = "[A.name] | [location.x], [location.y]"
var/whereLink = "<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[location.x];Y=[location.y];Z=[location.z]'>[where]</a>"
if(carry && carry.my_atom)
if(carry.my_atom.fingerprintslast)
var/mob/M = get_mob_by_key(carry.my_atom.fingerprintslast)
var/more = ""
if(M)
more = " "
msg_admin_attack("A chemical smoke reaction has taken place in ([whereLink])[contained]. Last associated key is [carry.my_atom.fingerprintslast][more].", ATKLOG_FEW)
log_game("A chemical smoke reaction has taken place in ([where])[contained]. Last associated key is [carry.my_atom.fingerprintslast].")
else
msg_admin_attack("A chemical smoke reaction has taken place in ([whereLink]). No associated key.", ATKLOG_FEW)
log_game("A chemical smoke reaction has taken place in ([where])[contained]. No associated key.")
else
msg_admin_attack("A chemical smoke reaction has taken place in ([whereLink]). No associated key. CODERS: carry.my_atom may be null.", ATKLOG_FEW)
log_game("A chemical smoke reaction has taken place in ([where])[contained]. No associated key. CODERS: carry.my_atom may be null.")
/datum/effect_system/smoke_spread/chem/start(effect_range = 2)
set waitfor = FALSE
var/color = mix_color_from_reagents(chemholder.reagents.reagent_list)
for(var/x in 0 to 99)
for(var/i = 0, i < rand(2, 6), i++)
if(effect_range < 3)
new /obj/effect/particle_effect/chem_smoke/small(location, color)
else
new /obj/effect/particle_effect/chem_smoke(location, color)
if(x % 10 == 0) //Once every 10 ticks.
INVOKE_ASYNC(src, .proc/SmokeEm, effect_range)
sleep(1)
qdel(src)
/datum/effect_system/smoke_spread/chem/proc/SmokeEm(effect_range = 2)
for(var/atom/A in view(effect_range, get_turf(location)))
if(istype(A, /obj/effect/particle_effect)) // Don't impact particle effects, as there can be hundreds of them in a small area. Also, we don't want smoke particles adding themselves to this list. Major performance issue.
continue
if(A in smoked_atoms)
continue
smoked_atoms += A
chemholder.reagents.reaction(A)
if(iscarbon(A))
var/mob/living/carbon/C = A
if(C.can_breathe_gas())
chemholder.reagents.copy_to(C, chemholder.reagents.total_volume)
@@ -76,15 +76,18 @@
F = new /obj/effect/particle_effect/foam(T, metal)
F.amount = amount
if(!metal)
F.create_reagents(15)
F.create_reagents(25)
if(reagents)
for(var/datum/reagent/R in reagents.reagent_list)
F.reagents.add_reagent(R.id, min(R.volume, 3), R.data, reagents.chem_temp)
F.reagents.add_reagent(R.id, min(R.volume, 5), R.data, reagents.chem_temp)
F.color = mix_color_from_reagents(reagents.reagent_list)
// foam disolves when heated
// except metal foams
/obj/effect/particle_effect/foam/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
/obj/effect/particle_effect/foam/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) //Don't heat the reagents inside
return
/obj/effect/particle_effect/foam/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) // overriden to prevent weird behaviors with heating reagents inside
if(!metal && prob(max(0, exposed_temperature - 475)))
flick("[icon_state]-disolve", src)
@@ -146,14 +149,14 @@
F.amount = amount
if(!metal) // don't carry other chemicals if a metal foam
F.create_reagents(15)
F.create_reagents(25)
if(carried_reagents)
for(var/id in carried_reagents)
if(banned_reagents.Find("[id]"))
continue
var/datum/reagent/reagent_volume = carried_reagents[id]
F.reagents.add_reagent(id, min(reagent_volume, 3), null, temperature)
F.reagents.add_reagent(id, min(reagent_volume, 5), null, temperature)
F.color = mix_color_from_reagents(F.reagents.reagent_list)
else
F.reagents.add_reagent("cleaner", 1)
@@ -178,8 +181,9 @@
air_update_turf(1)
/obj/structure/foamedmetal/Destroy()
air_update_turf(1)
return ..()
var/turf/T = get_turf(src)
. = ..()
T.air_update_turf(TRUE)
/obj/structure/foamedmetal/Move()
var/turf/T = loc
@@ -207,99 +207,4 @@
return 1
/datum/effect_system/smoke_spread/sleeping
effect_type = /obj/effect/particle_effect/smoke/sleeping
/////////////////////////////////////////////
// Chem smoke
/////////////////////////////////////////////
/obj/effect/particle_effect/smoke/chem
icon = 'icons/effects/chemsmoke.dmi'
opacity = 0
lifetime = 10
/datum/effect_system/smoke_spread/chem
effect_type = /obj/effect/particle_effect/smoke/chem
var/obj/chemholder
/datum/effect_system/smoke_spread/chem/New()
..()
chemholder = new/obj()
var/datum/reagents/R = new/datum/reagents(500)
chemholder.reagents = R
R.my_atom = chemholder
/datum/effect_system/smoke_spread/chem/Destroy()
QDEL_NULL(chemholder)
return ..()
/datum/effect_system/smoke_spread/chem/set_up(datum/reagents/carry = null, n = 5, c = 0, loca, direct, silent = 0)
if(n > 20)
n = 20
number = n
cardinals = c
if(isturf(loca))
location = loca
else
location = get_turf(loca)
if(direct)
direction = direct
carry.copy_to(chemholder, carry.total_volume)
if(!silent)
var/contained = ""
for(var/reagent in carry.reagent_list)
contained += " [reagent] "
if(contained)
contained = "\[[contained]\]"
var/area/A = get_area(location)
var/where = "[A.name] | [location.x], [location.y]"
var/whereLink = "<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[location.x];Y=[location.y];Z=[location.z]'>[where]</a>"
if(carry && carry.my_atom)
if(carry.my_atom.fingerprintslast)
var/mob/M = get_mob_by_key(carry.my_atom.fingerprintslast)
var/more = ""
if(M)
more = " "
msg_admin_attack("A chemical smoke reaction has taken place in ([whereLink])[contained]. Last associated key is [carry.my_atom.fingerprintslast][more].", ATKLOG_FEW)
log_game("A chemical smoke reaction has taken place in ([where])[contained]. Last associated key is [carry.my_atom.fingerprintslast].")
else
msg_admin_attack("A chemical smoke reaction has taken place in ([whereLink]). No associated key.", ATKLOG_FEW)
log_game("A chemical smoke reaction has taken place in ([where])[contained]. No associated key.")
else
msg_admin_attack("A chemical smoke reaction has taken place in ([whereLink]). No associated key. CODERS: carry.my_atom may be null.", ATKLOG_FEW)
log_game("A chemical smoke reaction has taken place in ([where])[contained]. No associated key. CODERS: carry.my_atom may be null.")
/datum/effect_system/smoke_spread/chem/start(effect_range = 2)
var/color = mix_color_from_reagents(chemholder.reagents.reagent_list)
var/obj/effect/particle_effect/smoke/chem/smokeholder = new effect_type(location)
for(var/atom/A in view(effect_range, smokeholder))
chemholder.reagents.reaction(A)
if(iscarbon(A))
var/mob/living/carbon/C = A
if(C.can_breathe_gas())
chemholder.reagents.copy_to(C, chemholder.reagents.total_volume)
qdel(smokeholder)
for(var/i=0, i<number, i++)
if(holder)
location = get_turf(holder)
var/obj/effect/particle_effect/smoke/chem/S = new effect_type(location)
if(!direction)
if(cardinals)
S.direction = pick(cardinal)
else
S.direction = pick(alldirs)
else
S.direction = direction
S.steps = pick(0,1,1,1,2,2,2,3)
if(color)
S.icon += color // give the smoke color, if it has any to begin with
else
// if no color, just use the old smoke icon
S.icon = 'icons/effects/96x96.dmi'
S.icon_state = "smoke"
S.process()
effect_type = /obj/effect/particle_effect/smoke/sleeping
+36 -4
View File
@@ -6,13 +6,45 @@
icon = 'icons/effects/effects.dmi'
burn_state = LAVA_PROOF | FIRE_PROOF
resistance_flags = INDESTRUCTIBLE
anchored = 1
can_be_hit = FALSE
/obj/effect/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, attack_dir)
return
/obj/effect/fire_act()
return
/obj/effect/attack_hulk(mob/living/carbon/human/user, does_attack_animation = FALSE)
return FALSE
return FALSE
/obj/effect/decal
var/no_scoop = FALSE //if it has this, don't let it be scooped up
var/no_clear = FALSE //if it has this, don't delete it when its' scooped up
var/list/scoop_reagents = null
/obj/effect/decal/Initialize(mapload)
. = ..()
if(scoop_reagents)
create_reagents(100)
reagents.add_reagent_list(scoop_reagents)
/obj/effect/decal/attackby(obj/item/I, mob/user)
if(istype(I, /obj/item/reagent_containers/glass) || istype(I, /obj/item/reagent_containers/food/drinks))
scoop(I, user)
/obj/effect/decal/proc/scoop(obj/item/I, mob/user)
if(reagents && I.reagents && !no_scoop)
if(!reagents.total_volume)
to_chat(user, "<span class='notice'>There isn't enough [src] to scoop up!</span>")
return
if(I.reagents.total_volume >= I.reagents.maximum_volume)
to_chat(user, "<span class='notice'>[I] is full!</span>")
return
to_chat(user, "<span class='notice'>You scoop [src] into [I]!</span>")
reagents.trans_to(I, reagents.total_volume)
if(!reagents.total_volume && !no_clear) //scooped up all of it
qdel(src)
/obj/effect/decal/ex_act()
if(reagents)
for(var/datum/reagent/R in reagents.reagent_list)
R.on_ex_act()
..()
+22 -5
View File
@@ -7,19 +7,36 @@
opacity = 0
density = 1
unacidable = 1
var/lifetime = 30 SECONDS
/obj/effect/forcefield/New()
..()
if(lifetime)
QDEL_IN(src, lifetime)
/obj/effect/forcefield/CanAtmosPass(turf/T)
return !density
/obj/effect/forcefield/wizard
var/mob/wizard
/obj/effect/forcefield/wizard/Initialize(mapload, mob/summoner)
. = ..()
wizard = summoner
/obj/effect/forcefield/wizard/CanPass(atom/movable/mover, turf/target)
if(mover == wizard)
return TRUE
return FALSE
///////////Mimewalls///////////
/obj/effect/forcefield/mime
icon_state = "empty"
name = "invisible wall"
desc = "You have a bad feeling about this."
var/lifetime = 30 SECONDS
/obj/effect/forcefield/mime/New()
..()
if(lifetime)
QDEL_IN(src, lifetime)
/obj/effect/forcefield/mime/advanced
name = "invisible blockade"
desc = "You might be here a while."
lifetime = 60 SECONDS
+1
View File
@@ -180,6 +180,7 @@
qdel(src)
/obj/structure/glowshroom/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
..()
if(exposed_temperature > 300)
endurance -= 5
CheckEndurance()
+13 -2
View File
@@ -88,6 +88,10 @@
emergencyresponseteamspawn += loc
qdel(src)
if("Syndicate Officer")
syndicateofficer += loc
qdel(src)
GLOB.landmarks_list += src
return 1
@@ -246,8 +250,8 @@
qdel(src)
/obj/effect/landmark/costume/sexyclown/New()
new /obj/item/clothing/mask/gas/sexyclown(src.loc)
new /obj/item/clothing/under/sexyclown(src.loc)
new /obj/item/clothing/mask/gas/clown_hat/sexy(loc)
new /obj/item/clothing/under/rank/clown/sexy(loc)
qdel(src)
/obj/effect/landmark/costume/sexymime/New()
@@ -286,3 +290,10 @@
..()
var/turf/simulated/T = get_turf(src)
T.burn_tile()
/obj/effect/landmark/battle_mob_point
name = "Nanomob Battle Avatar Spawn Point"
/obj/effect/landmark/free_golem_spawn
name = "Free Golem Spawn Point"
+9
View File
@@ -53,6 +53,15 @@
if(isliving(victim))
victim.Weaken(stun_time)
/obj/effect/mine/depot
name = "sentry mine"
/obj/effect/mine/depot/mineEffect(mob/living/victim)
var/area/syndicate_depot/core/depotarea = areaMaster
if(istype(depotarea))
if(depotarea.mine_triggered(victim))
explosion(loc, 1, 0, 0, 1) // devastate the tile you are on, but leave everything else untouched
/obj/effect/mine/dnascramble
name = "Radiation Mine"
var/radiation_amount
+1
View File
@@ -66,4 +66,5 @@
desc = "A portal capable of bypassing bluespace interference."
icon_state = "portal1"
failchance = 0
precision = 0
ignore_tele_proof_area_setting = TRUE
+142
View File
@@ -0,0 +1,142 @@
/obj/effect/snowcloud
name = "snow cloud"
desc = "Let it snow, let it snow, let it snow!"
icon_state = "snowcloud"
layer = FLY_LAYER
anchored = TRUE
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
var/obj/machinery/snow_machine/parent_machine
/obj/effect/snowcloud/New(turf, obj/machinery/snow_machine/SM)
..()
processing_objects.Add(src)
if(SM && istype(SM))
parent_machine = SM
/obj/effect/snowcloud/Destroy()
processing_objects.Remove(src)
return ..()
/obj/effect/snowcloud/process()
if(QDELETED(parent_machine))
parent_machine = null
var/turf/T = get_turf(src)
if(isspaceturf(T))
qdel(src)
return
var/turf_hotness
if(issimulatedturf(T))
var/turf/simulated/S = T
turf_hotness = S.air.temperature
if(turf_hotness > T0C && prob(10 * (turf_hotness - T0C))) //Cloud disappears if it's too warm
qdel(src)
return
if(!parent_machine || !parent_machine.active || parent_machine.stat & NOPOWER) //All reasons a cloud could dissipate
if(prob(10))
qdel(src)
return
try_to_snow()
try_to_spread_cloud()
parent_machine.affect_turf_temperature(T, 0.25 * parent_machine.cooling_speed)
/obj/effect/snowcloud/proc/try_to_snow()
var/turf/T = get_turf(src)
if(locate(/obj/effect/snow, T))
return
if(issimulatedturf(T))
var/turf/simulated/S = T
if(prob(75 + S.air.temperature - T0C)) //Colder turf = more chance of snow
return
new /obj/effect/snow(T)
/obj/effect/snowcloud/proc/try_to_spread_cloud()
if(prob(95 - parent_machine.cooling_speed * 5)) //10 / 15 / 20 / 25% chance to spawn a new cloud
return
var/list/random_dirs = shuffle(cardinal)
for(var/potential in random_dirs)
var/turf/T = get_turf(get_step(src, potential))
if(isspaceturf(T) || T.density)
continue
if(!T.CanAtmosPass(T))
continue
if(parent_machine.make_snowcloud(T))
return
//Snow stuff below
/obj/effect/snow
desc = "Perfect for making snow angels, or throwing at other people!"
icon = 'icons/effects/effects.dmi'
icon_state = "snow"
layer = ABOVE_ICYOVERLAY_LAYER
anchored = TRUE
/obj/effect/snow/New()
processing_objects.Add(src)
icon_state = "snow[rand(1,6)]"
..()
/obj/effect/snow/Destroy()
processing_objects.Remove(src)
return ..()
/obj/effect/snow/process()
var/turf/T = get_turf(src)
if(isspaceturf(T))
qdel(src)
return
else if(issimulatedturf(T))
var/turf/simulated/S = T
if(S.air.temperature <= T0C)
return
if(prob(10 + S.air.temperature - T0C))
qdel(src)
/obj/effect/snow/attack_hand(mob/living/carbon/human/user)
if(!istype(user)) //Nonhumans don't have the balls to fight in the snow
return
user.changeNext_move(CLICK_CD_MELEE)
var/obj/item/snowball/SB = new(get_turf(user))
user.put_in_hands(SB)
to_chat(user, "<span class='notice'>You scoop up some snow and make \a [SB]!</span>")
/obj/effect/snow/attackby(obj/item/I, mob/user)
if(istype(I, /obj/item/shovel))
var/obj/item/shovel/S = I
user.visible_message("<span class='notice'>[user] is clearing away [src]...</span>", "<span class='notice'>You begin clearing away [src]...</span>", "<span class='warning'>You hear a wettish digging sound.</span>")
playsound(loc, S.usesound, 50, TRUE)
if(!do_after(user, 50 * S.toolspeed, target = src))
return
user.visible_message("<span class='notice'>[user] clears away [src]!</span>", "<span class='notice'>You clear away [src]!</span>")
qdel(src)
else
return ..()
/obj/effect/snow/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
qdel(src)
/obj/effect/snow/ex_act(severity)
if(severity == 3 && prob(50))
return
qdel(src)
/obj/item/snowball
name = "snowball"
desc = "Get ready for a snowball fight!"
force = 0
throwforce = 10
icon_state = "snowball"
damtype = STAMINA
/obj/item/snowball/throw_impact(atom/target)
..()
qdel(src)
/obj/item/snowball/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
qdel(src)
/obj/item/snowball/ex_act(severity)
qdel(src)
+207 -31
View File
@@ -98,6 +98,7 @@
/obj/item/poster/random_contraband = 10,
/obj/item/crowbar = 10,
/obj/item/crowbar/red = 10,
/obj/item/restraints/handcuffs/toy = 5,
/obj/item/extinguisher = 90,
//obj/item/gun/projectile/revolver/russian = 1, //disabled until lootdrop is a proper world proc.
/obj/item/hand_labeler = 10,
@@ -152,7 +153,8 @@
/obj/item/toy/cards/deck/syndicate = 2,
/obj/item/storage/secure/briefcase/syndie = 2,
/obj/item/storage/fancy/cigarettes/cigpack_syndicate = 2,
"" = 70
/obj/item/storage/pill_bottle/fakedeath = 2,
"" = 68
)
/obj/effect/spawner/lootdrop/crate_spawner // for ruins
@@ -164,44 +166,218 @@
"" = 80,
)
/obj/effect/spawner/lootdrop/trade_sol_rare
name = "trader rare item spawner"
lootdoubles = 0
/obj/effect/spawner/lootdrop/trade_sol/
name = "trader item spawner"
lootcount = 6
lootdoubles = 1
color = "#00FFFF"
/obj/effect/spawner/lootdrop/trade_sol/civ
name = "1. civilian gear"
loot = list(
/obj/item/card/emag_broken = 2,
/obj/item/defibrillator/compact/loaded = 2,
/obj/item/gun/energy/laser/retro = 2,
/obj/item/rcd/combat = 1,
/obj/item/rcd = 2,
// General utility gear
/obj/item/storage/belt/utility/full/multitool = 150,
/obj/item/clothing/gloves/combat = 100,
/obj/item/clothing/glasses/welding = 50,
/obj/item/reagent_containers/spray/cleaner = 100,
/obj/item/clothing/shoes/magboots = 50,
/obj/item/soap = 50,
/obj/item/clothing/under/syndicate/combat = 50,
/obj/item/soap/syndie = 50,
/obj/item/lighter/zippo/gonzofist = 50,
/obj/item/stack/nanopaste = 50,
/obj/item/clothing/under/psyjump = 50,
/obj/item/immortality_talisman = 50,
/obj/item/grenade/clusterbuster/smoke = 50
)
/obj/effect/spawner/lootdrop/trade_sol_common
name = "trader common item spawner"
lootdoubles = 0
color = "#00FFFF"
/obj/effect/spawner/lootdrop/trade_sol/minerals
name = "2. minerals"
lootdoubles = 1
loot = list(
/obj/item/tank/anesthetic = 2,
/obj/item/weldingtool/hugetank = 2,
/obj/item/pickaxe/diamond = 1,
/obj/item/spacepod_equipment/weaponry/mining_laser = 1,
/obj/item/paicard = 2,
/obj/item/gun/projectile/automatic/pistol = 2,
/obj/item/megaphone = 2,
/obj/item/stock_parts/capacitor = 1,
/obj/item/stock_parts/cell/high = 1,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/matter_bin = 1,
/obj/item/stock_parts/micro_laser = 1,
/obj/item/stock_parts/scanning_module = 1,
/obj/item/stack/spacecash/c200 = 1,
/obj/item/airlock_electronics = 1,
/obj/item/gun/energy/kinetic_accelerator = 1,
/obj/item/pizzabox = 3,
// Common stuff you get from mining which isn't already present on the station
// Note that plasma and derived hybrid materials are NOT included in this list because plasma is the trader's objective!
/obj/item/stack/sheet/mineral/silver = 50,
/obj/item/stack/sheet/mineral/gold = 50,
/obj/item/stack/sheet/mineral/uranium = 50,
/obj/item/stack/sheet/mineral/diamond = 50,
/obj/item/stack/sheet/mineral/titanium = 50,
/obj/item/stack/sheet/plasteel = 50,
// Hybrid stuff you could in theory get from mining
/obj/item/stack/sheet/titaniumglass = 50,
// Rare stuff you can't get from mining
/obj/item/stack/sheet/mineral/tranquillite = 50,
/obj/item/stack/sheet/mineral/bananium = 50,
/obj/item/stack/sheet/wood = 50,
/obj/item/stack/sheet/plastic = 50,
/obj/item/stack/sheet/mineral/sandstone = 50
)
/obj/effect/spawner/lootdrop/trade_sol/minerals/New()
if(loot && loot.len)
for(var/i = lootcount, i > 0, i--)
if(!loot.len)
break
var/lootspawn = pickweight(loot)
if(!lootdoubles)
loot.Remove(lootspawn)
if(lootspawn)
var/obj/item/stack/sheet/S = new lootspawn(get_turf(src))
S.amount = 25
qdel(src)
/obj/effect/spawner/lootdrop/trade_sol/donksoft
name = "3. donksoft gear"
loot = list(
// Donksoft guns
/obj/item/gun/projectile/automatic/c20r/toy = 50,
/obj/item/gun/projectile/automatic/l6_saw/toy = 50,
/obj/item/gun/projectile/automatic/toy/pistol = 100,
/obj/item/gun/projectile/automatic/toy/pistol/enforcer = 50,
/obj/item/gun/projectile/shotgun/toy = 50,
/obj/item/gun/projectile/shotgun/toy/crossbow = 50,
/obj/item/gun/projectile/shotgun/toy/tommygun = 50
)
/obj/effect/spawner/lootdrop/trade_sol/sci
name = "4. science gear"
loot = list(
// Robotics
/obj/item/mmi/robotic_brain = 50, // Low-value, but we want to encourage getting more players back in the round.
/obj/item/assembly/signaler/anomaly = 50, // anomaly core
/obj/item/mecha_parts/mecha_equipment/weapon/energy/xray = 25, // mecha x-ray laser
/obj/item/mecha_parts/mecha_equipment/teleporter/precise = 25, // upgraded mecha teleporter
/obj/item/autoimplanter = 50,
// Research / Experimentor
/obj/item/paper/researchnotes = 150, // papers that give random R&D levels
// Xenobio
/obj/item/slimepotion/sentience = 50, // Low-value, but we want to encourage getting more players back in the round.
/obj/item/slimepotion/transference = 50
)
/obj/effect/spawner/lootdrop/trade_sol/med
name = "5. medical gear"
loot = list(
// Medchem
/obj/item/storage/pill_bottle/random_meds/labelled = 100, // random medical and other chems
/obj/item/reagent_containers/glass/bottle/reagent/omnizine = 50,
/obj/item/reagent_containers/glass/bottle/reagent/strange_reagent = 50,
// Surgery
/obj/item/scalpel/laser/manager = 100,
/obj/item/organ/internal/heart/gland/ventcrawling = 50,
/obj/item/organ/internal/heart/gland/heals = 50,
// Genetics Research (should really be under science, but I was stuck for items to put in medical)
/obj/item/dnainjector/regenerate = 50, // regeneration
/obj/item/dnainjector/nobreath = 50,
/obj/item/dnainjector/telemut = 50,
// Virology
/obj/item/reagent_containers/glass/bottle/regeneration = 50,
/obj/item/reagent_containers/glass/bottle/sensory_restoration = 50
)
/obj/effect/spawner/lootdrop/trade_sol/sec
name = "6. security gear"
loot = list(
// Melee
/obj/item/kitchen/knife/combat = 50,
/obj/item/fluff/desolate_baton_kit = 50, // permission granted by Desolate to use their fluff kit in this loot table
// Utility
/obj/item/storage/belt/military/assault = 50,
/obj/item/clothing/mask/gas/sechailer/swat = 50,
/obj/item/clothing/glasses/thermal = 50, // see heat-source mobs through walls. Less powerful than already-available xray.
// Ranged weapons
/obj/item/storage/box/enforcer_rubber = 50,
/obj/item/storage/box/enforcer_lethal = 50,
/obj/item/gun/projectile/shotgun/automatic/combat = 50, // combat shotgun, between riot and bulldog in robustness. Not illegal, can be obtained from cargo.
/obj/item/gun/projectile/shotgun/automatic/dual_tube = 50, // cycler shotgun, not normally available to crew
// Cluster grenades
/obj/item/grenade/clusterbuster = 50, // cluster flashbang
/obj/item/grenade/clusterbuster/teargas = 50
)
/obj/effect/spawner/lootdrop/trade_sol/eng
name = "7. eng gear"
loot = list(
/obj/item/storage/belt/utility/chief/full = 25,
/obj/item/rcd/combat = 25,
/obj/item/rpd/bluespace = 25,
/obj/item/tank/emergency_oxygen/double/full = 25,
/obj/item/slimepotion/speed = 25,
/obj/item/storage/backpack/holding = 25,
/obj/item/clothing/glasses/meson/night = 25, // NV mesons
/obj/item/clothing/glasses/material = 25, // shows objects, but not mobs, through walls
/obj/item/grenade/clusterbuster/metalfoam = 25 // cluster metal foam grenade
)
/obj/effect/spawner/lootdrop/trade_sol/largeitem
name = "8. largeitem"
lootcount = 1
loot = list(
/obj/machinery/disco = 20,
/obj/mecha/combat/durand/old = 20
)
/obj/effect/spawner/lootdrop/trade_sol/vehicle
name = "9. vehicle"
loot = list(
/obj/vehicle/motorcycle = 50,
/obj/vehicle/snowmobile = 50,
/obj/vehicle/snowmobile/blue = 50,
/obj/vehicle/space/speedbike/red = 50,
/obj/vehicle/space/speedbike = 50
)
/obj/effect/spawner/lootdrop/trade_sol/vehicle/New()
if(!loot.len)
return
var/lootspawn = pickweight(loot)
var/obj/vehicle/V = new lootspawn(get_turf(src))
if(V.keytype)
new V.keytype(get_turf(src))
qdel(src)
/obj/effect/spawner/lootdrop/trade_sol/serv
name = "10. service gear"
loot = list(
// Mining
/obj/item/mining_voucher = 100,
/obj/item/pickaxe/drill/jackhammer = 100,
/obj/item/gun/energy/kinetic_accelerator/experimental = 100,
/obj/item/borg/upgrade/modkit/aoe/turfs/andmobs = 100,
// Botanist
/obj/item/seeds/random/labelled = 100,
// Clown
/obj/item/grenade/clusterbuster/honk = 100,
/obj/item/bikehorn/golden = 100,
// Bartender
/obj/item/storage/box/bartender_rare_ingredients_kit = 100,
// Chef
/obj/item/storage/box/chef_rare_ingredients_kit = 100
// It would be nice to also have items for other service jobs: Mime, Librarian, Chaplain, etc
)
/obj/effect/spawner/lootdrop/three_course_meal
name = "three course meal spawner"
lootcount = 3
@@ -159,6 +159,7 @@
/obj/effect/spawner/random_spawners/syndicate/trap/pizzabomb
name = "50pc trap pizza"
result = list(/obj/item/pizzabox/meat = 1,
/obj/item/pizzabox/hawaiian = 1,
/obj/item/pizza_bomb/autoarm = 1)
/obj/effect/spawner/random_spawners/syndicate/trap/medbot
@@ -169,7 +170,7 @@
/obj/effect/spawner/random_spawners/syndicate/trap/mine
name = "50pc trap landmine"
result = list(/datum/nothing = 1,
/obj/effect/mine/explosive = 1)
/obj/effect/mine/depot = 1)
/obj/effect/spawner/random_spawners/syndicate/trap/documents
name = "66pc trapped documents"
@@ -188,7 +189,6 @@
// Loot schema: costumes, toys, useless gimmick items, trapped items
result = list(/datum/nothing = 13,
/obj/item/storage/toolbox/syndicate = 1,
/obj/item/storage/toolbox/syndicate/trapped = 1,
/obj/item/storage/fancy/cigarettes/cigpack_syndicate = 1,
/obj/item/toy/cards/deck/syndicate = 1,
/obj/item/storage/secure/briefcase/syndie = 1,
@@ -279,7 +279,7 @@
/obj/item/clothing/glasses/thermal = 1,
/obj/item/chameleon = 1,
/obj/item/reagent_containers/hypospray/autoinjector/stimulants = 1,
/obj/item/storage/box/syndie_kit/atmosgasgrenades = 1,
/obj/item/storage/box/syndie_kit/atmosn2ogrenades = 1,
/obj/item/grenade/plastic/x4 = 1)
+2 -1
View File
@@ -69,6 +69,7 @@
qdel(src)
/obj/structure/spider/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
..()
if(exposed_temperature > 300)
health -= 5
healthcheck()
@@ -176,7 +177,7 @@
return
var/obj/machinery/atmospherics/unary/vent_pump/exit_vent = pick(vents)
if(prob(50))
visible_message("<B>[src] scrambles into the ventillation ducts!</B>", \
visible_message("<B>[src] scrambles into the ventilation ducts!</B>", \
"<span class='notice'>You hear something squeezing through the ventilation ducts.</span>")
spawn(rand(20,60))
@@ -211,3 +211,21 @@
pixel_x = rand(-4,4)
pixel_y = rand(-4,4)
animate(src, pixel_y = pixel_y + 32, alpha = 0, time = 25)
/obj/effect/temp_visual/shockwave
name = "shockwave"
icon = 'icons/goonstation/effects/64x64.dmi'
icon_state = "shockwave"
randomdir = FALSE
pixel_y = -16
pixel_x = -16
duration = 20
/obj/effect/temp_visual/implosion
name = "implosion"
icon = 'icons/goonstation/effects/64x64.dmi'
icon_state = "implosion"
randomdir = FALSE
pixel_y = -16
pixel_x = -16
duration = 20
+3 -3
View File
@@ -5,8 +5,8 @@
epicenter = get_turf(epicenter.loc)
if(log)
message_admins("EMP with size ([heavy_range], [light_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])": ] [ADMIN_COORDJMP(epicenter)]</a>")
log_game("EMP with size ([heavy_range], [light_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])" : ] [COORD(epicenter)]")
message_admins("EMP with size ([heavy_range], [light_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])": ""] [ADMIN_COORDJMP(epicenter)]</a>")
log_game("EMP with size ([heavy_range], [light_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])" : ""] [COORD(epicenter)]")
if(heavy_range > 1)
new/obj/effect/temp_visual/emp/pulse(epicenter)
@@ -15,7 +15,7 @@
light_range = heavy_range
for(var/mob/M in range(heavy_range, epicenter))
M << 'sound/effects/EMPulse.ogg'
M << 'sound/effects/empulse.ogg'
for(var/atom/T in range(light_range, epicenter))
var/distance = get_dist(epicenter, T)
if(distance < 0)
+7 -4
View File
@@ -1,6 +1,6 @@
//TODO: Flash range does nothing currently
/proc/explosion(turf/epicenter, devastation_range, heavy_impact_range, light_impact_range, flash_range, adminlog = 1, ignorecap = 0, flame_range = 0 ,silent = 0, smoke = 1, cause = null)
/proc/explosion(turf/epicenter, devastation_range, heavy_impact_range, light_impact_range, flash_range, adminlog = 1, ignorecap = 0, flame_range = 0 ,silent = 0, smoke = 1, cause = null, breach = TRUE)
src = null //so we don't abort once src is deleted
epicenter = get_turf(epicenter)
@@ -25,8 +25,8 @@
var/list/cached_exp_block = list()
if(adminlog)
message_admins("Explosion with size ([devastation_range], [heavy_impact_range], [light_impact_range], [flame_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])" : ] [ADMIN_COORDJMP(epicenter)] ")
log_game("Explosion with size ([devastation_range], [heavy_impact_range], [light_impact_range], [flame_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])" : ] [COORD(epicenter)] ")
message_admins("Explosion with size ([devastation_range], [heavy_impact_range], [light_impact_range], [flame_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])" : ""] [ADMIN_COORDJMP(epicenter)] ")
log_game("Explosion with size ([devastation_range], [heavy_impact_range], [light_impact_range], [flame_range]) in area [epicenter.loc.name] [cause ? "(Cause: [cause])" : ""] [COORD(epicenter)] ")
// Play sounds; we want sounds to be different depending on distance so we will manually do it ourselves.
// Stereo users will also hear the direction of the explosion!
@@ -132,7 +132,10 @@
if(AM && AM.simulated)
AM.ex_act(dist)
CHECK_TICK
T.ex_act(dist)
if(breach)
T.ex_act(dist)
else
T.ex_act(3)
CHECK_TICK
//--- THROW ITEMS AROUND ---
+33 -17
View File
@@ -16,6 +16,7 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
var/inhand_y_dimension = 32
can_be_hit = FALSE
suicidal_hands = TRUE
var/r_speed = 1.0
var/health = null
@@ -35,6 +36,8 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
var/list/actions = list() //list of /datum/action's that this item has.
var/list/actions_types = list() //list of paths of action datums to give to the item on New().
var/list/action_icon = list() //list of icons-sheets for a given action to override the icon.
var/list/action_icon_state = list() //list of icon states for a given action to override the icon_state.
var/list/materials = list()
//Since any item can now be a piece of clothing, this has to be put here so all items share it.
@@ -100,7 +103,7 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
/obj/item/New()
..()
for(var/path in actions_types)
new path(src)
new path(src, action_icon[path], action_icon_state[path])
if(!hitsound)
if(damtype == "fire")
@@ -143,16 +146,6 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
/obj/item/blob_act()
qdel(src)
//user: The mob that is suiciding
//damagetype: The type of damage the item will inflict on the user
//BRUTELOSS = 1
//FIRELOSS = 2
//TOXLOSS = 4
//OXYLOSS = 8
//Output a creative message and then return the damagetype done
/obj/item/proc/suicide_act(mob/user)
return
/obj/item/verb/move_to_top()
set name = "Move To Top"
set category = null
@@ -206,6 +199,9 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
msg += "*--------*"
to_chat(user, msg)
/obj/item/afterattack(atom/target, mob/user, proximity, params)
SEND_SIGNAL(src, COMSIG_ITEM_AFTERATTACK, target, user, proximity, params)
..()
/obj/item/attack_hand(mob/user as mob, pickupfireoverride = FALSE)
if(!user) return 0
@@ -250,10 +246,10 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
else
if(isliving(loc))
return 0
pickup(user)
add_fingerprint(user)
user.put_in_active_hand(src)
if(pickup(user)) // Pickup succeeded
user.put_in_active_hand(src)
return 1
/obj/item/attack_alien(mob/user as mob)
@@ -306,6 +302,25 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
else if(S.can_be_inserted(src))
S.handle_item_insertion(src)
else if(istype(I, /obj/item/stack/tape_roll))
if(istype(src, /obj/item/storage)) //Don't tape the bag if we can put the duct tape inside it instead
var/obj/item/storage/bag = src
if(bag.can_be_inserted(I))
return ..()
var/obj/item/stack/tape_roll/TR = I
var/list/clickparams = params2list(params)
var/x_offset = text2num(clickparams["icon-x"])
var/y_offset = text2num(clickparams["icon-y"])
if(GetComponent(/datum/component/ducttape))
to_chat(user, "<span class='notice'>[src] already has some tape attached!</span>")
return
if(TR.use(1))
to_chat(user, "<span class='notice'>You apply some tape to [src].</span>")
AddComponent(/datum/component/ducttape, src, user, x_offset, y_offset)
anchored = TRUE
user.transfer_fingerprints_to(src)
else
to_chat(user, "<span class='notice'>You don't have enough tape to do that!</span>")
else
return ..()
@@ -329,7 +344,8 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
// called just as an item is picked up (loc is not yet changed)
/obj/item/proc/pickup(mob/user)
return
SEND_SIGNAL(src, COMSIG_ITEM_PICKUP, user)
return TRUE
// called when this item is removed from a storage item, which is passed on as S. The loc variable is already set to the new destination before this is called.
/obj/item/proc/on_exit_storage(obj/item/storage/S as obj)
@@ -507,10 +523,10 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
itempush = 0 // too light to push anything
return A.hitby(src, 0, itempush)
/obj/item/throw_at(atom/target, range, speed, mob/thrower, spin=1, diagonals_first = 0, datum/callback/callback)
/obj/item/throw_at(atom/target, range, speed, mob/thrower, spin=1, diagonals_first = 0, datum/callback/callback, force)
thrownby = thrower
callback = CALLBACK(src, .proc/after_throw, callback) //replace their callback with our own
. = ..(target, range, speed, thrower, spin, diagonals_first, callback)
. = ..(target, range, speed, thrower, spin, diagonals_first, callback, force)
/obj/item/proc/after_throw(datum/callback/callback)
if(callback) //call the original callback
+19
View File
@@ -68,6 +68,22 @@
..()
qdel(src)
//free golem blueprints, like permit but can claim as much as needed
/obj/item/areaeditor/golem
name = "Golem Land Claim"
desc = "Used to define new areas in space."
fluffnotice = "Praise the Liberator!"
/obj/item/areaeditor/golem/attack_self(mob/user)
. = ..()
var/area/A = get_area()
if(get_area_type() == AREA_STATION)
. += "<p>According to the [src], you are now in <b>\"[sanitize(A.name)]\"</b>.</p>"
var/datum/browser/popup = new(user, "blueprints", "[src]", 700, 500)
popup.set_content(.)
popup.open()
onclose(usr, "blueprints")
//Station blueprints!!!
/obj/item/areaeditor/blueprints
@@ -252,6 +268,8 @@
return BORDER_BETWEEN
if(istype(T2, /turf/simulated/wall))
return BORDER_2NDTILE
if(istype(T2, /turf/simulated/mineral))
return BORDER_2NDTILE
if(!istype(T2, /turf/simulated))
return BORDER_BETWEEN
@@ -312,3 +330,4 @@
name = "station schematics"
desc = "A digital copy of the station blueprints stored in your memory."
fluffnotice = "Intellectual Property of Nanotrasen. For use in engineering cyborgs only. Wipe from memory upon departure from the station."
+2 -1
View File
@@ -51,7 +51,8 @@
light("<span class='notice'>[user] tilts [C] and lights [src] with it.</span>")
/obj/item/candle/fire_act()
/obj/item/candle/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
if(!lit)
light() //honk
+2 -2
View File
@@ -18,7 +18,7 @@
if(user.a_intent == INTENT_HELP || pushed_over)
return ..()
user.visible_message("<span class='warning'>[user] pushes over [src]!</span>", "<span class='danger'>You push over [src]!</span>")
playsound(src, 'sound/weapons/Genhit.ogg', 50, 1)
playsound(src, 'sound/weapons/genhit.ogg', 50, 1)
push_over()
/obj/item/cardboard_cutout/proc/push_over()
@@ -85,7 +85,7 @@
return
if(pushed_over)
to_chat(user, "<span class='warning'>Right [src] first!</span>")
return
return
if(!new_appearance || !crayon)
return
if(!do_after(user, 10, FALSE, src, TRUE))
+1 -1
View File
@@ -23,7 +23,7 @@
/obj/item/toy/crayon/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] is jamming the [name] up [user.p_their()] nose and into [user.p_their()] brain. It looks like [user.p_theyre()] trying to commit suicide.</span>")
return (BRUTELOSS|OXYLOSS)
return BRUTELOSS|OXYLOSS
/obj/item/toy/crayon/New()
..()
@@ -78,6 +78,8 @@
playsound(loc, 'sound/goonstation/machines/printer_thermal.ogg', 50, 1)
sleep(10)
user.put_in_hands(R)
else
return ..()
/obj/item/autopsy_scanner/attack_self(mob/user)
var/scan_data = ""
@@ -45,7 +45,7 @@
eject_all()
playsound(get_turf(src), 'sound/effects/pop.ogg', 100, 1, -6)
QDEL_NULL(active_dummy)
to_chat(usr, "<span class='notice'>You deactivate \the [src].</span>")
to_chat(usr, "<span class='notice'>You deactivate [src].</span>")
var/obj/effect/overlay/T = new/obj/effect/overlay(get_turf(src))
T.icon = 'icons/effects/effects.dmi'
flick("emppulse",T)
@@ -58,7 +58,7 @@
var/obj/effect/dummy/chameleon/C = new/obj/effect/dummy/chameleon(usr.loc)
C.activate(O, usr, saved_icon, saved_icon_state, saved_overlays, saved_underlays, src)
qdel(O)
to_chat(usr, "<span class='notice'>You activate \the [src].</span>")
to_chat(usr, "<span class='notice'>You activate [src].</span>")
var/obj/effect/overlay/T = new/obj/effect/overlay(get_turf(src))
T.icon = 'icons/effects/effects.dmi'
flick("emppulse",T)
@@ -148,3 +148,102 @@
/obj/effect/dummy/chameleon/Destroy()
master.disrupt(0)
return ..()
/obj/item/borg_chameleon
name = "cyborg chameleon projector"
icon = 'icons/obj/device.dmi'
icon_state = "shield0"
item_state = "electronic"
w_class = WEIGHT_CLASS_SMALL
var/active = FALSE
var/activationCost = 300
var/activationUpkeep = 50
var/disguise = "landmate"
var/mob/living/silicon/robot/syndicate/saboteur/S
/obj/item/borg_chameleon/Destroy()
if(S)
S.cham_proj = null
return ..()
/obj/item/borg_chameleon/dropped(mob/user)
. = ..()
disrupt(user)
/obj/item/borg_chameleon/equipped(mob/user)
. = ..()
disrupt(user)
/obj/item/borg_chameleon/attack_self(mob/living/silicon/robot/syndicate/saboteur/user)
if(user && user.cell && user.cell.charge > activationCost)
if(isturf(user.loc))
toggle(user)
else
to_chat(user, "<span class='warning'>You can't use [src] while inside something!</span>")
else
to_chat(user, "<span class='warning'>You need at least [activationCost] charge in your cell to use [src]!</span>")
/obj/item/borg_chameleon/proc/toggle(mob/living/silicon/robot/syndicate/saboteur/user)
if(active)
playsound(src, 'sound/effects/pop.ogg', 100, 1, -6)
to_chat(user, "<span class='notice'>You deactivate [src].</span>")
deactivate(user)
else
to_chat(user, "<span class='notice'>You activate [src].</span>")
var/start = user.filters.len
var/X
var/Y
var/rsq
var/i
var/f
for(i in 1 to 7)
do
X = 60 * rand() - 30
Y = 60 * rand() - 30
rsq = X * X + Y * Y
while(rsq < 100 || rsq > 900)
user.filters += filter(type = "wave", x = X, y = Y, size = rand() * 2.5 + 0.5, offset = rand())
for(i in 1 to 7)
f = user.filters[start+i]
animate(f, offset = f:offset, time = 0, loop = 3, flags = ANIMATION_PARALLEL)
animate(offset = f:offset - 1, time = rand() * 20 + 10)
if(do_after(user, 50, target = user) && user.cell.use(activationCost))
playsound(src, 'sound/effects/bamf.ogg', 100, 1, -6)
to_chat(user, "<span class='notice'>You are now disguised as a Nanotrasen engineering cyborg.</span>")
activate(user)
else
to_chat(user, "<span class='warning'>The chameleon field fizzles.</span>")
do_sparks(3, FALSE, user)
for(i in 1 to min(7, user.filters.len)) // removing filters that are animating does nothing, we gotta stop the animations first
f = user.filters[start + i]
animate(f)
user.filters = null
/obj/item/borg_chameleon/process()
if(S)
if(!S.cell || !S.cell.use(activationUpkeep))
disrupt(S)
else
return PROCESS_KILL
/obj/item/borg_chameleon/proc/activate(mob/living/silicon/robot/syndicate/saboteur/user)
processing_objects.Add(src)
S = user
user.base_icon = disguise
user.icon_state = disguise
user.cham_proj = src
active = TRUE
user.update_icons()
/obj/item/borg_chameleon/proc/deactivate(mob/living/silicon/robot/syndicate/saboteur/user)
processing_objects.Remove(src)
S = user
user.base_icon = initial(user.base_icon)
user.icon_state = initial(user.icon_state)
active = FALSE
user.update_icons()
/obj/item/borg_chameleon/proc/disrupt(mob/living/silicon/robot/syndicate/saboteur/user)
if(active)
to_chat(user, "<span class='danger'>Your chameleon field deactivates.</span>")
deactivate(user)
+69 -16
View File
@@ -17,7 +17,8 @@
var/last_used = 0 //last world.time it was used.
var/battery_panel = 0 //whether the flash can be modified with a cell or not
var/overcharged = 0 //if overcharged the flash will set people on fire then immediately burn out (does so even if it doesn't blind them).
var/can_overcharge = TRUE //set this to FALSE if you don't want your flash to be overcharge capable
var/use_sound = 'sound/weapons/flash.ogg'
/obj/item/flash/proc/clown_check(mob/user)
if(user && (CLUMSY in user.mutations) && prob(50))
@@ -26,19 +27,20 @@
return 1
/obj/item/flash/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/screwdriver))
if(battery_panel)
to_chat(user, "<span class='notice'>You close the battery compartment on the [src].</span>")
battery_panel = 0
else
to_chat(user, "<span class='notice'>You open the battery compartment on the [src].</span>")
battery_panel = 1
if(battery_panel && !overcharged)
if(istype(W, /obj/item/stock_parts/cell))
to_chat(user, "<span class='notice'>You jam the cell into battery compartment on the [src].</span>")
qdel(W)
overcharged = 1
overlays += "overcharge"
if(can_overcharge)
if(istype(W, /obj/item/screwdriver))
if(battery_panel)
to_chat(user, "<span class='notice'>You close the battery compartment on the [src].</span>")
battery_panel = 0
else
to_chat(user, "<span class='notice'>You open the battery compartment on the [src].</span>")
battery_panel = 1
if(battery_panel && !overcharged)
if(istype(W, /obj/item/stock_parts/cell))
to_chat(user, "<span class='notice'>You jam the cell into battery compartment on the [src].</span>")
qdel(W)
overcharged = 1
overlays += "overcharge"
/obj/item/flash/random/New()
..()
@@ -71,7 +73,7 @@
if(broken)
return 0
playsound(src.loc, 'sound/weapons/flash.ogg', 100, 1)
playsound(src.loc, use_sound, 100, 1)
flick("[initial(icon_state)]2", src)
times_used++
@@ -186,6 +188,57 @@
..()
new /obj/effect/temp_visual/borgflash(get_turf(src))
/obj/item/flash/cameraflash
name = "camera"
icon = 'icons/obj/items.dmi'
desc = "A polaroid camera. 10 photos left."
icon_state = "camera"
item_state = "electropack" //spelling, a coders worst enemy. This part gave me trouble for a while.
w_class = WEIGHT_CLASS_SMALL
slot_flags = SLOT_BELT
can_overcharge = FALSE
var/flash_max_charges = 5
var/flash_cur_charges = 5
var/charge_tick = 0
use_sound = 'sound/items/polaroid1.ogg'
/obj/item/flash/cameraflash/burn_out() //stops from burning out
return
/obj/item/flash/cameraflash/New()
..()
processing_objects.Add(src)
/obj/item/flash/cameraflash/Destroy()
processing_objects.Remove(src)
return ..()
/obj/item/flash/cameraflash/process() //this and the two parts above are part of the charge system.
charge_tick++
if(charge_tick < 10)
return FALSE
charge_tick = 0
flash_cur_charges = min(flash_cur_charges+1, flash_max_charges)
return TRUE
/obj/item/flash/cameraflash/attack(mob/living/M, mob/user)
if(flash_cur_charges > 0)
flash_cur_charges -= 1
to_chat(user, "[src] now has [flash_cur_charges] charge\s.")
..()
else
to_chat(user, "<span class='warning'>\The [src] needs time to recharge!</span>")
return
/obj/item/flash/cameraflash/attack_self(mob/living/carbon/user, flag = 0)
if(flash_cur_charges > 0)
flash_cur_charges -= 1
to_chat(user, "[src] now has [flash_cur_charges] charge\s.")
..()
else
to_chat(user, "<span class='warning'>\The [src] needs time to recharge!</span>")
return
/obj/item/flash/memorizer
name = "memorizer"
desc = "If you see this, you're not likely to remember it any time soon."
@@ -194,7 +247,7 @@
/obj/item/flash/armimplant
name = "photon projector"
desc = "A high-powered photon projector implant normally used for lighting purposes, but also doubles as a flashbulb weapon. Self-repair protocals fix the flashbulb if it ever burns out."
desc = "A high-powered photon projector implant normally used for lighting purposes, but also doubles as a flashbulb weapon. Self-repair protocols fix the flashbulb if it ever burns out."
var/flashcd = 20
var/overheat = 0
var/obj/item/organ/internal/cyberimp/arm/flash/I = null
+101 -107
View File
@@ -11,6 +11,7 @@
actions_types = list(/datum/action/item_action/toggle_light)
var/on = FALSE
var/brightness_on = 4 //luminosity when on
var/togglesound = 'sound/weapons/empty.ogg'
/obj/item/flashlight/Initialize()
. = ..()
@@ -35,7 +36,7 @@
return 0
on = !on
playsound(user, 'sound/weapons/empty.ogg', 100, 1)
playsound(user, togglesound, 100, 1)
update_brightness(user)
for(var/X in actions)
var/datum/action/A = X
@@ -83,6 +84,11 @@
else
return ..()
/obj/item/flashlight/extinguish_light()
if(on)
on = FALSE
update_brightness()
/obj/item/flashlight/pen
name = "penlight"
desc = "A pen-sized light, used by medical staff."
@@ -121,7 +127,7 @@
w_class = WEIGHT_CLASS_BULKY
flags = CONDUCT
materials = list()
on = 1
on = TRUE
// green-shaded desk lamp
@@ -141,7 +147,7 @@
attack_self(usr)
//Bananalamp
obj/item/flashlight/lamp/bananalamp
/obj/item/flashlight/lamp/bananalamp
name = "banana lamp"
desc = "Only a clown would think to make a ghetto banana-shaped lamp. Even has a goofy pullstring."
icon_state = "bananalamp"
@@ -153,22 +159,24 @@ obj/item/flashlight/lamp/bananalamp
/obj/item/flashlight/flare
name = "flare"
desc = "A red Nanotrasen issued flare. There are instructions on the side, it reads 'pull cord, make light'."
w_class = WEIGHT_CLASS_SMALL
brightness_on = 8 // Made it brighter (from 7 to 8).
light_color = "#ff0000" // changed colour to a more brighter red.
brightness_on = 8
light_color = "#ff0000"
icon_state = "flare"
item_state = "flare"
togglesound = 'sound/goonstation/misc/matchstick_light.ogg'
var/fuel = 0
var/on_damage = 7
var/produce_heat = 1500
var/fuel_lower = 800
var/fuel_upp = 1000
/obj/item/flashlight/flare/New()
fuel = rand(800, 1000) // Sorry for changing this so much but I keep under-estimating how long X number of ticks last in seconds.
fuel = rand(fuel_lower, fuel_upp)
..()
/obj/item/flashlight/flare/process()
var/turf/pos = get_turf(src)
if(pos)
if(pos && produce_heat)
pos.hotspot_expose(produce_heat, 5)
fuel = max(fuel - 1, 0)
if(!fuel || !on)
@@ -177,6 +185,10 @@ obj/item/flashlight/lamp/bananalamp
src.icon_state = "[initial(icon_state)]-empty"
processing_objects -= src
/obj/item/flashlight/flare/Destroy()
processing_objects.Remove(src)
return ..()
/obj/item/flashlight/flare/proc/turn_off()
on = 0
src.force = initial(src.force)
@@ -207,11 +219,87 @@ obj/item/flashlight/lamp/bananalamp
. = ..()
// All good, turn it on.
if(.)
user.visible_message("<span class='notice'>[user] activates the flare.</span>", "<span class='notice'>You pull the cord on the flare, activating it!</span>")
user.visible_message("<span class='notice'>[user] activates [src].</span>", "<span class='notice'>You activate [src].</span>")
src.force = on_damage
src.damtype = "fire"
processing_objects += src
// GLOWSTICKS
/obj/item/flashlight/flare/glowstick
name = "green glowstick"
desc = "A military-grade glowstick."
brightness_on = 4
color = LIGHT_COLOR_GREEN
icon_state = "glowstick"
item_state = "glowstick"
togglesound = 'sound/effects/bone_break_1.ogg'
produce_heat = 0
fuel_lower = 1600
fuel_upp = 2000
/obj/item/flashlight/flare/glowstick/Initialize()
light_color = color
..()
/obj/item/flashlight/flare/glowstick/update_icon()
item_state = "glowstick"
cut_overlays()
if(!fuel)
icon_state = "glowstick-empty"
cut_overlays()
update_brightness(0)
else if(on)
var/mutable_appearance/glowstick_overlay = mutable_appearance(icon, "glowstick-glow")
glowstick_overlay.color = color
add_overlay(glowstick_overlay)
item_state = "glowstick-on"
update_brightness(brightness_on)
else
icon_state = "glowstick"
cut_overlays()
/obj/item/flashlight/flare/glowstick/red
name = "red glowstick"
color = LIGHT_COLOR_RED
/obj/item/flashlight/flare/glowstick/blue
name = "blue glowstick"
color = LIGHT_COLOR_BLUE
/obj/item/flashlight/flare/glowstick/orange
name = "orange glowstick"
color = LIGHT_COLOR_ORANGE
/obj/item/flashlight/flare/glowstick/yellow
name = "yellow glowstick"
color = LIGHT_COLOR_YELLOW
/obj/item/flashlight/flare/glowstick/pink
name = "pink glowstick"
color = LIGHT_COLOR_PINK
/obj/item/flashlight/flare/glowstick/emergency
name = "emergency glowstick"
desc = "A cheap looking, mass produced glowstick. You can practically feel it was made on a tight budget."
color = LIGHT_COLOR_BLUE
fuel_lower = 30
fuel_upp = 90
/obj/item/flashlight/flare/glowstick/random
name = "random colored glowstick"
icon_state = "random_glowstick"
color = null
/obj/item/flashlight/flare/glowstick/random/Initialize()
..()
var/T = pick(typesof(/obj/item/flashlight/flare/glowstick) - /obj/item/flashlight/flare/glowstick/random - /obj/item/flashlight/flare/glowstick/emergency)
new T(loc)
return INITIALIZE_HINT_QDEL
/obj/item/flashlight/flare/extinguish_light()
visible_message("<span class='danger'>[src] dims slightly before scattering the shadows around it.</span>")
/obj/item/flashlight/flare/torch
name = "torch"
desc = "A torch fashioned from some leaves and a log."
@@ -232,7 +320,7 @@ obj/item/flashlight/lamp/bananalamp
brightness_on = 6
light_color = "#FFBF00"
materials = list()
on = 1 //Bio-luminesence has one setting, on.
on = TRUE //Bio-luminesence has one setting, on.
/obj/item/flashlight/slime/New()
set_light(brightness_on)
@@ -243,6 +331,9 @@ obj/item/flashlight/lamp/bananalamp
/obj/item/flashlight/slime/attack_self(mob/user)
return //Bio-luminescence does not toggle.
/obj/item/flashlight/slime/extinguish_light()
visible_message("<span class='danger'>[src] dims slightly before scattering the shadows around it.</span>")
/obj/item/flashlight/emp
origin_tech = "magnets=3;syndicate=1"
@@ -302,100 +393,3 @@ obj/item/flashlight/lamp/bananalamp
var/range = null
unacidable = TRUE
burn_state = LAVA_PROOF
/obj/item/flashlight/glowstick
name = "green glowstick"
desc = "A military-grade glowstick."
w_class = WEIGHT_CLASS_SMALL
brightness_on = 4
color = LIGHT_COLOR_GREEN
icon_state = "glowstick"
item_state = "glowstick"
var/fuel = 0
/obj/item/flashlight/glowstick/Initialize()
fuel = rand(1600, 2000)
light_color = color
. = ..()
/obj/item/flashlight/glowstick/Destroy()
processing_objects.Remove(src)
. = ..()
/obj/item/flashlight/glowstick/process()
fuel = max(fuel - 1, 0)
if(!fuel)
turn_off()
processing_objects.Remove(src)
update_icon()
/obj/item/flashlight/glowstick/proc/turn_off()
on = FALSE
update_icon()
/obj/item/flashlight/glowstick/update_icon()
item_state = "glowstick"
cut_overlays()
if(!fuel)
icon_state = "glowstick-empty"
cut_overlays()
update_brightness(0)
else if(on)
var/mutable_appearance/glowstick_overlay = mutable_appearance(icon, "glowstick-glow")
glowstick_overlay.color = color
add_overlay(glowstick_overlay)
item_state = "glowstick-on"
update_brightness(brightness_on)
else
icon_state = "glowstick"
cut_overlays()
/obj/item/flashlight/glowstick/attack_self(mob/user)
if(!fuel)
to_chat(user, "<span class='notice'>[src] is spent.</span>")
return
if(on)
to_chat(user, "<span class='notice'>[src] is already lit.</span>")
return
. = ..()
if(.)
user.visible_message("<span class='notice'>[user] cracks and shakes [src].</span>", "<span class='notice'>You crack and shake [src], turning it on!</span>")
activate()
/obj/item/flashlight/glowstick/proc/activate()
if(!on)
on = TRUE
processing_objects.Add(src)
update_icon()
/obj/item/flashlight/glowstick/red
name = "red glowstick"
color = LIGHT_COLOR_RED
/obj/item/flashlight/glowstick/blue
name = "blue glowstick"
color = LIGHT_COLOR_BLUE
/obj/item/flashlight/glowstick/orange
name = "orange glowstick"
color = LIGHT_COLOR_ORANGE
/obj/item/flashlight/glowstick/yellow
name = "yellow glowstick"
color = LIGHT_COLOR_YELLOW
/obj/item/flashlight/glowstick/pink
name = "pink glowstick"
color = LIGHT_COLOR_PINK
/obj/item/flashlight/glowstick/random
name = "random colored glowstick"
icon_state = "random_glowstick"
color = null
/obj/item/flashlight/glowstick/random/Initialize()
..()
var/T = pick(typesof(/obj/item/flashlight/glowstick) - /obj/item/flashlight/glowstick/random)
new T(loc)
return INITIALIZE_HINT_QDEL
@@ -0,0 +1,91 @@
/obj/item/handheld_defibrillator
name = "handheld defibrillator"
desc = "Used to restart stopped hearts."
icon = 'icons/goonstation/objects/objects.dmi'
lefthand_file = 'icons/goonstation/mob/inhands/items_lefthand.dmi'
righthand_file = 'icons/goonstation/mob/inhands/items_righthand.dmi'
icon_state = "defib-on"
item_state = "defib"
var/icon_base = "defib"
var/cooldown = FALSE
var/charge_time = 100
var/emagged = FALSE
/obj/item/handheld_defibrillator/emag_act(mob/user)
if(!emagged)
emagged = TRUE
desc += " The screen only shows the word KILL flashing over and over."
if(user)
to_chat(user, "<span class='warning'>you short out the safeties on [src]</span>")
else
emagged = FALSE
desc = "Used to restart stopped hearts."
if(user)
to_chat(user, "<span class='warning'>You restore the safeties on [src]</span>")
/obj/item/handheld_defibrillator/emp_act(severity)
if(emagged)
emagged = FALSE
desc = "Used to restart stopped hearts."
visible_message("<span class='notice'>[src] beeps: Safety protocols enabled!</span>")
playsound(get_turf(src), 'sound/machines/defib_saftyon.ogg', 50, 0)
else
emagged = TRUE
desc += " The screen only shows the word KILL flashing over and over."
visible_message("<span class='notice'>[src] beeps: Safety protocols disabled!</span>")
playsound(get_turf(src), 'sound/machines/defib_saftyoff.ogg', 50, 0)
/obj/item/handheld_defibrillator/attack(mob/living/carbon/human/H, mob/user)
if(!istype(H))
return ..()
if(cooldown)
to_chat(user, "<span class='warning'>[src] is still charging!</span>")
return
if(emagged || (H.health <= HEALTH_THRESHOLD_CRIT) || (H.undergoing_cardiac_arrest()))
user.visible_message("<span class='notice'>[user] shocks [H] with [src].</span>", "<span class='notice'>You shock [H] with [src].</span>")
add_attack_logs(user, H, "defibrillated with [src]")
playsound(user.loc, "sound/weapons/Egloves.ogg", 75, 1)
if(H.stat == DEAD)
to_chat(user, "<span class='danger'>[H] doesn't respond at all!</span>")
else
H.set_heartattack(FALSE)
var/total_damage = H.getBruteLoss() + H.getFireLoss() + H.getToxLoss()
if(H.health <= HEALTH_THRESHOLD_CRIT)
if(total_damage >= 90)
to_chat(user, "<span class='danger'>[H] looks horribly injured. Resuscitation alone may not help revive them.</span>")
if(prob(66))
to_chat(user, "<span class='notice'>[H] inhales deeply!</span>")
H.adjustOxyLoss(-50)
else
to_chat(user, "<span class='danger'>[H] doesn't respond!</span>")
H.AdjustParalysis(3)
H.AdjustStunned(5)
H.AdjustWeakened(5)
H.AdjustStuttering(10)
to_chat(H, "<span class='danger'>You feel a powerful jolt!</span>")
H.shock_internal_organs(100)
if(emagged && prob(10))
to_chat(user, "<span class='danger'>[src]'s on board scanner indicates that the target is undergoing a cardiac arrest!</span>")
H.set_heartattack(TRUE)
cooldown = TRUE
icon_state = "[icon_base]-shock"
addtimer(CALLBACK(src, .proc/short_charge), 10)
addtimer(CALLBACK(src, .proc/recharge), charge_time)
else
to_chat(user, "<span class='notice'>[src]'s on board medical scanner indicates that no shock is required.</span>")
/obj/item/handheld_defibrillator/proc/short_charge()
icon_state = "[icon_base]-off"
/obj/item/handheld_defibrillator/proc/recharge()
cooldown = FALSE
icon_state = "[icon_base]-on"
playsound(loc, "sound/weapons/flash.ogg", 75, 1)
@@ -19,7 +19,7 @@
/obj/item/instrument/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] begins to play 'Gloomy Sunday'! It looks like [user.p_theyre()] trying to commit suicide!</span>")
return (BRUTELOSS)
return BRUTELOSS
/obj/item/instrument/Initialize(mapload)
song.tempo = song.sanitize_tempo(song.tempo) // tick_lag isn't set when the map is loaded
@@ -168,6 +168,7 @@
/obj/item/stack/tape_roll = 5)
tools = list(/obj/item/screwdriver, /obj/item/wirecutters)
time = 80
category = CAT_MISC
/datum/crafting_recipe/guitar
name = "Guitar"
@@ -177,6 +178,7 @@
/obj/item/stack/tape_roll = 5)
tools = list(/obj/item/screwdriver, /obj/item/wirecutters)
time = 80
category = CAT_MISC
/datum/crafting_recipe/eguitar
name = "Electric Guitar"
@@ -185,4 +187,5 @@
/obj/item/stack/cable_coil = 6,
/obj/item/stack/tape_roll = 5)
tools = list(/obj/item/screwdriver, /obj/item/wirecutters)
time = 80
time = 80
category = CAT_MISC
+4 -2
View File
@@ -47,8 +47,10 @@
message = sanitize(copytext(message, 1, MAX_MESSAGE_LEN))
if(!message)
return
message = user.handle_speech_problems(message)[1]
message = capitalize(message)
var/list/message_pieces = message_to_multilingual(message)
user.handle_speech_problems(message_pieces)
message = multilingual_to_message(message_pieces)
if((loc == user && !user.incapacitated()))
if(emagged)
if(insults)
@@ -69,7 +71,7 @@
audible_message("<span class='game say'><span class='name'>[user.GetVoice()]</span> [user.GetAltName()] broadcasts, <span class='reallybig'>\"[message]\"</span></span>", hearing_distance = 14)
log_say(message, user)
for(var/obj/O in oview(14, get_turf(src)))
O.hear_talk(user, "<span class='reallybig'>[message]</span>")
O.hear_talk(user, message_to_multilingual("<span class='reallybig'>[message]</span>"))
/obj/item/megaphone/emag_act(user as mob)
if(!emagged)
@@ -339,3 +339,7 @@
pai.ex_act(severity)
else
qdel(src)
/obj/item/paicard/extinguish_light()
pai.extinguish_light()
set_light(0)
@@ -102,4 +102,4 @@
/obj/item/pizza_bomb/autoarm
timer_set = 1
timer = 10
timer = 30 // 3 seconds
@@ -8,6 +8,7 @@
var/emagged = 0
var/syndicate = 0
var/area_bypass = FALSE
var/cc_beacon = FALSE //set if allowed to teleport to even if on zlevel2
/obj/item/radio/beacon/New()
..()
@@ -1,5 +1,5 @@
/obj/item/encryptionkey/
/obj/item/encryptionkey
name = "Standard Encryption Key"
desc = "An encyption key for a radio headset. Contains cypherkeys."
icon = 'icons/obj/radio.dmi'
@@ -43,7 +43,7 @@
/obj/item/encryptionkey/binary
name = "binary translator key"
desc = "An encryption key for a radio headset. To access the binary channel, use :b."
desc = "An encryption key for a radio headset. To access the binary channel, use :+."
icon_state = "cypherkey"
translate_binary = TRUE
origin_tech = "syndicate=3;engineering=4;bluespace=3"
@@ -50,15 +50,15 @@
to_chat(user, "The following channels are available:")
to_chat(user, radio_desc)
/obj/item/radio/headset/handle_message_mode(mob/living/M as mob, message, channel)
/obj/item/radio/headset/handle_message_mode(mob/living/M as mob, list/message_pieces, channel)
if(channel == "special")
if(translate_binary)
var/datum/language/binary = GLOB.all_languages["Robot Talk"]
binary.broadcast(M, message)
binary.broadcast(M, strip_prefixes(multilingual_to_message(message_pieces)))
return RADIO_CONNECTION_NON_SUBSPACE
if(translate_hive)
var/datum/language/hivemind = GLOB.all_languages["Hivemind"]
hivemind.broadcast(M, message)
hivemind.broadcast(M, strip_prefixes(multilingual_to_message(message_pieces)))
return RADIO_CONNECTION_NON_SUBSPACE
return RADIO_CONNECTION_FAIL
@@ -309,7 +309,7 @@
/obj/item/radio/headset/attackby(obj/item/W as obj, mob/user as mob)
user.set_machine(src)
if(!( istype(W, /obj/item/screwdriver) || (istype(W, /obj/item/encryptionkey/ ))))
return
return ..()
if(istype(W, /obj/item/screwdriver))
if(keyslot1 || keyslot2)
@@ -135,6 +135,8 @@
return canhear_range
/obj/item/radio/intercom/attackby(obj/item/W as obj, mob/user as mob)
if(istype(W, /obj/item/stack/tape_roll)) //eww
return
switch(buildstage)
if(3)
if(iswirecutter(W) && b_stat && wires.IsAllCut())
@@ -236,7 +238,7 @@
materials = list(MAT_METAL=50, MAT_GLASS=50)
origin_tech = "engineering=2;programming=1"
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
usesound = 'sound/items/deconstruct.ogg'
/obj/item/radio/intercom/locked
var/locked_frequency
+13 -15
View File
@@ -256,9 +256,10 @@ var/global/list/default_medbay_channels = list(
break
if(jammed)
message = Gibberish(message, 100)
var/list/message_pieces = message_to_multilingual(message)
Broadcast_Message(connection, A,
0, "*garbled automated announcement*", src,
message, from, "Automated Announcement", from, "synthesized voice",
message_pieces, from, "Automated Announcement", from, "synthesized voice",
4, 0, zlevel, connection.frequency, follow_target = follow_target)
qdel(A)
@@ -285,7 +286,7 @@ var/global/list/default_medbay_channels = list(
qdel(src)
// Interprets the message mode when talking into a radio, possibly returning a connection datum
/obj/item/radio/proc/handle_message_mode(mob/living/M as mob, message, message_mode)
/obj/item/radio/proc/handle_message_mode(mob/living/M as mob, list/message_pieces, message_mode)
// If a channel isn't specified, send to common.
if(!message_mode || message_mode == "headset")
return radio_connection
@@ -301,11 +302,11 @@ var/global/list/default_medbay_channels = list(
// If we were to send to a channel we don't have, drop it.
return RADIO_CONNECTION_FAIL
/obj/item/radio/talk_into(mob/living/M as mob, message, channel, var/verb = "says", var/datum/language/speaking = null)
/obj/item/radio/talk_into(mob/living/M as mob, list/message_pieces, channel, var/verb = "says")
if(!on)
return 0 // the device has to be on
// Fix for permacell radios, but kinda eh about actually fixing them.
if(!M || !message)
if(!M || !message_pieces)
return 0
// Uncommenting this. To the above comment:
@@ -328,7 +329,7 @@ var/global/list/default_medbay_channels = list(
*/
//#### Grab the connection datum ####//
var/message_mode = handle_message_mode(M, message, channel)
var/message_mode = handle_message_mode(M, message_pieces, channel)
switch(message_mode) //special cases
if(RADIO_CONNECTION_FAIL)
return 0
@@ -361,7 +362,7 @@ var/global/list/default_medbay_channels = list(
var/jobname // the mob's "job"
if(jammed)
message = Gibberish(message, 100)
Gibberish_all(message_pieces, 100)
// --- Human: use their actual job ---
if(ishuman(M))
@@ -432,7 +433,7 @@ var/global/list/default_medbay_channels = list(
// Other tags:
"compression" = rand(45,50), // compressed radio signal
"message" = message, // the actual sent message
"message" = message_pieces, // the actual sent message
"connection" = connection, // the radio connection to use
"radio" = src, // stores the radio used for transmission
"slow" = 0, // how much to sleep() before broadcasting - simulates net lag
@@ -441,7 +442,6 @@ var/global/list/default_medbay_channels = list(
"server" = null, // the last server to log this signal
"reject" = 0, // if nonzero, the signal will not be accepted by any broadcasting machinery
"level" = position.z, // The source's z level
"language" = speaking,
"verb" = verb
)
signal.frequency = connection.frequency // Quick frequency set
@@ -490,7 +490,7 @@ var/global/list/default_medbay_channels = list(
"vmask" = voicemask, // 1 if the mob is using a voice gas mas
"compression" = 0, // uncompressed radio signal
"message" = message, // the actual sent message
"message" = message_pieces, // the actual sent message
"connection" = connection, // the radio connection to use
"radio" = src, // stores the radio used for transmission
"slow" = 0,
@@ -499,7 +499,6 @@ var/global/list/default_medbay_channels = list(
"server" = null,
"reject" = 0,
"level" = position.z,
"language" = speaking,
"verb" = verb
)
signal.frequency = connection.frequency // Quick frequency set
@@ -522,15 +521,14 @@ var/global/list/default_medbay_channels = list(
if(!connection) return 0 //~Carn
return Broadcast_Message(connection, M, voicemask, pick(M.speak_emote),
src, message, displayname, jobname, real_name, M.voice_name,
filter_type, signal.data["compression"], list(position.z), connection.frequency,verb,speaking)
src, message_pieces, displayname, jobname, real_name, M.voice_name,
filter_type, signal.data["compression"], list(position.z), connection.frequency,verb)
/obj/item/radio/hear_talk(mob/M as mob, msg, var/verb = "says", var/datum/language/speaking = null)
/obj/item/radio/hear_talk(mob/M as mob, list/message_pieces, var/verb = "says")
if(broadcasting)
if(get_dist(src, M) <= canhear_range)
talk_into(M, msg,null,verb,speaking)
talk_into(M, message_pieces, null, verb)
/*
+178 -214
View File
@@ -5,7 +5,6 @@ DETECTIVE SCANNER
HEALTH ANALYZER
GAS ANALYZER
PLANT ANALYZER
MASS SPECTROMETER
REAGENT SCANNER
*/
/obj/item/t_scanner
@@ -126,8 +125,8 @@ REAGENT SCANNER
var/mode = 1;
/obj/item/healthanalyzer/attack(mob/living/M as mob, mob/living/user as mob)
if(( (CLUMSY in user.mutations) || user.getBrainLoss() >= 60) && prob(50))
/obj/item/healthanalyzer/attack(mob/living/M, mob/living/user)
if(((CLUMSY in user.mutations) || user.getBrainLoss() >= 60) && prob(50))
to_chat(user, text("<span class='warning'>You try to analyze the floor's vitals!</span>"))
for(var/mob/O in viewers(M, null))
O.show_message(text("<span class='warning'>[user] has analyzed the floor's vitals!</span>"), 1)
@@ -138,7 +137,7 @@ REAGENT SCANNER
return
user.visible_message("<span class='notice'>[user] has analyzed [M]'s vitals.</span>","<span class='notice'> You have analyzed [M]'s vitals.</span>")
if(!istype(M,/mob/living/carbon/human) || M.isSynthetic())
if(!ishuman(M) || M.isSynthetic())
//these sensors are designed for organic life
user.show_message("<span class='notice'>Analyzing Results for ERROR:\n\t Overall Status: ERROR</span>")
user.show_message("\t Key: <font color='blue'>Suffocation</font>/<font color='green'>Toxin</font>/<font color='#FFA500'>Burns</font>/<font color='red'>Brute</font>", 1)
@@ -148,118 +147,132 @@ REAGENT SCANNER
user.show_message("<span class='notice'>Subject's pulse: <font color='red'>-- bpm.</font></span>")
return
var/fake_oxy = max(rand(1,40), M.getOxyLoss(), (300 - (M.getToxLoss() + M.getFireLoss() + M.getBruteLoss())))
var/OX = M.getOxyLoss() > 50 ? "<b>[M.getOxyLoss()]</b>" : M.getOxyLoss()
var/TX = M.getToxLoss() > 50 ? "<b>[M.getToxLoss()]</b>" : M.getToxLoss()
var/BU = M.getFireLoss() > 50 ? "<b>[M.getFireLoss()]</b>" : M.getFireLoss()
var/BR = M.getBruteLoss() > 50 ? "<b>[M.getBruteLoss()]</b>" : M.getBruteLoss()
if(M.status_flags & FAKEDEATH)
var/mob/living/carbon/human/H = M
var/fake_oxy = max(rand(1,40), H.getOxyLoss(), (300 - (H.getToxLoss() + H.getFireLoss() + H.getBruteLoss())))
var/OX = H.getOxyLoss() > 50 ? "<b>[H.getOxyLoss()]</b>" : H.getOxyLoss()
var/TX = H.getToxLoss() > 50 ? "<b>[H.getToxLoss()]</b>" : H.getToxLoss()
var/BU = H.getFireLoss() > 50 ? "<b>[H.getFireLoss()]</b>" : H.getFireLoss()
var/BR = H.getBruteLoss() > 50 ? "<b>[H.getBruteLoss()]</b>" : H.getBruteLoss()
if(H.status_flags & FAKEDEATH)
OX = fake_oxy > 50 ? "<b>[fake_oxy]</b>" : fake_oxy
user.show_message("<span class='notice'>Analyzing Results for [M]:\n\t Overall Status: dead</span>")
user.show_message("<span class='notice'>Analyzing Results for [H]:\n\t Overall Status: dead</span>")
else
user.show_message("<span class='notice'>Analyzing Results for [M]:\n\t Overall Status: [M.stat > 1 ? "dead" : "[M.health]% healthy"]</span>")
user.show_message("<span class='notice'>Analyzing Results for [H]:\n\t Overall Status: [H.stat > 1 ? "dead" : "[H.health]% healthy"]</span>")
user.show_message("\t Key: <font color='blue'>Suffocation</font>/<font color='green'>Toxin</font>/<font color='#FFA500'>Burns</font>/<font color='red'>Brute</font>", 1)
user.show_message("\t Damage Specifics: <font color='blue'>[OX]</font> - <font color='green'>[TX]</font> - <font color='#FFA500'>[BU]</font> - <font color='red'>[BR]</font>")
user.show_message("<span class='notice'>Body Temperature: [M.bodytemperature-T0C]&deg;C ([M.bodytemperature*1.8-459.67]&deg;F)</span>", 1)
if(M.timeofdeath && (M.stat == DEAD || (M.status_flags & FAKEDEATH)))
user.show_message("<span class='notice'>Time of Death: [station_time_timestamp("hh:mm:ss", M.timeofdeath)]</span>")
if(istype(M, /mob/living/carbon/human) && mode == 1)
var/mob/living/carbon/human/H = M
user.show_message("<span class='notice'>Body Temperature: [H.bodytemperature-T0C]&deg;C ([H.bodytemperature*1.8-459.67]&deg;F)</span>", 1)
if(H.timeofdeath && (H.stat == DEAD || (H.status_flags & FAKEDEATH)))
user.show_message("<span class='notice'>Time of Death: [station_time_timestamp("hh:mm:ss", H.timeofdeath)]</span>")
var/tdelta = round(world.time - H.timeofdeath)
if(tdelta < (DEFIB_TIME_LIMIT * 10))
user.show_message("<span class='danger'>Subject died [DisplayTimeText(tdelta)] ago, defibrillation may be possible!</span>")
if(mode == 1)
var/list/damaged = H.get_damaged_organs(1,1)
user.show_message("<span class='notice'>Localized Damage, Brute/Burn:</span>",1)
if(length(damaged) > 0)
for(var/obj/item/organ/external/org in damaged)
user.show_message("\t\t<span class='info'>[capitalize(org.name)]: [(org.brute_dam > 0) ? "<font color='red'>[org.brute_dam]</font></span>" : "<font color='red'>0</font>"]-[(org.burn_dam > 0) ? "<font color='#FF8000'>[org.burn_dam]</font>" : "<font color='#FF8000'>0</font>"]")
OX = M.getOxyLoss() > 50 ? "<font color='blue'><b>Severe oxygen deprivation detected</b></font>" : "Subject bloodstream oxygen level normal"
TX = M.getToxLoss() > 50 ? "<font color='green'><b>Dangerous amount of toxins detected</b></font>" : "Subject bloodstream toxin level minimal"
BU = M.getFireLoss() > 50 ? "<font color='#FFA500'><b>Severe burn damage detected</b></font>" : "Subject burn injury status O.K"
BR = M.getBruteLoss() > 50 ? "<font color='red'><b>Severe anatomical damage detected</b></font>" : "Subject brute-force injury status O.K"
if(M.status_flags & FAKEDEATH)
OX = H.getOxyLoss() > 50 ? "<font color='blue'><b>Severe oxygen deprivation detected</b></font>" : "Subject bloodstream oxygen level normal"
TX = H.getToxLoss() > 50 ? "<font color='green'><b>Dangerous amount of toxins detected</b></font>" : "Subject bloodstream toxin level minimal"
BU = H.getFireLoss() > 50 ? "<font color='#FFA500'><b>Severe burn damage detected</b></font>" : "Subject burn injury status O.K"
BR = H.getBruteLoss() > 50 ? "<font color='red'><b>Severe anatomical damage detected</b></font>" : "Subject brute-force injury status O.K"
if(H.status_flags & FAKEDEATH)
OX = fake_oxy > 50 ? "<span class='danger'>Severe oxygen deprivation detected</span>" : "<span class='notice'>Subject bloodstream oxygen level normal</span>"
user.show_message("[OX] | [TX] | [BU] | [BR]")
if(istype(M, /mob/living/carbon))
if(upgraded)
chemscan(user, M)
for(var/thing in M.viruses)
var/datum/disease/D = thing
if(!(D.visibility_flags & HIDDEN_SCANNER))
user.show_message("<span class='alert'><b>Warning: [D.form] detected</b>\nName: [D.name].\nType: [D.spread_text].\nStage: [D.stage]/[D.max_stages].\nPossible Cure: [D.cure_text]</span>")
if(M.getStaminaLoss())
if(upgraded)
chemscan(user, H)
for(var/thing in H.viruses)
var/datum/disease/D = thing
if(!(D.visibility_flags & HIDDEN_SCANNER))
user.show_message("<span class='alert'><b>Warning: [D.form] detected</b>\nName: [D.name].\nType: [D.spread_text].\nStage: [D.stage]/[D.max_stages].\nPossible Cure: [D.cure_text]</span>")
if(H.undergoing_cardiac_arrest())
var/obj/item/organ/internal/heart/heart = H.get_int_organ(/obj/item/organ/internal/heart)
if(heart && !(heart.status & ORGAN_DEAD))
user.show_message("<span class='alert'><b>Warning: Medical Emergency detected</b>\nName: Cardiac Arrest.\nType: The patient's heart has stopped.\nStage: 1/1.\nPossible Cure: Electric Shock</span>")
else if(heart && (heart.status & ORGAN_DEAD))
user.show_message("<span class='alert'><b>Subject's heart is necrotic.</b></span>")
else if(!heart)
user.show_message("<span class='alert'><b>Subject has no heart.</b></span>")
if(H.getStaminaLoss())
user.show_message("<span class='info'>Subject appears to be suffering from fatigue.</span>")
if(M.getCloneLoss())
user.show_message("<span class='warning'>Subject appears to have [M.getCloneLoss() > 30 ? "severe" : "minor"] cellular damage.</span>")
if(M.has_brain_worms())
if(H.getCloneLoss())
user.show_message("<span class='warning'>Subject appears to have [H.getCloneLoss() > 30 ? "severe" : "minor"] cellular damage.</span>")
if(H.has_brain_worms())
user.show_message("<span class='warning'>Subject suffering from aberrant brain activity. Recommend further scanning.</span>")
else if(M.getBrainLoss() >= 100 || istype(M, /mob/living/carbon/human) && !M.get_int_organ(/obj/item/organ/internal/brain))
user.show_message("<span class='warning'>Subject is brain dead.</span>")
else if(M.getBrainLoss() >= 60)
user.show_message("<span class='warning'>Severe brain damage detected. Subject likely to have mental retardation.</span>")
else if(M.getBrainLoss() >= 10)
user.show_message("<span class='warning'>Significant brain damage detected. Subject may have had a concussion.</span>")
if(ishuman(M))
var/mob/living/carbon/human/H = M
for(var/name in H.bodyparts_by_name)
var/obj/item/organ/external/e = H.bodyparts_by_name[name]
if(!e)
continue
var/limb = e.name
if(e.status & ORGAN_BROKEN)
if((e.limb_name in list("l_arm", "r_arm", "l_hand", "r_hand", "l_leg", "r_leg", "l_foot", "r_foot")) && !(e.status & ORGAN_SPLINTED))
user.show_message("<span class='warning'>Unsecured fracture in subject [limb]. Splinting recommended for transport.</span>")
if(e.has_infected_wound())
user.show_message("<span class='warning'>Infected wound detected in subject [limb]. Disinfection recommended.</span>")
for(var/name in H.bodyparts_by_name)
var/obj/item/organ/external/e = H.bodyparts_by_name[name]
if(!e)
continue
if(e.status & ORGAN_BROKEN)
user.show_message(text("<span class='warning'>Bone fractures detected. Advanced scanner required for location.</span>"), 1)
break
for(var/obj/item/organ/external/e in H.bodyparts)
if(e.internal_bleeding)
user.show_message(text("<span class='warning'>Internal bleeding detected. Advanced scanner required for location.</span>"), 1)
break
var/blood_id = H.get_blood_id()
if(blood_id)
if(H.bleed_rate)
user.show_message("<span class='danger'>Subject is bleeding!</span>")
var/blood_percent = round((H.blood_volume / BLOOD_VOLUME_NORMAL)*100)
var/blood_type = H.b_type
if(blood_id != "blood")//special blood substance
var/datum/reagent/R = GLOB.chemical_reagents_list[blood_id]
if(R)
blood_type = R.name
else
blood_type = blood_id
if(H.blood_volume <= BLOOD_VOLUME_SAFE && H.blood_volume > BLOOD_VOLUME_OKAY)
user.show_message("<span class='danger'>LOW blood level [blood_percent] %, [H.blood_volume] cl,</span> <span class='info'>type: [blood_type]</span>")
else if(H.blood_volume <= BLOOD_VOLUME_OKAY)
user.show_message("<span class='danger'>CRITICAL blood level [blood_percent] %, [H.blood_volume] cl,</span> <span class='info'>type: [blood_type]</span>")
if(H.get_int_organ(/obj/item/organ/internal/brain))
if(H.getBrainLoss() >= 100)
user.show_message("<span class='warning'>Subject is brain dead.</span>")
else if(H.getBrainLoss() >= 60)
user.show_message("<span class='warning'>Severe brain damage detected. Subject likely to have mental retardation.</span>")
else if(H.getBrainLoss() >= 10)
user.show_message("<span class='warning'>Significant brain damage detected. Subject may have had a concussion.</span>")
else
user.show_message("<span class='warning'>Subject has no brain.</span>")
for(var/name in H.bodyparts_by_name)
var/obj/item/organ/external/e = H.bodyparts_by_name[name]
if(!e)
continue
var/limb = e.name
if(e.status & ORGAN_BROKEN)
if((e.limb_name in list("l_arm", "r_arm", "l_hand", "r_hand", "l_leg", "r_leg", "l_foot", "r_foot")) && !(e.status & ORGAN_SPLINTED))
user.show_message("<span class='warning'>Unsecured fracture in subject [limb]. Splinting recommended for transport.</span>")
if(e.has_infected_wound())
user.show_message("<span class='warning'>Infected wound detected in subject [limb]. Disinfection recommended.</span>")
for(var/name in H.bodyparts_by_name)
var/obj/item/organ/external/e = H.bodyparts_by_name[name]
if(!e)
continue
if(e.status & ORGAN_BROKEN)
user.show_message(text("<span class='warning'>Bone fractures detected. Advanced scanner required for location.</span>"), 1)
break
for(var/obj/item/organ/external/e in H.bodyparts)
if(e.internal_bleeding)
user.show_message(text("<span class='warning'>Internal bleeding detected. Advanced scanner required for location.</span>"), 1)
break
var/blood_id = H.get_blood_id()
if(blood_id)
if(H.bleed_rate)
user.show_message("<span class='danger'>Subject is bleeding!</span>")
var/blood_percent = round((H.blood_volume / BLOOD_VOLUME_NORMAL)*100)
var/blood_type = H.b_type
if(blood_id != "blood")//special blood substance
var/datum/reagent/R = GLOB.chemical_reagents_list[blood_id]
if(R)
blood_type = R.name
else
user.show_message("<span class='info'>Blood level [blood_percent] %, [H.blood_volume] cl, type: [blood_type]</span>")
if(H.undergoing_cardiac_arrest() && H.stat != DEAD)
user.show_message("<span class='userdanger'>Subject suffering from heart attack: Apply defibrillator immediately.</span>")
user.show_message("<span class='notice'>Subject's pulse: <font color='[H.pulse == PULSE_THREADY || H.pulse == PULSE_NONE ? "red" : "blue"]'>[H.get_pulse(GETPULSE_TOOL)] bpm.</font></span>")
var/implant_detect
for(var/obj/item/organ/internal/cyberimp/CI in H.internal_organs)
if(CI.is_robotic())
implant_detect += "[H.name] is modified with a [CI.name].<br>"
if(implant_detect)
user.show_message("<span class='notice'>Detected cybernetic modifications:</span>")
user.show_message("<span class='notice'>[implant_detect]</span>")
if(H.gene_stability < 40)
user.show_message("<span class='userdanger'>Subject's genes are quickly breaking down!</span>")
else if(H.gene_stability < 70)
user.show_message("<span class='danger'>Subject's genes are showing signs of spontaneous breakdown.</span>")
else if(H.gene_stability < 85)
user.show_message("<span class='warning'>Subject's genes are showing minor signs of instability.</span>")
blood_type = blood_id
if(H.blood_volume <= BLOOD_VOLUME_SAFE && H.blood_volume > BLOOD_VOLUME_OKAY)
user.show_message("<span class='danger'>LOW blood level [blood_percent] %, [H.blood_volume] cl,</span> <span class='info'>type: [blood_type]</span>")
else if(H.blood_volume <= BLOOD_VOLUME_OKAY)
user.show_message("<span class='danger'>CRITICAL blood level [blood_percent] %, [H.blood_volume] cl,</span> <span class='info'>type: [blood_type]</span>")
else
user.show_message("<span class='notice'>Subject's genes are stable.</span>")
src.add_fingerprint(user)
return
user.show_message("<span class='info'>Blood level [blood_percent] %, [H.blood_volume] cl, type: [blood_type]</span>")
user.show_message("<span class='notice'>Subject's pulse: <font color='[H.pulse == PULSE_THREADY || H.pulse == PULSE_NONE ? "red" : "blue"]'>[H.get_pulse(GETPULSE_TOOL)] bpm.</font></span>")
var/implant_detect
for(var/obj/item/organ/internal/cyberimp/CI in H.internal_organs)
if(CI.is_robotic())
implant_detect += "[H.name] is modified with a [CI.name].<br>"
if(implant_detect)
user.show_message("<span class='notice'>Detected cybernetic modifications:</span>")
user.show_message("<span class='notice'>[implant_detect]</span>")
if(H.gene_stability < 40)
user.show_message("<span class='userdanger'>Subject's genes are quickly breaking down!</span>")
else if(H.gene_stability < 70)
user.show_message("<span class='danger'>Subject's genes are showing signs of spontaneous breakdown.</span>")
else if(H.gene_stability < 85)
user.show_message("<span class='warning'>Subject's genes are showing minor signs of instability.</span>")
else
user.show_message("<span class='notice'>Subject's genes are stable.</span>")
add_fingerprint(user)
/obj/item/healthanalyzer/verb/toggle_mode()
set name = "Switch Verbosity"
@@ -272,19 +285,21 @@ REAGENT SCANNER
if(0)
to_chat(usr, "The scanner no longer shows limb damage.")
/obj/item/healthanalyzer/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/healthupgrade))
/obj/item/healthanalyzer/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/healthupgrade))
if(upgraded)
to_chat(user, "<span class='notice'>You have already installed an upgraded in the [src].</span>")
else
to_chat(user, "<span class='notice'>You install the upgrade in the [src].</span>")
overlays += "advanced"
playsound(loc, W.usesound, 50, 1)
upgraded = 1
qdel(W)
playsound(loc, I.usesound, 50, 1)
upgraded = TRUE
qdel(I)
return
return ..()
/obj/item/healthanalyzer/advanced
upgraded = 1
upgraded = TRUE
/obj/item/healthanalyzer/advanced/New()
overlays += "advanced"
@@ -297,7 +312,7 @@ REAGENT SCANNER
desc = "An upgrade unit that can be installed on a health analyzer for expanded functionality."
w_class = WEIGHT_CLASS_TINY
origin_tech = "magnets=2;biotech=2"
usesound = 'sound/items/Deconstruct.ogg'
usesound = 'sound/items/deconstruct.ogg'
/obj/item/analyzer
desc = "A hand-held environmental scanner which reports current gas levels."
@@ -432,95 +447,9 @@ REAGENT SCANNER
amount += inaccurate
return DisplayTimeText(max(1, amount))
/obj/item/mass_spectrometer
desc = "A hand-held mass spectrometer which identifies trace chemicals in a blood sample. Inject sample with syringe."
name = "mass-spectrometer"
icon = 'icons/obj/device.dmi'
icon_state = "spectrometer"
item_state = "analyzer"
w_class = WEIGHT_CLASS_SMALL
flags = CONDUCT
container_type = OPENCONTAINER
slot_flags = SLOT_BELT
throwforce = 5
throw_speed = 4
throw_range = 20
materials = list(MAT_METAL=150, MAT_GLASS=100)
origin_tech = "magnets=2;biotech=1;plasmatech=2"
var/details = 0
var/datatoprint = ""
var/scanning = TRUE
actions_types = list(/datum/action/item_action/print_report)
/obj/item/mass_spectrometer/New()
..()
create_reagents(5)
/obj/item/mass_spectrometer/on_reagent_change()
if(reagents.total_volume)
icon_state = initial(icon_state) + "_s"
else
icon_state = initial(icon_state)
/obj/item/mass_spectrometer/attack_self(mob/user as mob)
if(user.stat)
return
if(!user.IsAdvancedToolUser())
to_chat(user, "<span class='warning'>You don't have the dexterity to do this!</span>")
return
if(reagents.total_volume)
var/list/blood_traces = list()
for(var/datum/reagent/R in reagents.reagent_list)
if(R.id != "blood")
to_chat(user, "<span class='warning'>The sample was contaminated! Please insert another sample.</span>")
reagents.clear_reagents()
return
else
blood_traces = params2list(R.data["trace_chem"])
break
var/dat = ""
for(var/R in blood_traces)
if(details)
dat += "[R] ([blood_traces[R]] units) "
else
dat += "[R] "
to_chat(user, "Analysis completed. Chemicals found: [dat]")
scanning = FALSE
datatoprint = dat
reagents.clear_reagents()
return
/obj/item/mass_spectrometer/adv
name = "advanced mass-spectrometer"
icon_state = "adv_spectrometer"
details = 1
origin_tech = "magnets=4;biotech=3;plasmatech=3"
/obj/item/mass_spectrometer/proc/print_report()
if(!scanning)
scanning = TRUE
usr.visible_message("<span class='warning'>[src] rattles and prints out a sheet of paper.</span>")
playsound(loc, 'sound/goonstation/machines/printer_thermal.ogg', 50, 1)
sleep(50)
var/obj/item/paper/P = new(get_turf(src))
P.name = "Mass Spectrometer Scanner Report: [station_time_timestamp()]"
P.info = "<center><b>Mass Spectrometer</b></center><br><center>Data Analysis:</center><br><hr><br><b>Trace chemicals detected:</b><br>[datatoprint]<br><hr>"
if(ismob(loc))
var/mob/M = loc
M.put_in_hands(P)
to_chat(M, "<span class='notice'>Report printed. Log cleared.</span>")
datatoprint = ""
else
to_chat(usr, "<span class='notice'>[src] has no logs or is already in use.</span>")
/obj/item/mass_spectrometer/ui_action_click()
print_report()
/obj/item/reagent_scanner
name = "reagent scanner"
desc = "A hand-held reagent scanner which identifies chemical agents."
desc = "A hand-held reagent scanner which identifies chemical agents and blood types."
icon = 'icons/obj/device.dmi'
icon_state = "spectrometer"
item_state = "analyzer"
@@ -532,9 +461,9 @@ REAGENT SCANNER
throw_range = 20
materials = list(MAT_METAL=30, MAT_GLASS=20)
origin_tech = "magnets=2;biotech=1;plasmatech=2"
var/details = 0
var/details = FALSE
var/datatoprint = ""
var/scanning = 1
var/scanning = TRUE
actions_types = list(/datum/action/item_action/print_report)
/obj/item/reagent_scanner/afterattack(obj/O, mob/user as mob)
@@ -548,14 +477,19 @@ REAGENT SCANNER
if(!isnull(O.reagents))
var/dat = ""
var/blood_type = ""
if(O.reagents.reagent_list.len > 0)
var/one_percent = O.reagents.total_volume / 100
for(var/datum/reagent/R in O.reagents.reagent_list)
dat += "<br>[TAB]<span class='notice'>[R][details ? ": [R.volume / one_percent]%" : ""]</span>"
if(R.id != "blood")
dat += "<br>[TAB]<span class='notice'>[R][details ? ": [R.volume / one_percent]%" : ""]</span>"
else
blood_type = R.data["blood_type"]
dat += "<br>[TAB]<span class='notice'>[R][blood_type ? " [blood_type]" : ""][details ? ": [R.volume / one_percent]%" : ""]</span>"
if(dat)
to_chat(user, "<span class='notice'>Chemicals found: [dat]</span>")
datatoprint = dat
scanning = 0
scanning = FALSE
else
to_chat(user, "<span class='notice'>No active chemical agents found in [O].</span>")
else
@@ -565,7 +499,7 @@ REAGENT SCANNER
/obj/item/reagent_scanner/adv
name = "advanced reagent scanner"
icon_state = "adv_spectrometer"
details = 1
details = TRUE
origin_tech = "magnets=4;biotech=3;plasmatech=3"
/obj/item/reagent_scanner/proc/print_report()
@@ -583,7 +517,7 @@ REAGENT SCANNER
M.put_in_hands(P)
to_chat(M, "<span class='notice'>Report printed. Log cleared.</span>")
datatoprint = ""
scanning = 1
scanning = TRUE
else
to_chat(usr, "<span class='notice'>[src] has no logs or is already in use.</span>")
@@ -604,6 +538,9 @@ REAGENT SCANNER
materials = list(MAT_METAL=30, MAT_GLASS=20)
/obj/item/slime_scanner/attack(mob/living/M as mob, mob/living/user as mob)
slime_scan(M, user)
/proc/slime_scan(mob/living/carbon/slime/M, mob/living/user)
if(!isslime(M))
user.show_message("<span class='warning'>This device can only scan slimes!</span>", 1)
return
@@ -651,10 +588,20 @@ REAGENT SCANNER
var/ready = TRUE // Ready to scan
var/time_to_use = 0 // How much time remaining before next scan is available.
var/usecharge = 750
var/scan_time = 10 SECONDS //how long does it take to scan
var/scan_cd = 60 SECONDS //how long before we can scan again
/obj/item/bodyanalyzer/advanced
cell_type = /obj/item/stock_parts/cell/upgraded/plus
/obj/item/bodyanalyzer/borg
name = "cyborg body analyzer"
desc = "Scan an entire body to prepare for field surgery. Consumes power for each scan."
/obj/item/bodyanalyzer/borg/syndicate
scan_time = 5 SECONDS
scan_cd = 20 SECONDS
/obj/item/bodyanalyzer/New()
..()
power_supply = new cell_type(src)
@@ -663,7 +610,7 @@ REAGENT SCANNER
/obj/item/bodyanalyzer/proc/setReady()
ready = TRUE
playsound(src, 'sound/machines/defib_saftyOn.ogg', 50, 0)
playsound(src, 'sound/machines/defib_saftyon.ogg', 50, 0)
update_icon()
/obj/item/bodyanalyzer/update_icon(printing = FALSE)
@@ -673,7 +620,7 @@ REAGENT SCANNER
icon_state = "bodyanalyzer_1"
else
icon_state = "bodyanalyzer_2"
var/overlayid = round(percent / 10)
overlayid = "bodyanalyzer_charge[overlayid]"
overlays += icon(icon, overlayid)
@@ -684,49 +631,66 @@ REAGENT SCANNER
/obj/item/bodyanalyzer/attack(mob/living/M, mob/living/carbon/human/user)
if(user.incapacitated() || !user.Adjacent(M))
return
if(!ready)
to_chat(user, "<span class='notice'>The scanner beeps angrily at you! It's currently recharging - [round((time_to_use - world.time) * 0.1)] seconds remaining.</span>")
playsound(user.loc, 'sound/machines/buzz-sigh.ogg', 50, 1)
return
if(power_supply.charge >= usecharge)
mobScan(M, user)
else
to_chat(user, "<span class='notice'>The scanner beeps angrily at you! It's out of charge!</span>")
playsound(user.loc, 'sound/machines/buzz-sigh.ogg', 50, 1)
/obj/item/bodyanalyzer/borg/attack(mob/living/M, mob/living/silicon/robot/user)
if(user.incapacitated() || !user.Adjacent(M))
return
if(!ready)
to_chat(user, "<span class='notice'>[src] is currently recharging - [round((time_to_use - world.time) * 0.1)] seconds remaining.</span>")
return
if(user.cell.charge >= usecharge)
mobScan(M, user)
else
to_chat(user, "<span class='notice'>You need to recharge before you can use [src]</span>")
/obj/item/bodyanalyzer/proc/mobScan(mob/living/M, mob/user)
if(ishuman(M))
var/report = generate_printing_text(M, user)
user.visible_message("[user] begins scanning [M] with [src].", "You begin scanning [M].")
if(do_after(user, 100, target = M))
if(do_after(user, scan_time, target = M))
var/obj/item/paper/printout = new
printout.info = report
printout.name = "Scan report - [M.name]"
playsound(user.loc, 'sound/goonstation/machines/printer_dotmatrix.ogg', 50, 1)
user.put_in_hands(printout)
time_to_use = world.time + 600
power_supply.use(usecharge)
time_to_use = world.time + scan_cd
if(isrobot(user))
var/mob/living/silicon/robot/R = user
R.cell.use(usecharge)
else
power_supply.use(usecharge)
ready = FALSE
update_icon(TRUE)
addtimer(CALLBACK(src, /obj/item/bodyanalyzer/.proc/setReady), 600)
addtimer(CALLBACK(src, /obj/item/bodyanalyzer/.proc/setReady), scan_cd)
addtimer(CALLBACK(src, /obj/item/bodyanalyzer/.proc/update_icon), 20)
else if(iscorgi(M) && M.stat == DEAD)
to_chat(user, "<span class='notice'>You wonder if [M.p_they()] was a good dog. <b>[src] tells you they were the best...</b></span>") // :'(
playsound(loc, 'sound/machines/ping.ogg', 50, 0)
ready = FALSE
addtimer(CALLBACK(src, /obj/item/bodyanalyzer/.proc/setReady), 600)
time_to_use = world.time + 600
addtimer(CALLBACK(src, /obj/item/bodyanalyzer/.proc/setReady), scan_cd)
time_to_use = world.time + scan_cd
else
to_chat(user, "<span class='notice'>Scanning error detected. Invalid specimen.</span>")
//Unashamedly ripped from adv_med.dm
/obj/item/bodyanalyzer/proc/generate_printing_text(mob/living/M, mob/user)
var/dat = ""
var/mob/living/carbon/human/target = M
dat = "<font color='blue'><b>Target Statistics:</b></font><br>"
var/t1
switch(target.stat) // obvious, see what their status is
@@ -881,5 +845,5 @@ REAGENT SCANNER
dat += "<font color='red'>Photoreceptor abnormalities detected.</font><BR>"
if(target.disabilities & NEARSIGHTED)
dat += "<font color='red'>Retinal misalignment detected.</font><BR>"
return dat
return dat
@@ -47,7 +47,7 @@
update_icon()
/obj/item/taperecorder/fire_act()
/obj/item/taperecorder/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
mytape.ruin() //Fires destroy the tape
return ..()
@@ -85,7 +85,8 @@
icon_state = "taperecorder_idle"
/obj/item/taperecorder/hear_talk(mob/living/M as mob, msg)
/obj/item/taperecorder/hear_talk(mob/living/M as mob, list/message_pieces)
var/msg = multilingual_to_message(message_pieces)
if(mytape && recording)
var/ending = copytext(msg, length(msg))
mytape.timestamp += mytape.used_capacity
@@ -261,7 +262,8 @@
var/list/timestamp = list()
var/ruined = 0
/obj/item/tape/fire_act()
/obj/item/tape/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
ruin()
/obj/item/tape/attack_self(mob/user)
@@ -75,10 +75,10 @@
return
attached_device.HasProximity(AM)
/obj/item/transfer_valve/hear_talk(mob/living/M, msg)
/obj/item/transfer_valve/hear_talk(mob/living/M, list/message_pieces)
..()
for(var/obj/O in contents)
O.hear_talk(M, msg)
O.hear_talk(M, message_pieces)
/obj/item/transfer_valve/hear_message(mob/living/M, msg)
..()
+32 -14
View File
@@ -23,7 +23,8 @@ var/list/world_uplinks = list()
var/used_TC = 0
var/job = null
var/show_descriptions = 0
var/temp_category
var/uplink_type = "traitor"
/obj/item/uplink/nano_host()
return loc
@@ -70,7 +71,10 @@ var/list/world_uplinks = list()
if(I.job && I.job.len)
if(!(I.job.Find(job)))
continue
dat += "<A href='byond://?src=[UID()];buy_item=[I.reference];cost=[I.cost]'>[I.name]</A> ([I.cost])<BR>"
dat += "<A href='byond://?src=[UID()];buy_item=[I.reference];cost=[I.cost]'>[I.name]</A> ([I.cost])"
if(I.hijack_only)
dat += " (HIJACK ONLY)"
dat += " <BR>"
category_items++
dat += "<A href='byond://?src=[UID()];buy_item=random'>Random Item (??)</A><br>"
@@ -93,7 +97,7 @@ var/list/world_uplinks = list()
if(I.job && I.job.len)
if(!(I.job.Find(job)))
continue
nano[nano.len]["items"] += list(list("Name" = sanitize(I.name), "Description" = sanitize(I.description()),"Cost" = I.cost, "obj_path" = I.reference))
nano[nano.len]["items"] += list(list("Name" = sanitize(I.name), "Description" = sanitize(I.description()),"Cost" = I.cost, "hijack_only" = I.hijack_only, "obj_path" = I.reference))
reference[I.reference] = I
var/datum/nano_item_lists/result = new
@@ -109,7 +113,7 @@ var/list/world_uplinks = list()
var/list/random_items = new
for(var/IR in ItemsReference)
var/datum/uplink_item/UI = ItemsReference[IR]
if(UI.cost <= uses)
if(UI.cost <= uses && UI.limited_stock != 0)
random_items += UI
return pick(random_items)
@@ -132,7 +136,12 @@ var/list/world_uplinks = list()
/obj/item/uplink/proc/buy(var/datum/uplink_item/UI, var/reference)
if(!UI)
return
if(UI.limited_stock == 0)
to_chat(usr, "<span class='warning'>You have redeemed this discount already.</span>")
return
UI.buy(src,usr)
if(UI.limited_stock > 0) // only decrement it if it's actually limited
UI.limited_stock--
SSnanoui.update_uis(src)
/* var/list/L = UI.spawn_item(get_turf(usr),src)
@@ -224,10 +233,10 @@ var/list/world_uplinks = list()
data["welcome"] = welcome
data["crystals"] = uses
data["menu"] = nanoui_menu
data["descriptions"] = show_descriptions
if(!nanoui_items)
generate_items(user)
data["nano_items"] = nanoui_items
data["category_choice"] = temp_category
data += nanoui_data
return data
@@ -255,17 +264,11 @@ var/list/world_uplinks = list()
hidden_crystals = 0
ui.close()
return 1
if(href_list["return"])
nanoui_menu = round(nanoui_menu/10)
update_nano_data()
if(href_list["menu"])
nanoui_menu = text2num(href_list["menu"])
update_nano_data(href_list["id"])
if(href_list["menu"])
nanoui_menu = text2num(href_list["menu"])
update_nano_data(href_list["id"])
if(href_list["descriptions"])
show_descriptions = !show_descriptions
if(href_list["category"])
temp_category = href_list["category"]
update_nano_data()
SSnanoui.update_uis(src)
@@ -320,6 +323,21 @@ var/list/world_uplinks = list()
if(hidden_uplink)
hidden_uplink.trigger(user)
/obj/item/radio/uplink/nuclear/New()
..()
if(hidden_uplink)
hidden_uplink.uplink_type = "nuclear"
GLOB.nuclear_uplink_list += src
/obj/item/radio/uplink/nuclear/Destroy()
GLOB.nuclear_uplink_list -= src
return ..()
/obj/item/radio/uplink/sst/New()
..()
if(hidden_uplink)
hidden_uplink.uplink_type = "sst"
/obj/item/multitool/uplink/New()
hidden_uplink = new(src)
@@ -333,4 +351,4 @@ var/list/world_uplinks = list()
/obj/item/radio/headset/uplink/New()
..()
hidden_uplink = new(src)
hidden_uplink.uses = 20
hidden_uplink.uses = 20
+1 -1
View File
@@ -47,4 +47,4 @@
H.reagents.add_reagent(poison_type, poison_dose)
poison_total -= poison_dose
add_attack_logs(src, user, "Picked up [src], the trapped syndicate documents")
..()
return ..()
+40 -4
View File
@@ -21,7 +21,7 @@
user.visible_message("<span class='notice'>[user] [rolled ? "rolls up" : "unfurls"] [src].</span>", "<span class='notice'>You [rolled ? "roll up" : "unfurl"] [src].</span>", "<span class='warning'>You hear fabric rustling.</span>")
update_icon()
/obj/item/flag/fire_act(global_overlay = FALSE)
/obj/item/flag/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = FALSE)
..()
update_icon()
@@ -205,6 +205,8 @@
origin_tech = "syndicate=4;magnets=4"
var/updated_icon_state = null
var/used = FALSE
var/obj/item/grenade/boobytrap = null
var/mob/trapper = null
/obj/item/flag/chameleon/New()
updated_icon_state = icon_state
@@ -214,7 +216,7 @@
if(used)
return ..()
var/list/flag_types = typesof(/obj/item/flag) - list(src.type, /obj/item/flag)
var/list/flag_types = typesof(/obj/item/flag) - list(/obj/item/flag, /obj/item/flag/chameleon, /obj/item/flag/chameleon/depot)
var/list/flag = list()
for(var/flag_type in flag_types)
@@ -236,9 +238,43 @@
desc = chosen_flag.desc
used = TRUE
/obj/item/flag/chameleon/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/grenade) && !boobytrap)
if(user.drop_item())
boobytrap = I
trapper = user
I.forceMove(src)
to_chat(user, "<span class='notice'>You hide [I] in the [src]. It will detonate some time after the flag is lit on fire.</span>")
var/turf/bombturf = get_turf(src)
var/area/A = get_area(bombturf)
message_admins("[key_name_admin(user)] has hidden [I] in the [src] ready for detonation at <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[bombturf.x];Y=[bombturf.y];Z=[bombturf.z]'>[A.name] (JMP)</a>.")
log_game("[key_name(user)] has hidden [I] in the [src] ready for detonation at [A.name] ([bombturf.x],[bombturf.y],[bombturf.z]).")
investigate_log("[key_name(user)] has hidden [I] in the [src] ready for detonation at [A.name] ([bombturf.x],[bombturf.y],[bombturf.z]).", INVESTIGATE_BOMB)
else if(isscrewdriver(I) && boobytrap && user == trapper)
to_chat(user, "<span class='notice'>You remove [boobytrap] from the [src].</span>")
boobytrap.forceMove(get_turf(src))
boobytrap = null
trapper = null
else
..()
/obj/item/flag/chameleon/attackby(obj/item/W, mob/user, params)
if(is_hot(W) && burn_state != ON_FIRE && boobytrap && trapper)
var/turf/bombturf = get_turf(src)
var/area/A = get_area(bombturf)
message_admins("[key_name_admin(user)] has lit the [src] trapped with [boobytrap] by [key_name_admin(trapper)] at <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[bombturf.x];Y=[bombturf.y];Z=[bombturf.z]'>[A.name] (JMP)</a>.")
log_game("[key_name_admin(user)] has lit the [src] trapped with [boobytrap] by [key_name_admin(trapper)] at [A.name] ([bombturf.x],[bombturf.y],[bombturf.z]).")
investigate_log("[key_name_admin(user)] has lit the [src] trapped with [boobytrap] by [key_name_admin(trapper)] at [A.name] ([bombturf.x],[bombturf.y],[bombturf.z]).", INVESTIGATE_BOMB)
..()
/obj/item/flag/chameleon/burn()
explosion(loc,1,2,4,4, flame_range = 4)
qdel(src)
if(boobytrap)
boobytrap.prime()
..()
/obj/item/flag/chameleon/updateFlagIcon()
icon_state = updated_icon_state
/obj/item/flag/chameleon/depot/New()
..()
boobytrap = new /obj/item/grenade/gas/plasma(src)
+2 -2
View File
@@ -28,7 +28,7 @@
/obj/item/latexballon/proc/burst()
if(!air_contents || icon_state != "latexballon_blow")
return
playsound(src, 'sound/weapons/Gunshot.ogg', 100, 1)
playsound(src, 'sound/weapons/gunshots/gunshot.ogg', 100, 1)
icon_state = "latexballon_bursted"
item_state = "lgloves"
if(isliving(loc))
@@ -50,9 +50,9 @@
burst()
/obj/item/latexballon/temperature_expose(datum/gas_mixture/air, temperature, volume)
..()
if(temperature > T0C+100)
burst()
return
/obj/item/latexballon/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/tank))
@@ -5,7 +5,7 @@
var/sheets_refunded = 2
var/list/mount_reqs = list() //can contain simfloor, nospace. Used in try_build to see if conditions are needed, then met
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
usesound = 'sound/items/deconstruct.ogg'
/obj/item/mounted/frame/attackby(obj/item/W, mob/user)
..()
+40 -58
View File
@@ -9,8 +9,7 @@
var/list/types = list(/obj/item/gun/projectile/shotgun/toy/crossbow, /obj/item/toy/balloon,/obj/item/toy/spinningtoy,/obj/item/reagent_containers/spray/waterflower) + subtypesof(/obj/item/toy/prize)
var/T = pick(types)
new T(loc)
spawn(1)
qdel(src)
qdel(src)
// -------------------------------------
// Random cleanables, clearly this makes sense
@@ -24,8 +23,7 @@
var/list/list = subtypesof(/obj/effect/decal/cleanable) - list(/obj/effect/decal/cleanable/random,/obj/effect/decal/cleanable/cobweb,/obj/effect/decal/cleanable/cobweb2)
var/T = pick(list)
new T(loc)
spawn(0)
qdel(src)
qdel(src)
/obj/item/stack/sheet/animalhide/random
@@ -33,11 +31,10 @@
/obj/item/stack/sheet/animalhide/random/New()
..()
spawn(1)
var/htype = pick(/obj/item/stack/sheet/animalhide/cat,/obj/item/stack/sheet/animalhide/corgi,/obj/item/stack/sheet/animalhide/human,/obj/item/stack/sheet/animalhide/lizard,/obj/item/stack/sheet/animalhide/monkey)
var/obj/item/stack/S = new htype(loc)
S.amount = amount
qdel(src)
var/htype = pick(/obj/item/stack/sheet/animalhide/cat,/obj/item/stack/sheet/animalhide/corgi,/obj/item/stack/sheet/animalhide/human,/obj/item/stack/sheet/animalhide/lizard,/obj/item/stack/sheet/animalhide/monkey)
var/obj/item/stack/S = new htype(loc)
S.amount = amount
qdel(src)
// -------------------------------------
// Not yet identified chemical.
@@ -121,12 +118,12 @@
icon_state = pick("alco-white","alco-green","alco-blue","alco-clear","alco-red")
pixel_x = rand(-5, 5)
pixel_y = rand(-5, 5)
spawn(0)
qdel(src)
qdel(src)
/obj/item/storage/pill_bottle/random_meds
name = "unlabelled pillbottle"
desc = "The sheer recklessness of this bottle's existence astounds you."
var/labelled = FALSE
/obj/item/storage/pill_bottle/random_meds/New()
..()
@@ -141,11 +138,19 @@
P.reagents.add_reagent(R, 10)
else
P.reagents.add_reagent(R, rand(2, 5)*10)
P.name = "Unlabelled Pill"
P.desc = "Something about this pill entices you to try it, against your better judgement."
if(labelled)
P.name = "[R] Pill"
P.desc = "A pill containing [R]."
else
P.name = "Unlabelled Pill"
P.desc = "Something about this pill entices you to try it, against your better judgement."
pixel_x = rand(-10, 10)
pixel_y = rand(-10, 10)
/obj/item/storage/pill_bottle/random_meds/labelled
name = "variety pillbottle"
labelled = TRUE
// -------------------------------------
// Containers full of unknown crap
@@ -158,16 +163,10 @@
/obj/structure/closet/crate/secure/unknownchemicals/New()
..()
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_chem(src)
new/obj/item/reagent_containers/glass/bottle/random_chem(src)
for(var/i in 1 to 7)
new/obj/item/reagent_containers/glass/bottle/random_base_chem(src)
for(var/i in 1 to 3)
new/obj/item/reagent_containers/glass/bottle/random_chem(src)
while(prob(50))
new/obj/item/reagent_containers/glass/bottle/random_reagent(src)
@@ -193,7 +192,7 @@
B.name = "unlabelled bottle"
B.desc = "Looks like the label fell off."
// B.identify_probability = 0
//
/*
/obj/structure/closet/crate/bin/flowers
name = "flower barrel"
@@ -243,11 +242,8 @@
/obj/structure/closet/secure_closet/random_drinks/New()
..()
new/obj/item/reagent_containers/food/drinks/bottle/random_drink(src)
new/obj/item/reagent_containers/food/drinks/bottle/random_drink(src)
new/obj/item/reagent_containers/food/drinks/bottle/random_drink(src)
new/obj/item/reagent_containers/food/drinks/bottle/random_drink(src)
new/obj/item/reagent_containers/food/drinks/bottle/random_drink(src)
for(var/i in 1 to 5)
new/obj/item/reagent_containers/food/drinks/bottle/random_drink(src)
while(prob(25))
new/obj/item/reagent_containers/food/drinks/bottle/random_reagent(src)
@@ -272,12 +268,12 @@
visible_message("<span class='warning'>Something falls out of the [src]!</span>")
var/obj/item/grenade/clusterbuster/C = new(src.loc)
C.prime()
spawn(10)
new menace(src.loc)
while(prob(15))
new menace(get_step_rand(src.loc))
..()
return 1
sleep(10)
new menace(src.loc)
while(prob(15))
new menace(get_step_rand(src.loc))
..()
return TRUE
else
return ..()
@@ -296,19 +292,15 @@
/obj/structure/largecrate/schrodinger/attackby(obj/item/W as obj, mob/user as mob, params)
if(istype(W, /obj/item/crowbar))
var/mob/living/simple_animal/pet/cat/Cat1 = new(loc)
Cat1.apply_damage(250)//,TOX)
Cat1.name = "Schrodinger's Cat"
Cat1.desc = "It seems it's been dead for a while."
var/mob/living/simple_animal/pet/cat/Cat2 = new(loc)
Cat2.name = "Schrodinger's Cat"
Cat2.desc = "It's was alive the whole time!"
sleep(2)
var/mob/living/simple_animal/pet/cat/Cat = new(loc)
Cat.name = "Schrodinger's Cat"
if(prob(50))
qdel(Cat1)
Cat.apply_damage(250,TOX)
Cat.desc = "It seems it's been dead for a while."
else
qdel(Cat2)
Cat.desc = "It was alive the whole time!"
return ..()
// --------------------------------------
@@ -326,16 +318,6 @@
/obj/item/storage/box/grenades/New()
..()
var/nade1 = pick(grenadelist)
var/nade2 = pick(grenadelist)
var/nade3 = pick(grenadelist)
var/nade4 = pick(grenadelist)
var/nade5 = pick(grenadelist)
var/nade6 = pick(grenadelist)
new nade1(src)
new nade2(src)
new nade3(src)
new nade4(src)
new nade5(src)
new nade6(src)
for(var/i in 1 to 6)
var/nade = pick(grenadelist)
new nade(src)
+2 -2
View File
@@ -13,7 +13,7 @@
if(ishuman(M))
var/mob/living/carbon/human/H = M
if(H.check_shields(0, "[M]'s [name]", src, MELEE_ATTACK))
playsound(M, 'sound/weapons/Genhit.ogg', 50, 1)
playsound(M, 'sound/weapons/genhit.ogg', 50, 1)
return 0
if(isrobot(user))
@@ -28,7 +28,7 @@
M.visible_message("<span class='danger'>[user] has prodded [M] with [src]!</span>", \
"<span class='userdanger'>[user] has prodded you with [src]!</span>")
playsound(loc, 'sound/weapons/Egloves.ogg', 50, 1, -1)
playsound(loc, 'sound/weapons/egloves.ogg', 50, 1, -1)
add_attack_logs(user, M, "Stunned with [src] (INTENT: [uppertext(user.a_intent)])")
/obj/item/borg/overdrive
+57 -56
View File
@@ -9,75 +9,76 @@
var/icon/virtualIcon
var/list/bulletholes = list()
Destroy()
// if a target is deleted and associated with a stake, force stake to forget
for(var/obj/structure/target_stake/T in view(3,src))
if(T.pinned_target == src)
T.pinned_target = null
T.density = 1
break
return ..() // delete target
/obj/item/target/Destroy()
// if a target is deleted and associated with a stake, force stake to forget
for(var/obj/structure/target_stake/T in view(3,src))
if(T.pinned_target == src)
T.pinned_target = null
T.density = 1
break
return ..() // delete target
Move()
..()
// After target moves, check for nearby stakes. If associated, move to target
for(var/obj/structure/target_stake/M in view(3,src))
if(M.density == 0 && M.pinned_target == src)
M.loc = loc
/obj/item/target/Move()
..()
// After target moves, check for nearby stakes. If associated, move to target
for(var/obj/structure/target_stake/M in view(3,src))
if(M.density == 0 && M.pinned_target == src)
M.loc = loc
// This may seem a little counter-intuitive but I assure you that's for a purpose.
// Stakes are the ones that carry targets, yes, but in the stake code we set
// a stake's density to 0 meaning it can't be pushed anymore. Instead of pushing
// the stake now, we have to push the target.
// This may seem a little counter-intuitive but I assure you that's for a purpose.
// Stakes are the ones that carry targets, yes, but in the stake code we set
// a stake's density to 0 meaning it can't be pushed anymore. Instead of pushing
// the stake now, we have to push the target.
attackby(obj/item/W as obj, mob/user as mob, params)
if(istype(W, /obj/item/weldingtool))
var/obj/item/weldingtool/WT = W
if(WT.remove_fuel(0, user))
overlays.Cut()
to_chat(usr, "You slice off [src]'s uneven chunks of aluminum and scorch marks.")
return
/obj/item/target/attackby(obj/item/W as obj, mob/user as mob, params)
if(istype(W, /obj/item/weldingtool))
var/obj/item/weldingtool/WT = W
if(WT.remove_fuel(0, user))
overlays.Cut()
to_chat(usr, "You slice off [src]'s uneven chunks of aluminum and scorch marks.")
return
attack_hand(mob/user as mob)
// taking pinned targets off!
var/obj/structure/target_stake/stake
for(var/obj/structure/target_stake/T in view(3,src))
if(T.pinned_target == src)
stake = T
break
/obj/item/target/attack_hand(mob/user as mob)
// taking pinned targets off!
var/obj/structure/target_stake/stake
for(var/obj/structure/target_stake/T in view(3,src))
if(T.pinned_target == src)
stake = T
break
if(stake)
if(stake.pinned_target)
stake.density = 1
density = 0
layer = OBJ_LAYER
if(stake)
if(stake.pinned_target)
stake.density = 1
density = 0
layer = OBJ_LAYER
loc = user.loc
if(ishuman(user))
if(!user.get_active_hand())
user.put_in_hands(src)
to_chat(user, "You take the target out of the stake.")
else
src.loc = get_turf(user)
loc = user.loc
if(ishuman(user))
if(!user.get_active_hand())
user.put_in_hands(src)
to_chat(user, "You take the target out of the stake.")
else
src.loc = get_turf(user)
to_chat(user, "You take the target out of the stake.")
stake.pinned_target = null
return
stake.pinned_target = null
return
else
..()
else
..()
syndicate
icon_state = "target_s"
desc = "A shooting target that looks like a syndicate scum."
hp = 2600 // i guess syndie targets are sturdier?
alien
icon_state = "target_q"
desc = "A shooting target that looks like a xenomorphic alien."
hp = 2350 // alium onest too kinda
/obj/item/target/syndicate
icon_state = "target_s"
desc = "A shooting target that looks like a syndicate scum."
hp = 2600 // i guess syndie targets are sturdier?
/obj/item/target/alien
icon_state = "target_q"
desc = "A shooting target that looks like a xenomorphic alien."
hp = 2350 // alium onest too kinda
/obj/item/target/bullet_act(var/obj/item/projectile/Proj)
var/p_x = Proj.p_x + pick(0,0,0,0,0,-1,1) // really ugly way of coding "sometimes offset Proj.p_x!"
+30 -4
View File
@@ -22,16 +22,42 @@
else
to_chat(user, "<span class='notice'>All [R]'s systems are nominal.</span>")
if(istype(M,/mob/living/carbon/human)) //Repairing robolimbs
if(istype(M,/mob/living/carbon/human)) //Repairing robotic limbs and IPCs
var/mob/living/carbon/human/H = M
var/obj/item/organ/external/S = H.get_organ(user.zone_sel.selecting)
if(S && S.is_robotic())
if(S.get_damage())
S.heal_damage(15, 15, robo_repair = 1)
use(1)
user.visible_message("<span class='notice'>\The [user] applies some nanite paste at[user != M ? " \the [M]'s" : " \the"][S.name] with \the [src].</span>",\
"<span class='notice'>You apply some nanite paste at [user == M ? "your" : "[M]'s"] [S.name].</span>")
var/remheal = 15
var/nremheal = 0
S.heal_damage(robo_repair = 1) //should in, theory, heal the robotic organs in just the targeted area with it being S instead of E
var/childlist
if(!isnull(S.children))
childlist = S.children.Copy()
var/parenthealed = FALSE
while(remheal > 0)
var/obj/item/organ/external/E
if(S.get_damage())
E = S
else if(LAZYLEN(childlist))
E = pick_n_take(childlist)
if(!E.get_damage() || !E.is_robotic())
continue
else if(S.parent && !parenthealed)
E = S.parent
parenthealed = TRUE
if(!E.get_damage() || !E.is_robotic())
break
else
break
nremheal = max(remheal - E.get_damage(), 0)
E.heal_damage(remheal, 0, 0, 1) //Healing Brute
E.heal_damage(0, remheal, 0, 1) //Healing Burn
remheal = nremheal
user.visible_message("<span class='notice'>\The [user] applies some nanite paste at \the [M]'s [E.name] with \the [src].</span>")
if(H.bleed_rate && H.isSynthetic())
H.bleed_rate = 0
else
to_chat(user, "<span class='notice'>Nothing to fix here.</span>")
else
+1 -1
View File
@@ -20,7 +20,7 @@ var/global/list/datum/stack_recipe/rod_recipes = list ( \
attack_verb = list("hit", "bludgeoned", "whacked")
hitsound = 'sound/weapons/grenadelaunch.ogg'
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
usesound = 'sound/items/deconstruct.ogg'
/obj/item/stack/rods/cyborg
materials = list()
@@ -11,6 +11,8 @@ Mineral Sheets
- Tranqillite
- Enriched Uranium
- Platinum
- Alien Alloy
- Adamantine
*/
var/global/list/datum/stack_recipe/sandstone_recipes = list ( \
@@ -102,6 +104,10 @@ var/global/list/datum/stack_recipe/abductor_recipes = list ( \
new/datum/stack_recipe("alien floor tile", /obj/item/stack/tile/mineral/abductor, 1, 4, 20), \
)
var/global/list/datum/stack_recipe/adamantine_recipes = list(
new /datum/stack_recipe("incomplete servant golem shell", /obj/item/golem_shell/servant, req_amount = 1, res_amount = 1), \
)
/obj/item/stack/sheet/mineral
force = 5
throwforce = 5
@@ -173,7 +179,8 @@ var/global/list/datum/stack_recipe/abductor_recipes = list ( \
else
return ..()
/obj/item/stack/sheet/mineral/plasma/fire_act()
/obj/item/stack/sheet/mineral/plasma/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
atmos_spawn_air(SPAWN_HEAT | SPAWN_TOXINS, amount*10)
qdel(src)
@@ -301,3 +308,16 @@ var/global/list/datum/stack_recipe/plastitanium_recipes = list (
/obj/item/stack/sheet/mineral/abductor/New(loc, amount=null)
recipes = abductor_recipes
..()
/obj/item/stack/sheet/mineral/adamantine
name = "adamantine"
desc = "A strange mineral used in the construction of sentient golems."
icon_state = "sheet-adamantine"
singular_name = "adamantine sheet"
origin_tech = "materials=5"
merge_type = /obj/item/stack/sheet/mineral/adamantine
wall_allowed = FALSE
/obj/item/stack/sheet/mineral/adamantine/New(loc, amount = null)
recipes = adamantine_recipes
..()
@@ -58,6 +58,7 @@ var/global/list/datum/stack_recipe/metal_recipes = list(
new /datum/stack_recipe("turret frame", /obj/machinery/porta_turret_construct, 5, time = 25, one_per_turf = 1, on_floor = 1),
new /datum/stack_recipe("firelock frame", /obj/structure/firelock_frame, 3, time = 50, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("meatspike frame", /obj/structure/kitchenspike_frame, 5, time = 25, one_per_turf = 1, on_floor = 1),
new /datum/stack_recipe("reflector frame", /obj/structure/reflector, 5, time = 25, one_per_turf = 1, on_floor = 1),
null,
new /datum/stack_recipe_list("airlock assemblies", list(
new /datum/stack_recipe("standard airlock assembly", /obj/structure/door_assembly, 4, time = 50, one_per_turf = 1, on_floor = 1),
@@ -128,7 +129,7 @@ var/global/list/datum/stack_recipe/metal_recipes = list(
*/
var/global/list/datum/stack_recipe/plasteel_recipes = list(
new /datum/stack_recipe("AI core", /obj/structure/AIcore, 4, time = 50, one_per_turf = 1),
new /datum/stack_recipe("bomb assembly", /obj/machinery/syndicatebomb/empty, 10, time = 50),
new /datum/stack_recipe("bomb assembly", /obj/machinery/syndicatebomb/empty, 3, time = 50),
new /datum/stack_recipe("Surgery Table", /obj/machinery/optable, 5, time = 50, one_per_turf = 1, on_floor = 1),
new /datum/stack_recipe("Metal crate", /obj/structure/closet/crate, 10, time = 50, one_per_turf = 1),
new /datum/stack_recipe("Mass Driver frame", /obj/machinery/mass_driver_frame, 3, time = 50, one_per_turf = 1),
@@ -251,6 +252,16 @@ var/global/list/datum/stack_recipe/cardboard_recipes = list (
new/datum/stack_recipe("cardboard cutout", /obj/item/cardboard_cutout, 5),
)
/obj/item/stack/sheet/cardboard/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/stamp/clown) && !istype(loc, /obj/item/storage))
var/atom/droploc = drop_location()
if(use(1))
playsound(I, 'sound/items/bikehorn.ogg', 50, 1, -1)
to_chat(user, "<span class='notice'>You stamp the cardboard! It's a clown box! Honk!</span>")
new/obj/item/storage/box/clown(droploc) //bugfix
else
. = ..()
/obj/item/stack/sheet/cardboard //BubbleWrap
name = "cardboard"
desc = "Large sheets of card, like boxes folded flat."
@@ -11,7 +11,7 @@
var/sheettype = null //this is used for girders in the creation of walls/false walls
var/created_window = null //apparently glass sheets don't share a base type for glass specifically, so each had to define these vars individually
var/full_window = null //moving the var declaration to here so this can be checked cleaner until someone is willing to make them share a base type properly
usesound = 'sound/items/Deconstruct.ogg'
usesound = 'sound/items/deconstruct.ogg'
toolspeed = 1
var/wall_allowed = TRUE //determines if sheet can be used in wall construction or not.
+13 -10
View File
@@ -231,16 +231,10 @@
if(amount < used)
return FALSE
amount -= used
if(amount < 1)
if(isrobot(loc))
var/mob/living/silicon/robot/R = loc
if(locate(src) in R.module.modules)
R.module.modules -= src
if(R)
R.unEquip(src, TRUE)
zero_amount()
if(check)
zero_amount()
update_icon()
return 1
return TRUE
/obj/item/stack/proc/get_amount()
return amount
@@ -273,7 +267,9 @@
if(!istype(user) || user.incapacitated())
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
return
if(!in_range(src, user) || issilicon(usr))
if(!in_range(src, user))
return
if(!ishuman(usr))
return
if(amount < 1)
return
@@ -305,6 +301,13 @@
/obj/item/stack/proc/zero_amount()
if(amount < 1)
if(isrobot(loc))
var/mob/living/silicon/robot/R = loc
if(locate(src) in R.module.modules)
R.module.modules -= src
if(ismob(loc))
var/mob/living/L = loc // At this stage, stack code is so horrible and atrocious, I wouldn't be all surprised ghosts can somehow have stacks. If this happens, then the world deserves to burn.
L.unEquip(src, TRUE)
qdel(src)
return TRUE
return FALSE
@@ -38,4 +38,7 @@
amount = 5
/obj/item/stack/telecrystal/twenty
amount = 20
amount = 20
/obj/item/stack/telecrystal/fifty
amount = 50
@@ -122,6 +122,10 @@ var/global/list/datum/stack_recipe/silverfancy_tile_recipes = list ( \
mineralType = "titanium"
materials = list(MAT_TITANIUM=500)
/obj/item/stack/tile/mineral/titanium/purple
turf_type = /turf/simulated/floor/mineral/titanium/purple
icon_state = "tile_plasma"
/obj/item/stack/tile/mineral/plastitanium
name = "plas-titanium tile"
singular_name = "plas-titanium floor tile"
+112 -40
View File
@@ -231,7 +231,7 @@
/obj/item/toy/katana/suicide_act(mob/user)
var/dmsg = pick("[user] tries to stab \the [src] into [user.p_their()] abdomen, but it shatters! [user.p_they(TRUE)] look[user.p_s()] as if [user.p_they()] might die from the shame.","[user] tries to stab \the [src] into [user.p_their()] abdomen, but \the [src] bends and breaks in half! [user.p_they(TRUE)] look[user.p_s()] as if [user.p_they()] might die from the shame.","[user] tries to slice [user.p_their()] own throat, but the plastic blade has no sharpness, causing [user.p_them()] to lose [user.p_their()] balance, slip over, and break [user.p_their()] neck with a loud snap!")
user.visible_message("<span class='suicide'>[dmsg] It looks like [user.p_theyre()] trying to commit suicide.</span>")
return (BRUTELOSS)
return BRUTELOSS
/*
@@ -275,7 +275,8 @@
playsound(src, 'sound/effects/snap.ogg', 50, 1)
qdel(src)
/obj/item/toy/snappop/fire_act()
/obj/item/toy/snappop/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
pop_burst()
/obj/item/toy/snappop/throw_impact(atom/hit_atom)
@@ -775,7 +776,7 @@ obj/item/toy/cards/deck/syndicate/black
user.visible_message("<span class='warning'>[user] presses a button on [src]</span>", "<span class='notice'>You activate [src], it plays a loud noise!</span>", "<span class='notice'>You hear the click of a button.</span>")
spawn(5) //gia said so
icon_state = "nuketoy"
playsound(src, 'sound/machines/Alarm.ogg', 100, 0, 0)
playsound(src, 'sound/machines/alarm.ogg', 100, 0, 0)
sleep(135)
icon_state = "nuketoycool"
sleep(cooldown - world.time)
@@ -1143,6 +1144,37 @@ obj/item/toy/cards/deck/syndicate/black
return
..()
/obj/item/toy/codex_gigas
name = "Toy Codex Gigas"
desc = "A tool to help you write fictional devils!"
icon = 'icons/obj/library.dmi'
icon_state = "demonomicon"
w_class = WEIGHT_CLASS_SMALL
var/cooldown = FALSE
/obj/item/toy/codex_gigas/attack_self(mob/user)
if(!cooldown)
user.visible_message(
"<span class='notice'>[user] presses the button on \the [src].</span>",
"<span class='notice'>You press the button on \the [src].</span>",
"<span class='notice'>You hear a soft click.</span>")
var/list/messages = list()
var/datum/devilinfo/devil = randomDevilInfo()
messages += "Some fun facts about: [devil.truename]"
messages += "[lawlorify[LORE][devil.bane]]"
messages += "[lawlorify[LORE][devil.obligation]]"
messages += "[lawlorify[LORE][devil.ban]]"
messages += "[lawlorify[LORE][devil.banish]]"
playsound(loc, 'sound/machines/click.ogg', 20, 1)
cooldown = TRUE
for(var/message in messages)
user.loc.visible_message("<span class='danger'>[bicon(src)] [message]</span>")
sleep(10)
spawn(20)
cooldown = FALSE
return
..()
/obj/item/toy/owl
name = "owl action figure"
desc = "An action figure modeled after 'The Owl', defender of justice."
@@ -1155,7 +1187,7 @@ obj/item/toy/cards/deck/syndicate/black
if(!cooldown) //for the sanity of everyone
var/message = pick("You won't get away this time, Griffin!", "Stop right there, criminal!", "Hoot! Hoot!", "I am the night!")
to_chat(user, "<span class='notice'>You pull the string on the [src].</span>")
playsound(user, 'sound/misc/hoot.ogg', 25, 1)
playsound(user, 'sound/creatures/hoot.ogg', 25, 1)
visible_message("<span class='danger'>[bicon(src)] [message]</span>")
cooldown = 1
spawn(30) cooldown = 0
@@ -1174,7 +1206,7 @@ obj/item/toy/cards/deck/syndicate/black
if(!cooldown) //for the sanity of everyone
var/message = pick("You can't stop me, Owl!", "My plan is flawless! The vault is mine!", "Caaaawwww!", "You will never catch me!")
to_chat(user, "<span class='notice'>You pull the string on the [src].</span>")
playsound(user, 'sound/misc/caw.ogg', 25, 1)
playsound(user, 'sound/creatures/caw.ogg', 25, 1)
visible_message("<span class='danger'>[bicon(src)] [message]</span>")
cooldown = 1
spawn(30) cooldown = 0
@@ -1340,54 +1372,84 @@ obj/item/toy/cards/deck/syndicate/black
force = 5
origin_tech = "combat=1"
attack_verb = list("struck", "hit", "bashed")
var/bullet_position = 1
var/bullets_left = 0
var/max_shots = 6
/obj/item/toy/russian_revolver/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] quickly loads six bullets into [src]'s cylinder and points it at [user.p_their()] head before pulling the trigger! It looks like [user.p_theyre()] trying to commit suicide.</span>")
playsound(loc, 'sound/weapons/Gunshot.ogg', 50, 1)
return (BRUTELOSS)
playsound(loc, 'sound/weapons/gunshots/gunshot_strong.ogg', 50, 1)
return BRUTELOSS
/obj/item/toy/russian_revolver/New()
spin_cylinder()
..()
spin_cylinder()
/obj/item/toy/russian_revolver/attack_self(mob/user)
if(!bullet_position)
user.visible_message("<span class='warning'>[user] loads a bullet into [src]'s cylinder.</span>")
bullet_position = 1
else
if(!bullets_left)
user.visible_message("<span class='warning'>[user] loads a bullet into [src]'s cylinder before spinning it.</span>")
spin_cylinder()
user.visible_message("<span class='warning'>[user] spins the cylinder on [src]!</span>")
/obj/item/toy/russian_revolver/attack(mob/living/carbon/human/M, mob/living/carbon/human/user)
if(M != user) //can't use this on other people
return ..()
if(!bullet_position)
to_chat(user, "<span class='notice'>[src] is empty.</span>")
return
if(!(user.has_organ("head"))) //For sanity
to_chat(user, "<span class='notice'>Playing this game without a head would be classed as cheating.</span>")
return
user.visible_message("<span class='danger'>[user] points [src] at [user.p_their()] head, ready to pull the trigger!</span>")
if(do_after(user, 30, target = user))
if(bullet_position > 1)
user.visible_message("<span class='danger'>*click*</span>")
playsound(src, 'sound/weapons/empty.ogg', 100, 1)
bullet_position--
return
else
bullet_position = null
playsound(src, 'sound/weapons/Gunshot.ogg', 50, 1)
user.visible_message("<span class='danger'>[src] goes off!</span>")
user.apply_damage(200, BRUTE, "head", sharp = 1, used_weapon = "Self-inflicted gunshot wound to the head.")
user.death()
else
user.visible_message("<span class='danger'>[user] lowers [src] from [user.p_their()] head.</span>")
user.visible_message("<span class='warning'>[user] spins the cylinder on [src]!</span>")
spin_cylinder()
/obj/item/toy/russian_revolver/attack(mob/M, mob/living/user)
return
/obj/item/toy/russian_revolver/afterattack(atom/target, mob/user, flag, params)
if(flag)
if(target in user.contents)
return
if(!ismob(target))
return
shoot_gun(user)
/obj/item/toy/russian_revolver/proc/spin_cylinder()
bullet_position = rand(1,6)
bullets_left = rand(1, max_shots)
/obj/item/toy/russian_revolver/proc/post_shot(mob/user)
return
/obj/item/toy/russian_revolver/proc/shoot_gun(mob/living/carbon/human/user)
if(bullets_left > 1)
bullets_left--
user.visible_message("<span class='danger'>*click*</span>")
playsound(src, 'sound/weapons/empty.ogg', 100, 1)
return FALSE
if(bullets_left == 1)
bullets_left = 0
var/zone = "head"
if(!(user.has_organ(zone))) // If they somehow don't have a head.
zone = "chest"
playsound(src, 'sound/weapons/gunshots/gunshot_strong.ogg', 50, 1)
user.visible_message("<span class='danger'>[src] goes off!</span>")
post_shot(user)
user.apply_damage(300, BRUTE, zone, sharp = TRUE, used_weapon = "Self-inflicted gunshot wound to the [zone].")
user.bleed(BLOOD_VOLUME_NORMAL)
user.death() // Just in case
return TRUE
else
to_chat(user, "<span class='warning'>[src] needs to be reloaded.</span>")
return FALSE
/obj/item/toy/russian_revolver/trick_revolver
name = "\improper .357 revolver"
desc = "A suspicious revolver. Uses .357 ammo."
icon_state = "revolver"
max_shots = 1
var/fake_bullets = 0
/obj/item/toy/russian_revolver/trick_revolver/New()
..()
fake_bullets = rand(2, 7)
/obj/item/toy/russian_revolver/trick_revolver/examine(mob/user) //Sneaky sneaky
..()
to_chat(user, "Has [fake_bullets] round\s remaining.")
to_chat(user, "[fake_bullets] of those are live rounds.")
/obj/item/toy/russian_revolver/trick_revolver/post_shot(user)
to_chat(user, "<span class='danger'>[src] did look pretty dodgey!</span>")
SEND_SOUND(user, 'sound/misc/sadtrombone.ogg') //HONK
/*
* Rubber Chainsaw
*/
@@ -1650,3 +1712,13 @@ obj/item/toy/cards/deck/syndicate/black
icon_state = "conch"
use_action = "pulls the string"
possible_answers = list("Yes.", "No.", "Try asking again.", "Nothing.", "I don't think so.", "Neither.", "Maybe someday.")
/*
*Fake cuffs (honk honk)
*/
/obj/item/restraints/handcuffs/toy
desc = "Toy handcuffs. Plastic and extremely cheaply made."
throwforce = 0
breakouttime = 0
ignoresClumsy = TRUE
+6
View File
@@ -87,6 +87,12 @@
name = "bread tube"
icon_state = "tastybread"
/obj/item/trash/spentcasing
icon = 'icons/obj/ammo.dmi'
name = "bullet casing"
desc = "A spent bullet casing. Smells like cordite."
icon_state = "gshell"
/obj/item/trash/tapetrash
name = "old duct tape"
icon_state = "tape"
+10 -6
View File
@@ -46,7 +46,7 @@ GLOBAL_LIST_INIT(rcd_door_types, list(
materials = list(MAT_METAL = 30000)
origin_tech = "engineering=4;materials=2"
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
usesound = 'sound/items/deconstruct.ogg'
flags_2 = NO_MAT_REDEMPTION_2
req_access = list(access_engine)
@@ -456,20 +456,24 @@ GLOBAL_LIST_INIT(rcd_door_types, list(
/obj/item/rcd/proc/checkResource(amount, mob/user)
return matter >= amount
/obj/item/rcd/borg
canRwall = 1
var/use_multiplier = 160
/obj/item/rcd/borg/syndicate
use_multiplier = 80
/obj/item/rcd/borg/useResource(amount, mob/user)
if(!isrobot(user))
return 0
var/mob/living/silicon/robot/R = user
return R.cell.use(amount * 160)
return R.cell.use(amount * use_multiplier)
/obj/item/rcd/borg/checkResource(amount, mob/user)
if(!isrobot(user))
return 0
var/mob/living/silicon/robot/R = user
return R.cell.charge >= (amount * 160)
/obj/item/rcd/borg
canRwall = 1
return R.cell.charge >= (amount * use_multiplier)
/obj/item/rcd/proc/detonate_pulse()
audible_message("<span class='danger'><b>[src] begins to vibrate and \
+1
View File
@@ -85,6 +85,7 @@
else
icon_state = "rcl-0"
item_state = "rcl-0"
..()
/obj/item/twohanded/rcl/proc/is_empty(mob/user, loud = 1)
update_icon()
@@ -56,6 +56,7 @@
playsound(loc, 'sound/effects/spray3.ogg', 50, 1, -6)
/obj/item/bee_briefcase/attack_self(mob/user as mob)
var/bees_released
if(!bees_left)
to_chat(user, "<span class='danger'>The lack of all and any bees at this event has been somewhat of a let-down...</span>")
return
@@ -69,4 +70,5 @@
var/mob/living/simple_animal/hostile/poison/bees/syndi/B = new /mob/living/simple_animal/hostile/poison/bees/syndi(null)
B.master_and_friends = blood_list.Copy() //Doesn't automatically add the person who opens the case, so the bees will attack the user unless they gave their blood
B.forceMove(get_turf(user)) //RELEASE THE BEES!
bees_left -= 5
bees_released++
bees_left -= bees_released
+81 -46
View File
@@ -319,6 +319,10 @@
name = "agent card"
initial_access = list(access_maint_tunnels, access_vox, access_external_airlocks)
/obj/item/card/id/syndicate/command
initial_access = list(access_maint_tunnels, access_syndicate, access_syndicate_leader, access_syndicate_command, access_external_airlocks)
icon_state = "commander"
/obj/item/card/id/syndicate/afterattack(var/obj/item/O as obj, mob/user as mob, proximity)
if(!proximity)
return
@@ -329,25 +333,6 @@
to_chat(usr, "<span class='notice'>The card's microscanners activate as you pass it over \the [I], copying its access.</span>")
src.access |= I.access //Don't copy access if user isn't an antag -- to prevent metagaming
/obj/item/card/id/syndicate/proc/fake_id_photo(var/mob/living/carbon/human/H)//get_id_photo wouldn't work correctly
if(!istype(H))
return
var/storedDir = H.dir //don't want to lose track of this
var/icon/faked = new()
if(!H.equip_to_slot_if_possible(src, slot_l_store, 0, 1))
to_chat(H, "<span class='warning'>You need to empty your pockets before taking the ID picture.</span>")
return
H.dir = WEST //ensure the icon is actually the proper direction before copying it
faked.Insert(getFlatIcon(H), dir = WEST)
H.dir = SOUTH
faked.Insert(getFlatIcon(H), dir = SOUTH)
H.dir = storedDir
H.equip_to_slot_if_possible(src, slot_l_hand, 0, 1)
return faked
/obj/item/card/id/syndicate/attack_self(mob/user as mob)
if(!src.registered_name)
var t = reject_bad_name(input(user, "What name would you like to use on this card?", "Agent Card name", ishuman(user) ? user.real_name : user.name))
@@ -373,7 +358,7 @@
if("Show")
return ..()
if("Edit")
switch(input(user,"What would you like to edit on \the [src]?") in list("Name","Photo","Appearance","Sex","Age","Occupation","Money Account","Blood Type","DNA Hash","Fingerprint Hash","Reset Card"))
switch(input(user,"What would you like to edit on \the [src]?") in list("Name", "Photo", "Appearance", "Sex", "Age", "Occupation", "Money Account", "Blood Type", "DNA Hash", "Fingerprint Hash", "Reset Access", "Delete Card Information"))
if("Name")
var/new_name = reject_bad_name(input(user,"What name would you like to put on this card?","Agent Card Name", ishuman(user) ? user.real_name : user.name))
if(!Adjacent(user))
@@ -386,11 +371,14 @@
if("Photo")
if(!Adjacent(user))
return
var/icon/newphoto = fake_id_photo(user)
var/job_clothes = null
if(assignment)
job_clothes = assignment
var/icon/newphoto = get_id_photo(user, job_clothes)
if(!newphoto)
return
photo = newphoto
to_chat(user, "<span class='notice'>Photo changed.</span>")
to_chat(user, "<span class='notice'>Photo changed. Select another occupation and take a new photo if you wish to appear with different clothes.</span>")
RebuildHTML()
if("Appearance")
@@ -428,22 +416,41 @@
return
if(!choice)
return
src.icon_state = choice
icon_state = choice
switch(choice)
if("silver")
desc = "A silver card which shows honour and dedication."
if("gold")
desc = "A golden card which shows power and might."
if("clown")
desc = "Even looking at the card strikes you with deep fear."
if("mime")
desc = "..."
if("prisoner")
desc = "You are a number, you are not a free man."
if("centcom")
desc = "An ID straight from Central Command."
else
desc = "A card used to provide ID and determine access across the station."
to_chat(usr, "<span class='notice'>Appearance changed to [choice].</span>")
if("Sex")
var/new_sex = sanitize(stripped_input(user,"What sex would you like to put on this card?","Agent Card Sex", ishuman(user) ? capitalize(user.gender) : "Male", MAX_MESSAGE_LEN))
if(!Adjacent(user))
return
src.sex = new_sex
sex = new_sex
to_chat(user, "<span class='notice'>Sex changed to [new_sex].</span>")
RebuildHTML()
if("Age")
var/new_age = sanitize(stripped_input(user,"What age would you like to put on this card?","Agent Card Age","21", MAX_MESSAGE_LEN))
var/default = "21"
if(ishuman(user))
var/mob/living/carbon/human/H = user
default = H.age
var/new_age = sanitize(input(user,"What age would you like to be written on this card?","Agent Card Age", default) as text)
if(!Adjacent(user))
return
src.age = new_age
age = new_age
to_chat(user, "<span class='notice'>Age changed to [new_age].</span>")
RebuildHTML()
@@ -481,7 +488,7 @@
if(!Adjacent(user))
return
src.assignment = new_job
assignment = new_job
to_chat(user, "<span class='notice'>Occupation changed to [new_job].</span>")
UpdateName()
RebuildHTML()
@@ -503,7 +510,7 @@
var/new_blood_type = sanitize(input(user,"What blood type would you like to be written on this card?","Agent Card Blood Type",default) as text)
if(!Adjacent(user))
return
src.blood_type = new_blood_type
blood_type = new_blood_type
to_chat(user, "<span class='notice'>Blood type changed to [new_blood_type].</span>")
RebuildHTML()
@@ -517,7 +524,7 @@
var/new_dna_hash = sanitize(input(user,"What DNA hash would you like to be written on this card?","Agent Card DNA Hash",default) as text)
if(!Adjacent(user))
return
src.dna_hash = new_dna_hash
dna_hash = new_dna_hash
to_chat(user, "<span class='notice'>DNA hash changed to [new_dna_hash].</span>")
RebuildHTML()
@@ -531,26 +538,33 @@
var/new_fingerprint_hash = sanitize(input(user,"What fingerprint hash would you like to be written on this card?","Agent Card Fingerprint Hash",default) as text)
if(!Adjacent(user))
return
src.fingerprint_hash = new_fingerprint_hash
fingerprint_hash = new_fingerprint_hash
to_chat(user, "<span class='notice'>Fingerprint hash changed to [new_fingerprint_hash].</span>")
RebuildHTML()
if("Reset Card")
name = initial(name)
registered_name = initial(registered_name)
icon_state = initial(icon_state)
sex = initial(sex)
age = initial(age)
assignment = initial(assignment)
associated_account_number = initial(associated_account_number)
blood_type = initial(blood_type)
dna_hash = initial(dna_hash)
fingerprint_hash = initial(fingerprint_hash)
access = initial_access.Copy() // Initial() doesn't work on lists
registered_user = null
if("Reset Access")
var/response = alert(user, "Are you sure you want to reset access saved on the card?","Reset Access", "No", "Yes")
if(response == "Yes")
access = initial_access.Copy() // Initial() doesn't work on lists
to_chat(user, "<span class='notice'>Card access reset.</span>")
to_chat(user, "<span class='notice'>All information has been deleted from \the [src].</span>")
RebuildHTML()
if("Delete Card Information")
var/response = alert(user, "Are you sure you want to delete all information saved on the card?","Delete Card Information", "No", "Yes")
if(response == "Yes")
name = initial(name)
registered_name = initial(registered_name)
icon_state = initial(icon_state)
sex = initial(sex)
age = initial(age)
assignment = initial(assignment)
associated_account_number = initial(associated_account_number)
blood_type = initial(blood_type)
dna_hash = initial(dna_hash)
fingerprint_hash = initial(fingerprint_hash)
photo = null
registered_user = null
to_chat(user, "<span class='notice'>All information has been deleted from \the [src].</span>")
RebuildHTML()
else
..()
@@ -561,7 +575,7 @@
icon_state = "syndie"
assignment = "Syndicate Overlord"
untrackable = 1
access = list(access_syndicate, access_external_airlocks)
access = list(access_syndicate, access_syndicate_leader, access_syndicate_command, access_external_airlocks)
/obj/item/card/id/captains_spare
name = "captain's spare ID"
@@ -771,6 +785,27 @@
icon_state = "ERT_engineering"
/obj/item/card/id/ert/medic
icon_state = "ERT_medical"
/obj/item/card/id/golem
name = "Free Golem ID"
desc = "A card used to claim mining points and buy gear. Use it to mark it as yours."
icon_state = "research"
access = list(access_free_golems, access_robotics, access_clown, access_mime) //access to robots/mechs
var/registered = FALSE
/obj/item/card/id/golem/attack_self(mob/user as mob)
if(!registered && ishuman(user))
registered_name = user.real_name
SetOwnerInfo(user)
assignment = "Free Golem"
RebuildHTML()
UpdateName()
desc = "A card used to claim mining points and buy gear."
registered = TRUE
to_chat(user, "<span class='notice'>The ID is now registered as yours.</span>")
else
..()
// Decals
/obj/item/id_decal
name = "identification card decal"
+4 -3
View File
@@ -61,7 +61,8 @@ LIGHTERS ARE IN LIGHTERS.DM
return ..()
/obj/item/clothing/mask/cigarette/fire_act()
/obj/item/clothing/mask/cigarette/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
light()
/obj/item/clothing/mask/cigarette/attackby(obj/item/W as obj, mob/user as mob, params)
@@ -196,7 +197,7 @@ LIGHTERS ARE IN LIGHTERS.DM
if(is_being_smoked) // if it's being smoked, transfer reagents to the mob
var/mob/living/carbon/C = loc
for (var/datum/reagent/R in reagents.reagent_list)
reagents.trans_to(C, REAGENTS_METABOLISM)
reagents.trans_id_to(C, R.id, max(REAGENTS_METABOLISM / reagents.reagent_list.len, 0.1)) //transfer at least .1 of each chem
if(!reagents.total_volume) // There were reagents, but now they're gone
to_chat(C, "<span class='notice'>Your [name] loses its flavor.</span>")
else // else just remove some of the reagents
@@ -232,7 +233,7 @@ LIGHTERS ARE IN LIGHTERS.DM
type_butt = /obj/item/cigbutt/roach
throw_speed = 0.5
item_state = "spliffoff"
smoketime = 180
smoketime = 250
chem_volume = 100
/obj/item/clothing/mask/cigarette/rollie/New()
+1 -1
View File
@@ -100,7 +100,7 @@
icon_state = "razor"
flags = CONDUCT
w_class = WEIGHT_CLASS_TINY
usesound = 'sound/items/Welder2.ogg'
usesound = 'sound/items/welder2.ogg'
toolspeed = 1
/obj/item/razor/attack(mob/living/carbon/M as mob, mob/user as mob)
+1 -1
View File
@@ -16,7 +16,7 @@
/obj/item/gavelhammer/suicide_act(mob/user)
user.visible_message("<span class='warning'>[user] has sentenced [user.p_them()]self to death with the [src.name]! It looks like [user.p_theyre()] trying to commit suicide.</span>")
playsound(loc, 'sound/items/gavel.ogg', 50, 1, -1)
return (BRUTELOSS)
return BRUTELOSS
/obj/item/gavelblock
name = "gavel block"
+25 -12
View File
@@ -41,6 +41,10 @@
update_overlays()
update_charge()
/obj/item/defibrillator/examine(mob/user)
..(user)
to_chat(user,"<span class='notice'>Ctrl-click to remove the paddles from the defibrillator.")
/obj/item/defibrillator/proc/update_power()
if(bcell)
if(bcell.charge < paddles.revivecost)
@@ -118,11 +122,11 @@
if(safety)
safety = 0
src.visible_message("<span class='notice'>[src] beeps: Safety protocols disabled!</span>")
playsound(get_turf(src), 'sound/machines/defib_saftyOff.ogg', 50, 0)
playsound(get_turf(src), 'sound/machines/defib_saftyoff.ogg', 50, 0)
else
safety = 1
src.visible_message("<span class='notice'>[src] beeps: Safety protocols enabled!</span>")
playsound(get_turf(src), 'sound/machines/defib_saftyOn.ogg', 50, 0)
playsound(get_turf(src), 'sound/machines/defib_saftyon.ogg', 50, 0)
update_icon()
..()
@@ -279,7 +283,7 @@
user.visible_message("<span class='danger'>[user] is putting the live paddles on [user.p_their()] chest! It looks like [user.p_theyre()] trying to commit suicide.</span>")
defib.deductcharge(revivecost)
playsound(get_turf(src), 'sound/machines/defib_zap.ogg', 50, 1, -1)
return (OXYLOSS)
return OXYLOSS
/obj/item/twohanded/shockpaddles/dropped(mob/user as mob)
if(user)
@@ -294,8 +298,10 @@
return unwield(user)
/obj/item/twohanded/shockpaddles/on_mob_move(dir, mob/user)
if(defib && !(defib.Adjacent(user)))
defib.remove_paddles(user)
if(defib)
var/turf/t = get_turf(defib)
if(!t.Adjacent(user))
defib.remove_paddles(user)
/obj/item/twohanded/shockpaddles/proc/check_defib_exists(mainunit, var/mob/living/carbon/human/M, var/obj/O)
if(!mainunit || !istype(mainunit, /obj/item/defibrillator)) //To avoid weird issues from admin spawns
@@ -307,7 +313,7 @@
/obj/item/twohanded/shockpaddles/attack(mob/M, mob/user)
var/tobehealed
var/threshold = -config.health_threshold_dead
var/threshold = -HEALTH_THRESHOLD_DEAD
var/mob/living/carbon/human/H = M
if(busy)
@@ -336,6 +342,7 @@
H.emote("gasp")
if(!H.undergoing_cardiac_arrest() && (prob(10) || defib.combat)) // Your heart explodes.
H.set_heartattack(TRUE)
H.shock_internal_organs(100)
add_attack_logs(user, M, "Stunned with [src]")
defib.deductcharge(revivecost)
cooldown = 1
@@ -357,8 +364,8 @@
QDEL_NULL(ghost)
var/tplus = world.time - H.timeofdeath
var/tlimit = 3000 //past this much time the patient is unrecoverable (in deciseconds)
var/tloss = 600 //brain damage starts setting in on the patient after some time left rotting
var/tlimit = DEFIB_TIME_LIMIT * 10 //past this much time the patient is unrecoverable (in deciseconds)
var/tloss = DEFIB_TIME_LOSS * 10 //brain damage starts setting in on the patient after some time left rotting
var/total_burn = 0
var/total_brute = 0
if(do_after(user, 20 * toolspeed, target = M)) //placed on chest and short delay to shock for dramatic effect, revive time is 5sec total
@@ -386,6 +393,7 @@
update_icon()
return
H.set_heartattack(FALSE)
H.shock_internal_organs(100)
user.visible_message("<span class='boldnotice'>[defib] pings: Cardiac arrhythmia corrected.</span>")
M.visible_message("<span class='warning'>[M]'s body convulses a bit.")
playsound(get_turf(src), 'sound/machines/defib_zap.ogg', 50, 1, -1)
@@ -405,7 +413,7 @@
for(var/obj/item/organ/external/O in H.bodyparts)
total_brute += O.brute_dam
total_burn += O.burn_dam
if(total_burn <= 180 && total_brute <= 180 && !H.suiciding && !ghost && tplus < tlimit && !(NOCLONE in H.mutations) && (H.get_int_organ(/obj/item/organ/internal/heart) || H.get_int_organ(/obj/item/organ/internal/brain/slime)))
if(total_burn <= 180 && total_brute <= 180 && !H.suiciding && !ghost && tplus < tlimit && !(NOCLONE in H.mutations) && (H.mind && H.mind.is_revivable()) && (H.get_int_organ(/obj/item/organ/internal/heart) || H.get_int_organ(/obj/item/organ/internal/brain/slime)))
tobehealed = min(health + threshold, 0) // It's HILARIOUS without this min statement, let me tell you
tobehealed -= 5 //They get 5 of each type of damage healed so excessive combined damage will not immediately kill them after they get revived
H.adjustOxyLoss(tobehealed)
@@ -420,6 +428,9 @@
H.emote("gasp")
if(tplus > tloss)
H.setBrainLoss( max(0, min(99, ((tlimit - tplus) / tlimit * 100))))
H.shock_internal_organs(100)
H.med_hud_set_health()
H.med_hud_set_status()
defib.deductcharge(revivecost)
add_attack_logs(user, M, "Revived with [src]")
else
@@ -461,7 +472,7 @@
/obj/item/borg_defib/attack(mob/M, mob/user)
var/tobehealed
var/threshold = -config.health_threshold_dead
var/threshold = -HEALTH_THRESHOLD_DEAD
var/mob/living/carbon/human/H = M
if(busy)
@@ -480,6 +491,7 @@
H.Weaken(5)
if(!H.undergoing_cardiac_arrest() && prob(10)) // Your heart explodes.
H.set_heartattack(TRUE)
H.shock_internal_organs(100)
playsound(get_turf(src), 'sound/machines/defib_zap.ogg', 50, 1, -1)
H.emote("gasp")
add_attack_logs(user, M, "Stunned with [src]")
@@ -512,7 +524,7 @@
var/total_burn = 0
var/total_brute = 0
if(do_after(user, 20 * toolspeed, target = M)) //placed on chest and short delay to shock for dramatic effect, revive time is 5sec total
if(H.stat == 2)
if(H.stat == DEAD)
var/health = H.health
M.visible_message("<span class='warning'>[M]'s body convulses a bit.")
playsound(get_turf(src), "bodyfall", 50, 1)
@@ -520,7 +532,7 @@
for(var/obj/item/organ/external/O in H.bodyparts)
total_brute += O.brute_dam
total_burn += O.burn_dam
if(total_burn <= 180 && total_brute <= 180 && !H.suiciding && !ghost && tplus < tlimit && !(NOCLONE in H.mutations))
if(total_burn <= 180 && total_brute <= 180 && !H.suiciding && !ghost && tplus < tlimit && !(NOCLONE in H.mutations) && (H.mind && H.mind.is_revivable()))
tobehealed = min(health + threshold, 0) // It's HILARIOUS without this min statement, let me tell you
tobehealed -= 5 //They get 5 of each type of damage healed so excessive combined damage will not immediately kill them after they get revived
H.adjustOxyLoss(tobehealed)
@@ -535,6 +547,7 @@
H.emote("gasp")
if(tplus > tloss)
H.setBrainLoss( max(0, min(99, ((tlimit - tplus) / tlimit * 100))))
H.shock_internal_organs(100)
if(isrobot(user))
var/mob/living/silicon/robot/R = user
R.cell.use(revivecost)
+1
View File
@@ -3,6 +3,7 @@
desc = "Contains all the luck you'll ever need."
icon = 'icons/obj/dice.dmi'
icon_state = "dicebag"
can_hold = list(/obj/item/dice)
/obj/item/storage/pill_bottle/dice/New()
..()
+126 -122
View File
@@ -12,16 +12,18 @@
origin_tech = "biotech=1"
var/damage_coeff = 1
var/used = 0
var/used = FALSE
// USE ONLY IN PREMADE SYRINGES. WILL NOT WORK OTHERWISE.
var/datatype = 0
var/value = 0
var/forcedmutation = FALSE //Will it give the mutation, guaranteed?
/obj/item/dnainjector/New()
/obj/item/dnainjector/Initialize()
. = ..()
if(datatype && block)
buf=new
buf.dna=new
buf = new
buf.dna = new
buf.types = datatype
buf.dna.ResetSE()
SetValue(value)
@@ -30,53 +32,56 @@
QDEL_NULL(buf)
return ..()
/obj/item/dnainjector/proc/GetRealBlock(var/selblock)
if(selblock==0)
/obj/item/dnainjector/proc/GetRealBlock(selblock)
if(selblock == 0)
return block
else
return selblock
/obj/item/dnainjector/proc/GetState(var/selblock=0)
var/real_block=GetRealBlock(selblock)
if(buf.types&DNA2_BUF_SE)
/obj/item/dnainjector/proc/GetState(selblock = 0)
var/real_block = GetRealBlock(selblock)
if(buf.types & DNA2_BUF_SE)
return buf.dna.GetSEState(real_block)
else
return buf.dna.GetUIState(real_block)
/obj/item/dnainjector/proc/SetState(var/on, var/selblock=0)
var/real_block=GetRealBlock(selblock)
if(buf.types&DNA2_BUF_SE)
/obj/item/dnainjector/proc/SetState(on, selblock = 0)
var/real_block = GetRealBlock(selblock)
if(buf.types & DNA2_BUF_SE)
return buf.dna.SetSEState(real_block,on)
else
return buf.dna.SetUIState(real_block,on)
/obj/item/dnainjector/proc/GetValue(var/selblock=0)
var/real_block=GetRealBlock(selblock)
if(buf.types&DNA2_BUF_SE)
/obj/item/dnainjector/proc/GetValue(selblock = 0)
var/real_block = GetRealBlock(selblock)
if(buf.types & DNA2_BUF_SE)
return buf.dna.GetSEValue(real_block)
else
return buf.dna.GetUIValue(real_block)
/obj/item/dnainjector/proc/SetValue(var/val,var/selblock=0)
var/real_block=GetRealBlock(selblock)
if(buf.types&DNA2_BUF_SE)
/obj/item/dnainjector/proc/SetValue(val, selblock = 0)
var/real_block = GetRealBlock(selblock)
if(buf.types & DNA2_BUF_SE)
return buf.dna.SetSEValue(real_block,val)
else
return buf.dna.SetUIValue(real_block,val)
/obj/item/dnainjector/proc/inject(mob/living/M as mob, mob/user as mob)
/obj/item/dnainjector/proc/inject(mob/living/M, mob/user)
if(used)
return
if(istype(M,/mob/living))
M.apply_effect(rand(20/(damage_coeff ** 2),50/(damage_coeff ** 2)),IRRADIATE,0,1)
M.apply_effect(rand(20 / (damage_coeff ** 2), 50 / (damage_coeff ** 2)), IRRADIATE, 0, 1)
var/mob/living/carbon/human/H
if(istype(M, /mob/living/carbon/human))
H = M
if(!buf)
log_runtime(EXCEPTION("[src] used by [user] on [M] failed to initialize properly."), src)
return
spawn(0) //Some mutations have sleeps in them, like monkey
if(!(NOCLONE in M.mutations) && !(H && (NO_DNA in H.dna.species.species_traits))) // prevents drained people from having their DNA changed
var/prev_ue = M.dna.unique_enzymes
var/mutflags = 0
// UI in syringe.
if(buf.types & DNA2_BUF_UI)
if(!block) //isolated block?
@@ -93,35 +98,34 @@
M.dna.SetUIValue(block,src.GetValue())
M.UpdateAppearance()
if(buf.types & DNA2_BUF_SE)
mutflags = MUTCHK_FORCED
if(!block) //isolated block?
M.dna.SE = buf.dna.SE.Copy()
M.dna.UpdateSE()
else
M.dna.SetSEValue(block,src.GetValue())
domutcheck(M, null, mutflags)
domutcheck(M, null, forcedmutation ? MUTCHK_FORCED : 0)
M.update_mutations()
if(H)
H.sync_organ_dna(assimilate = 0, old_ue = prev_ue)
/obj/item/dnainjector/attack(mob/M as mob, mob/user as mob)
/obj/item/dnainjector/attack(mob/M, mob/user)
if(used)
to_chat(user, "<span class='warning'>This injector is used up!</span>")
return
if(!M.dna) //You know what would be nice? If the mob you're injecting has DNA, and so doesn't cause runtimes.
return 0
return FALSE
if(ishuman(M)) // Would've done this via species instead of type, but the basic mob doesn't have a species, go figure.
var/mob/living/carbon/human/H = M
if(NO_DNA in H.dna.species.species_traits)
return 0
return FALSE
if(!user.IsAdvancedToolUser())
return 0
return FALSE
var/attack_log = "injected with the Isolated [name]"
if(buf.types & DNA2_BUF_SE)
if(buf && buf.types & DNA2_BUF_SE)
if(block)
if(GetState() && block == MONKEYBLOCK && ishuman(M))
attack_log = "injected with the Isolated [name] (MONKEY)"
@@ -149,7 +153,7 @@
M.LAssailant = user
inject(M, user)
used = 1
used = TRUE
icon_state = "dnainjector0"
desc += " This one is used up."
@@ -158,9 +162,9 @@
desc = "This will make you big and strong, but give you a bad skin condition."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/hulkmut/New()
/obj/item/dnainjector/hulkmut/Initialize()
block = HULKBLOCK
..()
@@ -169,9 +173,9 @@
desc = "Cures green skin."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antihulk/New()
/obj/item/dnainjector/antihulk/Initialize()
block = HULKBLOCK
..()
@@ -180,9 +184,9 @@
desc = "Finally you can see what the Captain does."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 8
forcedmutation = TRUE
/obj/item/dnainjector/xraymut/New()
/obj/item/dnainjector/xraymut/Initialize()
block = XRAYBLOCK
..()
@@ -191,9 +195,9 @@
desc = "It will make you see harder."
datatype = DNA2_BUF_SE
value = 0x001
//block = 8
forcedmutation = TRUE
/obj/item/dnainjector/antixray/New()
/obj/item/dnainjector/antixray/Initialize()
block = XRAYBLOCK
..()
@@ -202,9 +206,9 @@
desc = "Gives you fire."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 10
forcedmutation = TRUE
/obj/item/dnainjector/firemut/New()
/obj/item/dnainjector/firemut/Initialize()
block = FIREBLOCK
..()
@@ -213,9 +217,9 @@
desc = "Cures fire."
datatype = DNA2_BUF_SE
value = 0x001
//block = 10
forcedmutation = TRUE
/obj/item/dnainjector/antifire/New()
/obj/item/dnainjector/antifire/Initialize()
block = FIREBLOCK
..()
@@ -224,9 +228,9 @@
desc = "Super brain man!"
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 12
forcedmutation = TRUE
/obj/item/dnainjector/telemut/New()
/obj/item/dnainjector/telemut/Initialize()
block = TELEBLOCK
..()
@@ -240,9 +244,9 @@
desc = "Will make you not able to control your mind."
datatype = DNA2_BUF_SE
value = 0x001
//block = 12
forcedmutation = TRUE
/obj/item/dnainjector/antitele/New()
/obj/item/dnainjector/antitele/Initialize()
block = TELEBLOCK
..()
@@ -251,9 +255,9 @@
desc = "Hold your breath and count to infinity."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/nobreath/New()
/obj/item/dnainjector/nobreath/Initialize()
block = BREATHLESSBLOCK
..()
@@ -262,9 +266,9 @@
desc = "Hold your breath and count to 100."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antinobreath/New()
/obj/item/dnainjector/antinobreath/Initialize()
block = BREATHLESSBLOCK
..()
@@ -273,9 +277,9 @@
desc = "Stare into the distance for a reason."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/remoteview/New()
/obj/item/dnainjector/remoteview/Initialize()
block = REMOTEVIEWBLOCK
..()
@@ -284,9 +288,9 @@
desc = "Cures green skin."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antiremoteview/New()
/obj/item/dnainjector/antiremoteview/Initialize()
block = REMOTEVIEWBLOCK
..()
@@ -295,9 +299,9 @@
desc = "Healthy but hungry."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/regenerate/New()
/obj/item/dnainjector/regenerate/Initialize()
block = REGENERATEBLOCK
..()
@@ -306,9 +310,9 @@
desc = "Sickly but sated."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antiregenerate/New()
/obj/item/dnainjector/antiregenerate/Initialize()
block = REGENERATEBLOCK
..()
@@ -317,9 +321,9 @@
desc = "Running Man."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/runfast/New()
/obj/item/dnainjector/runfast/Initialize()
block = INCREASERUNBLOCK
..()
@@ -328,9 +332,9 @@
desc = "Walking Man."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antirunfast/New()
/obj/item/dnainjector/antirunfast/Initialize()
block = INCREASERUNBLOCK
..()
@@ -339,9 +343,9 @@
desc = "A total makeover."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/morph/New()
/obj/item/dnainjector/morph/Initialize()
block = MORPHBLOCK
..()
@@ -350,9 +354,9 @@
desc = "Cures identity crisis."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antimorph/New()
/obj/item/dnainjector/antimorph/Initialize()
block = MORPHBLOCK
..()
@@ -361,9 +365,9 @@
desc = "Better than a pair of budget insulated gloves."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/noprints/New()
/obj/item/dnainjector/noprints/Initialize()
block = NOPRINTSBLOCK
..()
@@ -372,9 +376,9 @@
desc = "Not quite as good as a pair of budget insulated gloves."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antinoprints/New()
/obj/item/dnainjector/antinoprints/Initialize()
block = NOPRINTSBLOCK
..()
@@ -383,9 +387,9 @@
desc = "Better than a pair of real insulated gloves."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/insulation/New()
/obj/item/dnainjector/insulation/Initialize()
block = SHOCKIMMUNITYBLOCK
..()
@@ -394,9 +398,9 @@
desc = "Not quite as good as a pair of real insulated gloves."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antiinsulation/New()
/obj/item/dnainjector/antiinsulation/Initialize()
block = SHOCKIMMUNITYBLOCK
..()
@@ -405,9 +409,9 @@
desc = "Makes you shrink."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/midgit/New()
/obj/item/dnainjector/midgit/Initialize()
block = SMALLSIZEBLOCK
..()
@@ -416,9 +420,9 @@
desc = "Makes you grow. But not too much."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antimidgit/New()
/obj/item/dnainjector/antimidgit/Initialize()
block = SMALLSIZEBLOCK
..()
@@ -428,9 +432,9 @@
desc = "Toss away those glasses!"
datatype = DNA2_BUF_SE
value = 0x001
//block = 1
forcedmutation = TRUE
/obj/item/dnainjector/antiglasses/New()
/obj/item/dnainjector/antiglasses/Initialize()
block = GLASSESBLOCK
..()
@@ -439,9 +443,9 @@
desc = "Will make you need dorkish glasses."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 1
forcedmutation = TRUE
/obj/item/dnainjector/glassesmut/New()
/obj/item/dnainjector/glassesmut/Initialize()
block = GLASSESBLOCK
..()
@@ -450,9 +454,9 @@
desc = "Shake shake shake the room!"
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 3
forcedmutation = TRUE
/obj/item/dnainjector/epimut/New()
/obj/item/dnainjector/epimut/Initialize()
block = EPILEPSYBLOCK
..()
@@ -461,9 +465,9 @@
desc = "Will fix you up from shaking the room."
datatype = DNA2_BUF_SE
value = 0x001
//block = 3
forcedmutation = TRUE
/obj/item/dnainjector/antiepi/New()
/obj/item/dnainjector/antiepi/Initialize()
block = EPILEPSYBLOCK
..()
@@ -472,9 +476,9 @@
desc = "Will stop that awful noise."
datatype = DNA2_BUF_SE
value = 0x001
//block = 5
forcedmutation = TRUE
/obj/item/dnainjector/anticough/New()
/obj/item/dnainjector/anticough/Initialize()
block = COUGHBLOCK
..()
@@ -483,9 +487,9 @@
desc = "Will bring forth a sound of horror from your throat."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 5
forcedmutation = TRUE
/obj/item/dnainjector/coughmut/New()
/obj/item/dnainjector/coughmut/Initialize()
block = COUGHBLOCK
..()
@@ -494,9 +498,9 @@
desc = "Makes clumsy minions."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 6
forcedmutation = TRUE
/obj/item/dnainjector/clumsymut/New()
/obj/item/dnainjector/clumsymut/Initialize()
block = CLUMSYBLOCK
..()
@@ -505,9 +509,9 @@
desc = "Cleans up confusion."
datatype = DNA2_BUF_SE
value = 0x001
//block = 6
forcedmutation = TRUE
/obj/item/dnainjector/anticlumsy/New()
/obj/item/dnainjector/anticlumsy/Initialize()
block = CLUMSYBLOCK
..()
@@ -516,9 +520,9 @@
desc = "Will cure tourrets."
datatype = DNA2_BUF_SE
value = 0x001
//block = 7
forcedmutation = TRUE
/obj/item/dnainjector/antitour/New()
/obj/item/dnainjector/antitour/Initialize()
block = TWITCHBLOCK
..()
@@ -527,9 +531,9 @@
desc = "Gives you a nasty case off tourrets."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 7
forcedmutation = TRUE
/obj/item/dnainjector/tourmut/New()
/obj/item/dnainjector/tourmut/Initialize()
block = TWITCHBLOCK
..()
@@ -538,9 +542,9 @@
desc = "Makes you s-s-stuttterrr"
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 9
forcedmutation = TRUE
/obj/item/dnainjector/stuttmut/New()
/obj/item/dnainjector/stuttmut/Initialize()
block = NERVOUSBLOCK
..()
@@ -550,9 +554,9 @@
desc = "Fixes that speaking impairment."
datatype = DNA2_BUF_SE
value = 0x001
//block = 9
forcedmutation = TRUE
/obj/item/dnainjector/antistutt/New()
/obj/item/dnainjector/antistutt/Initialize()
block = NERVOUSBLOCK
..()
@@ -561,9 +565,9 @@
desc = "Makes you not see anything."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 11
forcedmutation = TRUE
/obj/item/dnainjector/blindmut/New()
/obj/item/dnainjector/blindmut/Initialize()
block = BLINDBLOCK
..()
@@ -572,9 +576,9 @@
desc = "ITS A MIRACLE!!!"
datatype = DNA2_BUF_SE
value = 0x001
//block = 11
forcedmutation = TRUE
/obj/item/dnainjector/antiblind/New()
/obj/item/dnainjector/antiblind/Initialize()
block = BLINDBLOCK
..()
@@ -583,9 +587,9 @@
desc = "Super brain man!"
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 12
forcedmutation = TRUE
/obj/item/dnainjector/telemut/New()
/obj/item/dnainjector/telemut/Initialize()
block = TELEBLOCK
..()
@@ -594,9 +598,9 @@
desc = "Will make you not able to control your mind."
datatype = DNA2_BUF_SE
value = 0x001
//block = 12
forcedmutation = TRUE
/obj/item/dnainjector/antitele/New()
/obj/item/dnainjector/antitele/Initialize()
block = TELEBLOCK
..()
@@ -605,9 +609,9 @@
desc = "Sorry, what did you say?"
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 13
forcedmutation = TRUE
/obj/item/dnainjector/deafmut/New()
/obj/item/dnainjector/deafmut/Initialize()
block = DEAFBLOCK
..()
@@ -616,9 +620,9 @@
desc = "Will make you hear once more."
datatype = DNA2_BUF_SE
value = 0x001
//block = 13
forcedmutation = TRUE
/obj/item/dnainjector/antideaf/New()
/obj/item/dnainjector/antideaf/Initialize()
block = DEAFBLOCK
..()
@@ -627,9 +631,9 @@
desc = "What you see isn't always what you get."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/hallucination/New()
/obj/item/dnainjector/hallucination/Initialize()
block = HALLUCINATIONBLOCK
..()
@@ -638,9 +642,9 @@
desc = "What you see is what you get."
datatype = DNA2_BUF_SE
value = 0x001
//block = 2
forcedmutation = TRUE
/obj/item/dnainjector/antihallucination/New()
/obj/item/dnainjector/antihallucination/Initialize()
block = HALLUCINATIONBLOCK
..()
@@ -649,9 +653,9 @@
desc = "Will make you a flea bag."
datatype = DNA2_BUF_SE
value = 0xFFF
//block = 14
forcedmutation = TRUE
/obj/item/dnainjector/h2m/New()
/obj/item/dnainjector/h2m/Initialize()
block = MONKEYBLOCK
..()
@@ -660,8 +664,8 @@
desc = "Will make you...less hairy."
datatype = DNA2_BUF_SE
value = 0x001
//block = 14
forcedmutation = TRUE
/obj/item/dnainjector/m2h/New()
/obj/item/dnainjector/m2h/Initialize()
block = MONKEYBLOCK
..()
..()
+14 -5
View File
@@ -109,11 +109,14 @@
message_say = "FOR THE REVOLOUTION!"
else if(role == "death commando" || role == ROLE_ERT)
message_say = "FOR NANOTRASEN!"
else if(role == ROLE_DEVIL)
message_say = "FOR INFERNO!"
user.say(message_say)
target = user
sleep(10)
prime()
user.gib()
return OBLITERATION
/obj/item/grenade/plastic/update_icon()
if(nadeassembly)
@@ -133,13 +136,16 @@
var/turf/location
if(target)
if(!QDELETED(target))
location = get_turf(target)
if(istype(target, /turf/))
location = get_turf(target) // Set the explosion location to turf if planted directly on a wall or floor
else
location = get_atom_on_turf(target) // Otherwise, make sure we're blowing up what's on top of the turf
target.overlays -= image_overlay
else
location = get_turf(src)
location = get_atom_on_turf(src)
if(location)
location.ex_act(2, target)
explosion(location,0,0,3)
location.ex_act(2, target)
if(istype(target, /mob))
var/mob/M = target
M.gib()
@@ -160,10 +166,13 @@
var/turf/location
if(target)
if(!QDELETED(target))
location = get_turf(target)
if(istype(target, /turf/))
location = get_turf(target)
else
location = get_atom_on_turf(target)
target.overlays -= image_overlay
else
location = get_turf(src)
location = get_atom_on_turf(src)
if(location)
if(target && target.density)
var/turf/T = get_step(location, aim_dir)
+1 -1
View File
@@ -168,4 +168,4 @@
/obj/item/twohanded/garrote/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] is wrapping the [src] around [user.p_their()] neck and pulling the handles! It looks like [user.p_theyre()] trying to commit suicide.</span>")
playsound(src.loc, 'sound/weapons/cablecuff.ogg', 15, 1, -1)
return (OXYLOSS)
return OXYLOSS
@@ -1,8 +1,5 @@
/obj/item/grenade/gas
name = "Plasma Fire Grenade"
name = "plasma fire grenade"
desc = "A compressed plasma grenade, used to start horrific plasma fires."
origin_tech = "materials=3;magnets=4;syndicate=3"
icon = 'icons/obj/grenade.dmi'
@@ -18,7 +15,40 @@
target_turf.air_update_turf()
qdel(src)
/obj/item/grenade/gas/plasma
icon_state = "plasma"
/obj/item/grenade/gas/knockout
name = "Knockout Grenade"
desc = "A grenade that completely removes all air and heat from its detonation area."
spawn_contents = SPAWN_20C | SPAWN_N2O
name = "knockout grenade"
desc = "A grenade that releases pure N2O gas."
spawn_contents = SPAWN_20C | SPAWN_N2O
/obj/item/grenade/gas/oxygen
name = "oxygen grenade"
desc = "A grenade that releases pure O2 gas."
icon_state = "oxygen"
spawn_contents = SPAWN_20C | SPAWN_OXYGEN
spawn_amount = 500
/obj/item/grenade/gluon
desc = "An advanced grenade that releases a harmful stream of gluons inducing radiation in those nearby. These gluon streams will also make victims feel exhausted, and induce shivering. This extreme coldness will also wet any nearby floors."
name = "gluon grenade"
icon = 'icons/obj/grenade.dmi'
icon_state = "gluon"
item_state = "flashbang"
var/range = 4
var/rad_damage = 60
var/stamina_damage = 30
/obj/item/grenade/gluon/prime()
update_mob()
playsound(loc, 'sound/effects/empulse.ogg', 50, 1)
for(var/turf/T in view(range, loc))
if(isfloorturf(T))
var/turf/simulated/F = T
F.MakeSlippery(TURF_WET_PERMAFROST)
for(var/mob/living/carbon/L in T)
L.adjustStaminaLoss(stamina_damage)
L.apply_effect(rad_damage, IRRADIATE)
L.adjust_bodytemperature(-230)
qdel(src)
@@ -11,7 +11,7 @@
var/payload_name = null // used for spawned grenades
w_class = WEIGHT_CLASS_SMALL
force = 2
var/prime_sound = 'sound/items/Screwdriver2.ogg'
var/prime_sound = 'sound/items/screwdriver2.ogg'
var/stage = EMPTY
var/list/beakers = list()
var/list/allowed_containers = list(/obj/item/reagent_containers/glass/beaker, /obj/item/reagent_containers/glass/bottle)
@@ -235,7 +235,7 @@
nadeassembly.process_movement()
/obj/item/grenade/chem_grenade/pickup()
..()
. = ..()
if(nadeassembly)
nadeassembly.process_movement()
@@ -247,9 +247,9 @@
if(nadeassembly)
nadeassembly.on_found(finder)
/obj/item/grenade/chem_grenade/hear_talk(mob/living/M, msg)
/obj/item/grenade/chem_grenade/hear_talk(mob/living/M, list/message_pieces)
if(nadeassembly)
nadeassembly.hear_talk(M, msg)
nadeassembly.hear_talk(M, message_pieces)
/obj/item/grenade/chem_grenade/hear_message(mob/living/M, msg)
if(nadeassembly)
@@ -275,7 +275,7 @@
reactants += G.reagents
if(!chem_splash(get_turf(src), affected_area, reactants, ignition_temp, threatscale) && !no_splash)
playsound(loc, 'sound/items/Screwdriver2.ogg', 50, 1)
playsound(loc, 'sound/items/screwdriver2.ogg', 50, 1)
if(beakers.len)
for(var/obj/O in beakers)
O.forceMove(get_turf(src))
@@ -526,20 +526,20 @@
update_icon()
/obj/item/grenade/chem_grenade/facid
name = "acid grenade"
desc = "Used for melting armoured opponents."
payload_name = "acid smoke"
desc = "Use to chew up opponents from the inside out."
stage = READY
/obj/item/grenade/chem_grenade/facid/New()
..()
var/obj/item/reagent_containers/glass/beaker/bluespace/B1 = new(src)
var/obj/item/reagent_containers/glass/beaker/bluespace/B2 = new(src)
var/obj/item/reagent_containers/glass/beaker/large/B1 = new(src)
var/obj/item/reagent_containers/glass/beaker/large/B2 = new(src)
B1.reagents.add_reagent("facid", 280)
B1.reagents.add_reagent("facid", 80)
B1.reagents.add_reagent("potassium", 20)
B2.reagents.add_reagent("phosphorus", 20)
B2.reagents.add_reagent("sugar", 20)
B2.reagents.add_reagent("facid", 260)
B2.reagents.add_reagent("facid", 60)
beakers += B1
beakers += B2
@@ -104,7 +104,7 @@
payload = /obj/item/grenade/chem_grenade/cleaner
/obj/item/grenade/clusterbuster/teargas
name = "Oignon Grenade"
name = "Oignon Teargas Grenade"
payload = /obj/item/grenade/chem_grenade/teargas
/obj/item/grenade/clusterbuster/facid
@@ -6,6 +6,7 @@
light_power = 10
light_color = LIGHT_COLOR_WHITE
var/light_time = 2
var/range = 7
/obj/item/grenade/flashbang/prime()
update_mob()
@@ -15,60 +16,65 @@
set_light(7)
for(var/mob/living/M in hearers(7, flashbang_turf))
bang(get_turf(M), M)
do_sparks(rand(5, 9), FALSE, src)
playsound(flashbang_turf, 'sound/effects/bang.ogg', 25, 1)
bang(flashbang_turf, range, src)
for(var/obj/structure/blob/B in hear(8,flashbang_turf)) //Blob damage here
var/damage = round(30/(get_dist(B,get_turf(src))+1))
for(var/obj/structure/blob/B in hear(8, flashbang_turf)) //Blob damage here
var/damage = round(30 / (get_dist(B, get_turf(src)) + 1))
B.health -= damage
B.update_icon()
spawn(light_time)
qdel(src)
/obj/item/grenade/flashbang/proc/bang(var/turf/T , var/mob/living/M)
M.show_message("<span class='warning'>BANG</span>", 2)
playsound(loc, 'sound/effects/bang.ogg', 25, 1)
/proc/bang(turf/T, atom/A, range = 7, flash = TRUE, bang = TRUE)
for(var/mob/living/M in hearers(range, T))
if(M.stat == DEAD)
continue
M.show_message("<span class='warning'>BANG</span>", 2)
//Checking for protections
var/ear_safety = M.check_ear_prot()
var/distance = max(1,get_dist(src,T))
//Checking for protections
var/ear_safety = M.check_ear_prot()
var/distance = max(1, get_dist(get_turf(A), get_turf(M)))
//Flash
if(M.weakeyes)
M.visible_message("<span class='disarm'><b>[M]</b> screams and collapses!</span>")
to_chat(M, "<span class='userdanger'><font size=3>AAAAGH!</font></span>")
M.Weaken(15) //hella stunned
M.Stun(15)
if(ishuman(M))
M.emote("scream")
var/mob/living/carbon/human/H = M
var/obj/item/organ/internal/eyes/E = H.get_int_organ(/obj/item/organ/internal/eyes)
if(E)
E.receive_damage(8, 1)
//Flash
if(flash)
if(M.weakeyes)
M.visible_message("<span class='disarm'><b>[M]</b> screams and collapses!</span>")
to_chat(M, "<span class='userdanger'><font size=3>AAAAGH!</font></span>")
M.Weaken(15) //hella stunned
M.Stun(15)
if(ishuman(M))
M.emote("scream")
var/mob/living/carbon/human/H = M
var/obj/item/organ/internal/eyes/E = H.get_int_organ(/obj/item/organ/internal/eyes)
if(E)
E.receive_damage(8, 1)
if(M.flash_eyes(affect_silicon = 1))
M.Stun(max(10/distance, 3))
M.Weaken(max(10/distance, 3))
if(M.flash_eyes(affect_silicon = TRUE))
M.Stun(max(10 / distance, 3))
M.Weaken(max(10 / distance, 3))
//Bang
if((loc == M) || loc == M.loc)//Holding on person or being exactly where lies is significantly more dangerous and voids protection
M.Stun(10)
M.Weaken(10)
if(!ear_safety)
M.Stun(max(10/distance, 3))
M.Weaken(max(10/distance, 3))
M.AdjustEarDamage(rand(0, 5), 15)
if(iscarbon(M))
var/mob/living/carbon/C = M
var/obj/item/organ/internal/ears/ears = C.get_int_organ(/obj/item/organ/internal/ears)
if(istype(ears))
if(ears.ear_damage >= 15)
to_chat(M, "<span class='warning'>Your ears start to ring badly!</span>")
if(prob(ears.ear_damage - 5))
to_chat(M, "<span class='warning'>You can't hear anything!</span>")
M.BecomeDeaf()
else
if(ears.ear_damage >= 5)
to_chat(M, "<span class='warning'>Your ears start to ring!</span>")
//Bang
if(bang)
if(!distance || A.loc == M || A.loc == M.loc) //Holding on person or being exactly where lies is significantly more dangerous and voids protection
M.Stun(10)
M.Weaken(10)
if(!ear_safety)
M.Stun(max(10 / distance, 3))
M.Weaken(max(10 / distance, 3))
M.AdjustEarDamage(rand(0, 5), 15)
if(iscarbon(M))
var/mob/living/carbon/C = M
var/obj/item/organ/internal/ears/ears = C.get_int_organ(/obj/item/organ/internal/ears)
if(istype(ears))
if(ears.ear_damage >= 15)
to_chat(M, "<span class='warning'>Your ears start to ring badly!</span>")
if(prob(ears.ear_damage - 5))
to_chat(M, "<span class='warning'>You can't hear anything!</span>")
M.BecomeDeaf()
else
if(ears.ear_damage >= 5)
to_chat(M, "<span class='warning'>Your ears start to ring!</span>")
@@ -0,0 +1,50 @@
/obj/item/grenade/frag
name = "frag grenade"
desc = "Fire in the hole."
icon_state = "frag"
item_state = "flashbang"
origin_tech = "materials=3;magnets=4"
var/range = 5
var/max_shrapnel = 4
var/embed_prob = 100 //reduced by armor
var/embedded_type = /obj/item/embedded/shrapnel
/obj/item/grenade/frag/prime()
update_mob()
var/turf/epicenter = get_turf(src)
for(var/mob/living/carbon/human/H in epicenter)
if(H.resting) //grenade is jumped on but get real fucked up
embed_shrapnel(H, max_shrapnel)
range = 1
explosion(loc, 0, 1, range, breach = FALSE)
for(var/turf/T in view(range, loc))
for(var/mob/living/carbon/human/H in T)
var/shrapnel_amount = max_shrapnel - T.Distance(epicenter)
if(shrapnel_amount > 0)
embed_shrapnel(H, shrapnel_amount)
qdel(src)
/obj/item/grenade/frag/proc/embed_shrapnel(mob/living/carbon/human/H, amount)
for(var/i = 0, i < amount, i++)
if(prob(embed_prob - H.getarmor(null, "bomb")))
var/obj/item/embedded/S = new embedded_type(src)
H.hitby(S, skipcatch = 1)
S.throwforce = 1
S.throw_speed = 1
S.sharp = FALSE
else
to_chat(H, "<span class='warning'>Shrapnel bounces off your armor!</span>")
/obj/item/embedded/shrapnel
name = "shrapnel"
icon = 'icons/obj/shards.dmi'
throwforce = 10
throw_speed = EMBED_THROWSPEED_THRESHOLD
embed_chance = 100
embedded_fall_chance = 0
w_class = WEIGHT_CLASS_SMALL
sharp = TRUE
hitsound = 'sound/weapons/pierce.ogg'
/obj/item/embedded/shrapnel/New()
icon_state = pick("shrapnel1", "shrapnel2", "shrapnel3")
@@ -8,5 +8,5 @@
/obj/item/grenade/syndieminibomb/prime()
update_mob()
explosion(src.loc,1,2,4,flame_range = 2)
qdel(src)
explosion(loc, 1, 2, 4, flame_range = 2)
qdel(src)
+23 -29
View File
@@ -15,6 +15,7 @@
breakouttime = 600 //Deciseconds = 60s = 1 minutes
var/cuffsound = 'sound/weapons/handcuffs.ogg'
var/trashtype = null //For disposable cuffs
var/ignoresClumsy = FALSE
/obj/item/restraints/handcuffs/attack(mob/living/carbon/C, mob/user)
if(!user.IsAdvancedToolUser())
@@ -23,13 +24,17 @@
if(!istype(C))
return
if(CLUMSY in user.mutations && prob(50))
if((CLUMSY in user.mutations) && prob(50) && (!ignoresClumsy))
to_chat(user, "<span class='warning'>Uh... how do those things work?!</span>")
apply_cuffs(user,user)
apply_cuffs(user, user)
return
cuff(C, user)
/obj/item/restraints/handcuffs/proc/cuff(mob/living/carbon/C, mob/user, remove_src = TRUE)
if(ishuman(C))
var/mob/living/carbon/human/H = C
if(!H.has_left_hand() || !H.has_right_hand())
if(!(H.has_left_hand() || H.has_right_hand()))
to_chat(user, "<span class='warning'>How do you suggest handcuffing someone with no hands?</span>")
return
@@ -39,26 +44,31 @@
playsound(loc, cuffsound, 30, 1, -2)
if(do_mob(user, C, 30))
apply_cuffs(C,user)
apply_cuffs(C, user, remove_src)
to_chat(user, "<span class='notice'>You handcuff [C].</span>")
if(istype(src, /obj/item/restraints/handcuffs/cable))
feedback_add_details("handcuffs","C")
feedback_add_details("handcuffs", "C")
else
feedback_add_details("handcuffs","H")
feedback_add_details("handcuffs", "H")
add_attack_logs(user, C, "Handcuffed ([src])")
else
to_chat(user, "<span class='warning'>You fail to handcuff [C].</span>")
/obj/item/restraints/handcuffs/proc/apply_cuffs(mob/living/carbon/target, mob/user)
/obj/item/restraints/handcuffs/proc/apply_cuffs(mob/living/carbon/target, mob/user, remove_src = TRUE)
if(!target.handcuffed)
user.drop_item()
if(remove_src)
user.drop_item()
if(trashtype)
target.handcuffed = new trashtype(target)
qdel(src)
if(remove_src)
qdel(src)
else
loc = target
target.handcuffed = src
if(remove_src)
loc = target
target.handcuffed = src
else
target.handcuffed = new type(loc)
target.update_handcuffed()
return
@@ -169,23 +179,7 @@
/obj/item/restraints/handcuffs/cable/zipties/cyborg/attack(mob/living/carbon/C, mob/user)
if(isrobot(user))
if(ishuman(C))
var/mob/living/carbon/human/H = C
if(!(H.get_organ("l_hand") || H.get_organ("r_hand")))
to_chat(user, "<span class='warning'>How do you suggest handcuffing someone with no hands?</span>")
return
if(!C.handcuffed)
playsound(loc, 'sound/weapons/cablecuff.ogg', 30, 1, -2)
C.visible_message("<span class='danger'>[user] is trying to put zipties on [C]!</span>", \
"<span class='userdanger'>[user] is trying to put zipties on [C]!</span>")
if(do_mob(user, C, 30))
if(!C.handcuffed)
C.handcuffed = new /obj/item/restraints/handcuffs/cable/zipties/used(C)
C.update_handcuffed()
to_chat(user, "<span class='notice'>You handcuff [C].</span>")
add_attack_logs(user, C, "Handcuffed (ziptie-cuffed)")
else
to_chat(user, "<span class='warning'>You fail to handcuff [C].</span>")
cuff(C, user, FALSE)
/obj/item/restraints/handcuffs/cable/zipties/used
desc = "A pair of broken zipties."
+53 -18
View File
@@ -11,10 +11,11 @@
var/reskinned = FALSE
var/reskin_selectable = TRUE //set to FALSE if a subtype is meant to not normally be available as a reskin option (fluff ones will get re-added through their list)
var/list/fluff_transformations = list() //does it have any special transformations only accessible to it? Should only be subtypes of /obj/item/nullrod
var/sanctify_force = 0
/obj/item/nullrod/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] is killing [user.p_them()]self with \the [src.name]! It looks like [user.p_theyre()] trying to get closer to god!</span>")
return (BRUTELOSS|FIRELOSS)
return BRUTELOSS|FIRELOSS
/obj/item/nullrod/attack(mob/M, mob/living/carbon/user)
..()
@@ -25,12 +26,29 @@
to_chat(M, "<span class='warning'>The nullrod's power interferes with your own!</span>")
M.mind.vampire.nullified = max(5, M.mind.vampire.nullified + 2)
/obj/item/nullrod/pickup(mob/living/user)
. = ..()
if(sanctify_force)
if(!user.mind || !user.mind.isholy)
user.adjustBruteLoss(force)
user.adjustFireLoss(sanctify_force)
user.Weaken(5)
user.unEquip(src, 1)
user.visible_message("<span class='warning'>[src] slips out of the grip of [user] as they try to pick it up, bouncing upwards and smacking [user.p_them()] in the face!</span>", \
"<span class='warning'>[src] slips out of your grip as you pick it up, bouncing upwards and smacking you in the face!</span>")
playsound(get_turf(user), 'sound/effects/hit_punch.ogg', 50, 1, -1)
throw_at(get_edge_target_turf(user, pick(alldirs)), rand(1, 3), 5)
/obj/item/nullrod/attack_self(mob/user)
if(reskinned)
return
if(user.mind && (user.mind.assigned_role == "Chaplain" || user.mind.special_role == SPECIAL_ROLE_ERT))
if(user.mind && (user.mind.isholy) && !reskinned)
reskin_holy_weapon(user)
/obj/item/nullrod/examine(mob/living/user)
. = ..()
if(sanctify_force)
to_chat(user, "<span class='notice'>It bears the inscription: 'Sanctified weapon of the inquisitors. Only the worthy may wield. Nobody shall expect us.'</span>")
/obj/item/nullrod/proc/reskin_holy_weapon(mob/M)
var/list/holy_weapons_list = typesof(/obj/item/nullrod)
for(var/entry in holy_weapons_list)
@@ -60,11 +78,27 @@
holy_weapon.reskinned = TRUE
M.unEquip(src)
M.put_in_active_hand(holy_weapon)
if(sanctify_force)
holy_weapon.sanctify_force = sanctify_force
holy_weapon.name = "sanctified " + holy_weapon.name
qdel(src)
/obj/item/nullrod/fluff //fluff subtype to be used for all donator nullrods
/obj/item/nullrod/afterattack(atom/movable/AM, mob/user, proximity)
. = ..()
if(!sanctify_force)
return
if(isliving(AM))
var/mob/living/L = AM
L.adjustFireLoss(sanctify_force) // Bonus fire damage for sanctified (ERT) versions of nullrod
/obj/item/nullrod/fluff // fluff subtype to be used for all donator nullrods
reskin_selectable = FALSE
/obj/item/nullrod/ert // ERT subtype, applies sanctified property to any derived rod
name = "inquisitor null rod"
reskin_selectable = FALSE
sanctify_force = 10
/obj/item/nullrod/godhand
name = "god hand"
icon_state = "disintegrate"
@@ -126,7 +160,7 @@
hitsound = 'sound/weapons/chainsaw.ogg'
/obj/item/nullrod/claymore/glowing
name = "force weapon"
name = "force blade"
icon_state = "swordon"
item_state = "swordon"
desc = "The blade glows with the power of faith. Or possibly a battery."
@@ -147,7 +181,7 @@
slot_flags = SLOT_BELT
/obj/item/nullrod/claymore/saber
name = "light energy sword"
name = "light energy blade"
hitsound = 'sound/weapons/blade1.ogg'
icon_state = "swordblue"
item_state = "swordblue"
@@ -155,13 +189,13 @@
slot_flags = SLOT_BELT
/obj/item/nullrod/claymore/saber/red
name = "dark energy sword"
name = "dark energy blade"
icon_state = "swordred"
item_state = "swordred"
desc = "Woefully ineffective when used on steep terrain."
/obj/item/nullrod/claymore/saber/pirate
name = "nautical energy sword"
name = "nautical energy cutlass"
icon_state = "cutlass1"
item_state = "cutlass1"
desc = "Convincing HR that your religion involved piracy was no mean feat."
@@ -279,7 +313,7 @@
/obj/item/nullrod/whip
name = "holy whip"
desc = "What a terrible night to be in spess"
desc = "A whip, blessed with the power to banish evil shadowy creatures. What a terrible night to be in spess."
icon_state = "chain"
item_state = "chain"
slot_flags = SLOT_BELT
@@ -298,11 +332,11 @@
if(is_shadow(H))
var/phrase = pick("Die monster! You don't belong in this world!!!", "You steal men's souls and make them your slaves!!!", "Your words are as empty as your soul!!!", "Mankind ill needs a savior such as you!!!")
user.say("[phrase]")
H.adjustBruteLoss(8) //Bonus damage
H.adjustBruteLoss(12) //Bonus damage
/obj/item/nullrod/fedora
name = "athiest's fedora"
desc = "The brim of the hat is as sharp as your wit. Throwing it at someone would hurt almost as much as disproving the existence of God."
name = "binary fedora"
desc = "The brim of the hat is as sharp as the division between 0 and 1. It makes a mighty throwing weapon."
icon_state = "fedora"
item_state = "fedora"
slot_flags = SLOT_HEAD
@@ -310,7 +344,7 @@
force = 0
throw_speed = 4
throw_range = 7
throwforce = 20
throwforce = 25 // Yes, this is high, since you can typically only use it once in a fight.
/obj/item/nullrod/armblade
name = "dark blessing"
@@ -335,7 +369,7 @@
/obj/item/nullrod/carp/attack_self(mob/living/user)
if(used_blessing)
return
if(user.mind && (user.mind.assigned_role != "Chaplain" && user.mind.special_role != SPECIAL_ROLE_ERT))
if(user.mind && !user.mind.isholy)
return
to_chat(user, "You are blessed by Carp-Sie. Wild space carp will no longer attack you.")
user.faction |= "carp"
@@ -408,19 +442,20 @@
if(!iscarbon(M))
return ..()
if(!user.mind || (user.mind.assigned_role != "Chaplain" && user.mind.special_role != SPECIAL_ROLE_ERT))
if(!user.mind || !user.mind.isholy)
to_chat(user, "<span class='notice'>You are not close enough with [ticker.Bible_deity_name] to use [src].</span>")
return
if(praying)
to_chat(user, "<span class='notice'>You are already using [src].</span>")
return
user.visible_message("<span class='info'>[user] kneels[M == user ? null : " next to [M]"] and begins to utter a prayer to [ticker.Bible_deity_name].</span>", \
"<span class='info'>You kneel[M == user ? null : " next to [M]"] and begin a prayer to [ticker.Bible_deity_name].</span>")
praying = 1
if(do_after(user, 150, target = M))
if(ishuman(M)) // This probably should not work on vulps. They're unholy abominations.
if(ishuman(M))
var/mob/living/carbon/human/target = M
if(target.mind)
@@ -470,7 +505,7 @@
/obj/item/nullrod/salt/attack_self(mob/user)
if(!user.mind || (user.mind.assigned_role != "Chaplain" && user.mind.special_role != SPECIAL_ROLE_ERT ))
if(!user.mind || !user.mind.isholy)
to_chat(user, "<span class='notice'>You are not close enough with [ticker.Bible_deity_name] to use [src].</span>")
return
@@ -10,6 +10,16 @@
hidden_uplink.uses = 10
..()
/obj/item/implant/uplink/sit/New()
..()
if(hidden_uplink)
hidden_uplink.uplink_type = "sit"
/obj/item/implant/uplink/admin/New()
..()
if(hidden_uplink)
hidden_uplink.uplink_type = "admin"
/obj/item/implant/uplink/implant(mob/source)
var/obj/item/implant/imp_e = locate(src.type) in source
if(imp_e && imp_e != src)
+37 -1
View File
@@ -8,12 +8,17 @@
* Butcher's cleaver
* Rolling Pins
* Candy Moulds
* Sushi Mat
* Circular cutter
*/
/obj/item/kitchen
icon = 'icons/obj/kitchen.dmi'
origin_tech = "materials=1"
/*
* Utensils
*/
@@ -116,7 +121,7 @@
user.visible_message(pick("<span class='suicide'>[user] is slitting [user.p_their()] wrists with the [src.name]! It looks like [user.p_theyre()] trying to commit suicide.</span>", \
"<span class='suicide'>[user] is slitting [user.p_their()] throat with the [src.name]! It looks like [user.p_theyre()] trying to commit suicide.</span>", \
"<span class='suicide'>[user] is slitting [user.p_their()] stomach open with the [name]! It looks like [user.p_theyre()] trying to commit seppuku.</span>"))
return (BRUTELOSS)
return BRUTELOSS
/obj/item/kitchen/knife/plastic
name = "plastic knife"
@@ -178,6 +183,7 @@
origin_tech = "biotech=3;combat=2"
attack_verb = list("shanked", "shivved")
/*
* Rolling Pins
*/
@@ -249,3 +255,33 @@
name = "sucker mould"
desc = "It has the shape of a sucker imprinted into it."
icon_state = "mould_loli"
/*
* Sushi Mat
*/
/obj/item/kitchen/sushimat
name = "Sushi Mat"
desc = "A wooden mat used for efficient sushi crafting."
icon_state = "sushi_mat"
force = 5
throwforce = 5
throw_speed = 3
throw_range = 3
w_class = WEIGHT_CLASS_SMALL
attack_verb = list("rolled", "cracked", "battered", "thrashed")
/// circular cutter by Ume
/obj/item/kitchen/cutter
name = "generic circular cutter"
desc = "A generic circular cutter for cookies and other things."
icon = 'icons/obj/kitchen.dmi'
icon_state = "circular_cutter"
force = 5
throwforce = 5
throw_speed = 3
throw_range = 3
w_class = WEIGHT_CLASS_SMALL
attack_verb = list("bashed", "slashed", "pricked", "thrashed")
+1 -1
View File
@@ -35,7 +35,7 @@
/obj/item/restraints/legcuffs/beartrap/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] is sticking [user.p_their()] head in the [name]! It looks like [user.p_theyre()] trying to commit suicide.</span>")
playsound(loc, 'sound/weapons/bladeslice.ogg', 50, 1, -1)
return (BRUTELOSS)
return BRUTELOSS
/obj/item/restraints/legcuffs/beartrap/attack_self(mob/user)
..()
+5 -4
View File
@@ -9,7 +9,7 @@
item_state = "lighter-g"
var/icon_on = "lighter-g-on"
var/icon_off = "lighter-g"
w_class = WEIGHT_CLASS_SMALL
w_class = WEIGHT_CLASS_TINY
throwforce = 4
flags = CONDUCT
slot_flags = SLOT_BELT
@@ -43,7 +43,7 @@
attack_verb = list("burnt", "singed")
if(istype(src, /obj/item/lighter/zippo) )
user.visible_message("<span class='rose'>Without even breaking stride, [user] flips open and lights [src] in one smooth movement.</span>")
playsound(src.loc, 'sound/items/ZippoLight.ogg', 25, 1)
playsound(src.loc, 'sound/items/zippolight.ogg', 25, 1)
else
if(prob(75))
user.visible_message("<span class='notice'>After a few attempts, [user] manages to light the [src].</span>")
@@ -69,7 +69,7 @@
attack_verb = null //human_defense.dm takes care of it
if(istype(src, /obj/item/lighter/zippo) )
user.visible_message("<span class='rose'>You hear a quiet click, as [user] shuts off [src] without even looking at what [user.p_theyre()] doing. Wow.")
playsound(src.loc, 'sound/items/ZippoClose.ogg', 25, 1)
playsound(src.loc, 'sound/items/zippoclose.ogg', 25, 1)
else
user.visible_message("<span class='notice'>[user] quietly shuts off the [src].")
@@ -166,7 +166,8 @@
location.hotspot_expose(700, 5)
return
/obj/item/match/fire_act()
/obj/item/match/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
matchignite()
/obj/item/match/proc/matchignite()
@@ -796,6 +796,7 @@
name = "Space Law"
desc = "A set of Nanotrasen guidelines for keeping law and order on their space stations."
icon_state = "bookSpaceLaw"
force = 4 //advanced magistrate tactics
author = "Nanotrasen"
title = "Space Law"
dat = {"
@@ -16,7 +16,7 @@
/obj/item/melee/energy/suicide_act(mob/user)
user.visible_message(pick("<span class='suicide'>[user] is slitting [user.p_their()] stomach open with the [name]! It looks like [user.p_theyre()] trying to commit seppuku.</span>", \
"<span class='suicide'>[user] is falling on the [name]! It looks like [user.p_theyre()] trying to commit suicide.</span>"))
return (BRUTELOSS|FIRELOSS)
return BRUTELOSS|FIRELOSS
/obj/item/melee/energy/attack_self(mob/living/carbon/user)
if(user.disabilities & CLUMSY && prob(50))
@@ -81,7 +81,7 @@
/obj/item/melee/energy/axe/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] swings the [name] towards [user.p_their()] head! It looks like [user.p_theyre()] trying to commit suicide.</span>")
return (BRUTELOSS|FIRELOSS)
return BRUTELOSS|FIRELOSS
/obj/item/melee/energy/sword
name = "energy sword"
@@ -24,8 +24,8 @@
/obj/item/melee/chainofcommand/suicide_act(mob/user)
to_chat(viewers(user), "<span class='suicide'>[user] is strangling [user.p_them()]self with the [src.name]! It looks like [user.p_theyre()] trying to commit suicide.</span>")
return (OXYLOSS)
to_chat(viewers(user), "<span class='suicide'>[user] is strangling [user.p_them()]self with the [src.name]! It looks like [user.p_theyre()] trying to commit suicide.</span>")
return OXYLOSS
/obj/item/melee/rapier
name = "captain's rapier"
+23 -3
View File
@@ -30,6 +30,9 @@
var/whatdpipe = PIPE_DISPOSALS_STRAIGHT //What kind of disposals pipe is it?
var/spawndelay = RPD_COOLDOWN_TIME
var/walldelay = RPD_WALLBUILD_TIME
var/ranged = FALSE
var/primary_sound = 'sound/machines/click.ogg'
var/alt_sound = null
/obj/item/rpd/New()
..()
@@ -41,11 +44,24 @@
QDEL_NULL(spark_system)
return ..()
/obj/item/rpd/bluespace
name = "bluespace rapid pipe dispenser"
desc = "This device can rapidly dispense atmospherics and disposals piping, manipulate loose piping, and recycle any detached pipes it is applied to, at any range."
icon_state = "brpd"
materials = list(MAT_METAL = 75000, MAT_GLASS = 37500, MAT_SILVER = 3000)
origin_tech = "engineering=4;materials=2;bluespace=3"
ranged = TRUE
primary_sound = 'sound/items/PSHOOM.ogg'
alt_sound = 'sound/items/PSHOOM_2.ogg'
//Procs
/obj/item/rpd/proc/activate_rpd(delay) //Maybe makes sparks and activates cooldown if there is a delay
playsound(loc, "sound/machines/click.ogg", 50, 1)
if(prob(15))
if(alt_sound && prob(3))
playsound(src, alt_sound, 50, 1)
else
playsound(src, primary_sound, 50, 1)
if(prob(15) && !ranged)
spark_system.start()
if(delay)
lastused = world.time
@@ -188,7 +204,7 @@ var/list/pipemenu = list(
..()
if(loc != user)
return
if(!proximity)
if(!proximity && !ranged)
return
if(world.time < lastused + spawndelay)
return
@@ -201,6 +217,8 @@ var/list/pipemenu = list(
if(target.rpd_act(user, src) == TRUE)
// If the object we are clicking on has a valid RPD interaction for just that specific object, do that and nothing else.
// Example: clicking on a pipe with a RPD in rotate mode should rotate that pipe and ignore everything else on the tile.
if(ranged)
user.Beam(T, icon_state="rped_upgrade", icon='icons/effects/effects.dmi', time=5)
return
// If we get this far, we have to check every object in the tile, to make sure that none of them block RPD usage on this tile.
@@ -212,6 +230,8 @@ var/list/pipemenu = list(
return
// If we get here, then we're effectively acting on the turf, probably placing a pipe.
if(ranged) //woosh beam if bluespaced at a distance
user.Beam(T,icon_state="rped_upgrade", icon='icons/effects/effects.dmi', time=5)
T.rpd_act(user, src)
#undef RPD_COOLDOWN_TIME
+2 -2
View File
@@ -79,7 +79,7 @@
species_hair = GLOB.hair_styles_public_list
var/h_new_style = input(user, "Select a hair style", "Grooming") as null|anything in species_hair
user.visible_message("<span class='notice'>[user] starts cutting [M]'s hair!</span>", "<span class='notice'>You start cutting [M]'s hair!</span>") //arguments for this are: 1. what others see 2. what the user sees. --Fixed grammar, (TGameCo)
playsound(loc, 'sound/goonstation/misc/Scissor.ogg', 100, 1)
playsound(loc, 'sound/goonstation/misc/scissor.ogg', 100, 1)
if(do_after(user, 50 * toolspeed, target = H)) //this is the part that adds a delay. delay is in deciseconds. --Made it 5 seconds, because hair isn't cut in one second in real life, and I want at least a little bit longer time, (TGameCo)
if(!(M in view(1))) //Adjacency test
user.visible_message("<span class='notice'>[user] stops cutting [M]'s hair.</span>", "<span class='notice'>You stop cutting [M]'s hair.</span>")
@@ -111,7 +111,7 @@
if(!is_cutting)
is_cutting = 1
user.visible_message("<span class='notice'>[user] starts cutting [M]'s hair!</span>", "<span class='notice'>You start cutting [M]'s hair!</span>")
playsound(loc, 'sound/goonstation/misc/Scissor.ogg', 100, 1)
playsound(loc, 'sound/goonstation/misc/scissor.ogg', 100, 1)
if(do_after(user, 50 * toolspeed, target = H))
playsound(loc, 'sound/weapons/bladeslice.ogg', 50, 1, -1)
user.visible_message("<span class='danger'>[user] abruptly stops cutting [M]'s hair and slices [M.p_their()] throat!</span>", "<span class='danger'>You stop cutting [M]'s hair and slice [M.p_their()] throat!</span>") //Just a little off the top.
+1 -1
View File
@@ -18,7 +18,7 @@
/obj/item/shard/suicide_act(mob/user)
to_chat(viewers(user), pick("<span class='danger'>[user] is slitting [user.p_their()] wrists with [src]! It looks like [user.p_theyre()] trying to commit suicide.</span>",
"<span class='danger'>[user] is slitting [user.p_their()] throat with [src]! It looks like [user.p_theyre()] trying to commit suicide.</span>"))
return (BRUTELOSS)
return BRUTELOSS
/obj/item/shard/New()
..()
@@ -40,9 +40,9 @@
max_w_class = WEIGHT_CLASS_NORMAL
max_combined_w_class = 800
works_from_distance = 1
primary_sound = 'sound/items/PSHOOM.ogg'
alt_sound = 'sound/items/PSHOOM_2.ogg'
usesound = 'sound/items/PSHOOM.ogg'
primary_sound = 'sound/items/pshoom.ogg'
alt_sound = 'sound/items/pshoom_2.ogg'
usesound = 'sound/items/pshoom.ogg'
toolspeed = 0.5
/obj/item/storage/part_replacer/proc/play_rped_sound()
@@ -65,7 +65,7 @@
w_class = WEIGHT_CLASS_SMALL
var/rating = 1
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
usesound = 'sound/items/deconstruct.ogg'
/obj/item/stock_parts/New()
src.pixel_x = rand(-5.0, 5)
@@ -13,57 +13,74 @@
force = 5
throwforce = 10
origin_tech = "combat=4;engineering=4;syndicate=2"
actions_types = list(/datum/action/item_action/toggle)
var/list/servantlinks = list()
var/hunger = 0
var/hunger_message_level = 0
var/original_owner = null
var/activated = 0
var/mindless_override = 0
var/mob/living/carbon/human/original_owner = null
var/activated = FALSE
/obj/item/storage/toolbox/green/memetic/ui_action_click(mob/user)
if(user.HasDisease(new /datum/disease/memetic_madness(0)))
var/obj/item/storage/toolbox/green/memetic/M = user.get_active_hand()
if(istype(M))
to_chat(user, "<span class='warning'>His Grace [flags & NODROP ? "releases from" : "binds to"] your hand!</span>")
flags ^= NODROP
else
to_chat(user, "<span class='warning'>You can't seem to understand what this does.</span>")
/obj/item/storage/toolbox/green/memetic/attack_hand(mob/living/carbon/user)
if(!activated)
if(ishuman(user) && !user.HasDisease(new /datum/disease/memetic_madness(0)))
activated = 1
user.ForceContractDisease(new /datum/disease/memetic_madness(0))
for(var/datum/disease/memetic_madness/DD in user.viruses)
DD.progenitor = src
servantlinks.Add(DD)
break
force += 4
throwforce += 4
user << 'sound/goonstation/effects/screech.ogg'
shake_camera(user, 20, 1)
to_chat(user, "<i><b><font face = Tempus Sans ITC>His Grace accepts thee, spread His will! All who look close to the Enlightened may share His gifts.</font></b></i>")
original_owner = user
return
if(loc == user)
if(!activated)
if(ishuman(user) && !user.HasDisease(new /datum/disease/memetic_madness(0)))
activated = TRUE
user.ForceContractDisease(new /datum/disease/memetic_madness(0))
for(var/datum/disease/memetic_madness/DD in user.viruses)
DD.progenitor = src
servantlinks.Add(DD)
break
force += 4
throwforce += 4
SEND_SOUND(user, 'sound/goonstation/effects/screech.ogg')
shake_camera(user, 20, 1)
var/acount = 0
var/amax = rand(10, 15)
var/up_and_down
var/asize = 1
while(acount <= amax)
up_and_down += "<font size=[asize]>a</font>"
if(acount > (amax * 0.5))
asize--
else
asize++
acount++
to_chat(user, "<span class='warning'>[up_and_down]</span>")
to_chat(user, "<i><b><font face = Tempus Sans ITC>His Grace accepts thee, spread His will! All who look close to the Enlightened may share His gifts.</font></b></i>")
original_owner = user
return
..()
/obj/item/storage/toolbox/green/memetic/attackby(obj/item/I, mob/user)
if(activated)
if(istype(I, /obj/item/grab/))
if(istype(I, /obj/item/grab))
var/obj/item/grab/G = I
if(!G.affecting)
return
var/mob/living/victim = G.affecting
if(!user.HasDisease(new /datum/disease/memetic_madness(0)))
to_chat(user, "<span class='warning'>You can't seem to find the latch to open this.</span>")
return
if(!ishuman(G.affecting) || issmall(G.affecting))
to_chat(user, "<span class='warning'>His Grace will not accept such a meager offering!</span>")
if(!victim)
return
if(!mindless_override)
if(G.affecting.mind == null && G.affecting.ckey == null)
to_chat(user, "<span class='warning'>His Grace will not accept a soulless shell for an offering!</span>")
return
if(!G.affecting.stat && !G.affecting.restrained() && !G.affecting.weakened)
if(!victim.stat && !victim.restrained() && !victim.weakened)
to_chat(user, "<span class='warning'>They're moving too much to feed to His Grace!</span>")
return
user.visible_message("<span class='userdanger'>[user] is trying to feed [G.affecting] to [src]!</span>")
if(!do_mob(user, G.affecting, 30))
user.visible_message("<span class='userdanger'>[user] is trying to feed [victim] to [src]!</span>")
if(!do_mob(user, victim, 30))
return
G.affecting.forceMove(src)
user.visible_message("<span class='userdanger'>[user] has fed [G.affecting] to [src]!</span>")
consume(G.affecting)
user.visible_message("<span class='userdanger'>[user] has fed [victim] to [src]!</span>")
consume(victim)
qdel(G)
to_chat(user, "<i><b><font face = Tempus Sans ITC>You have done well...</font></b></i>")
@@ -71,40 +88,52 @@
throwforce += 5
return
..()
return ..()
/obj/item/storage/toolbox/green/memetic/proc/consume(mob/M)
if(!M)
/obj/item/storage/toolbox/green/memetic/proc/consume(mob/living/L)
if(!L)
return
hunger = 0
hunger_message_level = 0
playsound(src.loc, 'sound/goonstation/misc/burp_alien.ogg', 50, 0)
M.emote("scream")
M.death()
M.ghostize()
if(M == original_owner)
qdel(M)
playsound(loc, 'sound/goonstation/misc/burp_alien.ogg', 50, 0)
if(L != original_owner)
var/list/equipped_items = L.get_equipped_items(TRUE)
if(L.l_hand)
equipped_items += L.l_hand
if(L.r_hand)
equipped_items += L.r_hand
if(equipped_items.len)
var/obj/item/storage/box/B = new(src)
B.name = "Box-'[L.real_name]'"
for(var/obj/item/SI in equipped_items)
L.unEquip(SI, TRUE)
SI.forceMove(B)
equipped_items.Cut()
L.forceMove(src)
L.emote("scream")
L.death()
L.ghostize()
if(L == original_owner)
L.unEquip(src, TRUE)
qdel(L)
var/obj/item/storage/toolbox/green/fake_toolbox = new(get_turf(src))
fake_toolbox.desc = "It looks a lot duller than it used to."
qdel(src)
else
qdel(L)
/obj/item/storage/toolbox/green/memetic/Destroy()
for(var/mob/living/carbon/human/H in src)
H.forceMove(get_turf(src))
visible_message("<span class='warning'>[H] bursts out of [src]!</span>")
for(var/datum/disease/memetic_madness/D in servantlinks)
D.cure()
for(var/A in servantlinks)
var/datum/disease/memetic_madness/D = A
if(D)
D.cure()
break
if(servantlinks)
servantlinks.Cut()
servantlinks.Cut()
servantlinks = null
original_owner = null
visible_message("<span class='userdanger'>[src] screams!</span>")
playsound(src.loc, 'sound/goonstation/effects/screech.ogg', 100, 1)
playsound(loc, 'sound/goonstation/effects/screech.ogg', 100, 1)
return ..()
/datum/disease/memetic_madness
@@ -116,11 +145,14 @@
cure_text = "Unknown"
viable_mobtypes = list(/mob/living/carbon/human)
severity = BIOHAZARD
disease_flags = CURABLE
disease_flags = CAN_CARRY
spread_flags = NON_CONTAGIOUS
virus_heal_resistant = TRUE
var/obj/item/storage/toolbox/green/memetic/progenitor = null
/datum/disease/memetic_madness/Destroy()
if(progenitor)
progenitor.servantlinks.Remove(src)
progenitor = null
if(affected_mob)
affected_mob.status_flags |= CANSTUN | CANWEAKEN | CANPARALYSE
@@ -142,6 +174,8 @@
affected_mob.AdjustDizzy(-10)
affected_mob.AdjustDrowsy(-10)
affected_mob.SetSleeping(0)
affected_mob.SetSlowed(0)
affected_mob.SetConfused(0)
stage = 1
switch(progenitor.hunger)
if(10 to 60)
@@ -182,4 +216,4 @@
affected_mob.adjustBruteLoss(5)
if(ismob(progenitor.loc))
progenitor.hunger++
progenitor.hunger++
@@ -26,6 +26,23 @@
playsound(src.loc, "rustle", 50, 1, -5)
return ..()
/obj/item/storage/backpack/examine(mob/user)
var/space_used = 0
if(!..(user, 1))
return
for(var/obj/item/I in contents)
space_used += I.w_class
if(!space_used)
to_chat(user, "<span class='notice'> [src] is empty.</span>")
else if(space_used <= max_combined_w_class*0.6)
to_chat(user, "<span class='notice'> [src] still has plenty of remaining space.</span>")
else if(space_used <= max_combined_w_class*0.8)
to_chat(user, "<span class='notice'> [src] is beginning to run out of space.</span>")
else if(space_used < max_combined_w_class)
to_chat(user, "<span class='notice'> [src] doesn't have much space left.</span>")
else
to_chat(user, "<span class='notice'> [src] is full.</span>")
/*
* Backpack Types
*/
@@ -47,7 +64,7 @@
/obj/item/storage/backpack/holding/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/storage/backpack/holding))
var/response = alert(user, "Are you sure you want to put the bag of holding inside another bag of holding?","Are you sure you want to die?","Yes","No")
var/response = alert(user, "This creates a singularity, destroying you and much of the station. Are you SURE?","IMMINENT DEATH!", "No", "Yes")
if(response == "Yes")
user.visible_message("<span class='warning'>[user] grins as [user.p_they()] begin[user.p_s()] to put a Bag of Holding into a Bag of Holding!</span>", "<span class='warning'>You begin to put the Bag of Holding into the Bag of Holding!</span>")
if(do_after(user, 30, target=src))
@@ -98,6 +115,7 @@
new /obj/item/clothing/mask/gas/voice/clown(src)
new /obj/item/radio/headset/headset_service(src)
new /obj/item/pda/clown(src)
new /obj/item/storage/box/survival(src)
new /obj/item/reagent_containers/food/snacks/grown/banana(src)
new /obj/item/stamp/clown(src)
new /obj/item/toy/crayon/rainbow(src)
@@ -179,6 +197,22 @@
desc = "It's a very fancy satchel made with fine leather."
icon_state = "satchel"
burn_state = FIRE_PROOF
var/strap_side_straight = FALSE
/obj/item/storage/backpack/satchel/verb/switch_strap()
set name = "Switch Strap Side"
set category = "Object"
set src in usr
if(usr.incapacitated())
return
strap_side_straight = !strap_side_straight
icon_state = strap_side_straight ? "satchel-flipped" : "satchel"
if(ishuman(loc))
var/mob/living/carbon/human/H = loc
H.update_inv_back()
/obj/item/storage/backpack/satcheldeluxe
name = "leather satchel"
@@ -333,7 +367,6 @@
new /obj/item/FixOVein(src)
new /obj/item/clothing/suit/straight_jacket(src)
new /obj/item/clothing/mask/muzzle(src)
new /obj/item/mmi/syndie(src)
/obj/item/storage/backpack/duffel/syndie/surgery_fake //for maint spawns
name = "surgery duffelbag"
@@ -42,7 +42,7 @@
/obj/item/storage/bag/trash/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] puts the [name] over [user.p_their()] head and starts chomping at the insides! Disgusting!</span>")
playsound(loc, 'sound/items/eatfood.ogg', 50, 1, -1)
return (TOXLOSS)
return TOXLOSS
/obj/item/storage/bag/trash/update_icon()
if(contents.len == 0)
@@ -460,6 +460,19 @@
return ..()
/obj/item/storage/bag/tray/cookies_tray
var/cookie = /obj/item/reagent_containers/food/snacks/cookie
/obj/item/storage/bag/tray/cookies_tray/New() /// By Azule Utama, thank you a lot!
..()
for(var/i in 1 to 6)
var/obj/item/C = new cookie(src)
handle_item_insertion(C) // Done this way so the tray actually has the cookies visible when spawned
rebuild_overlays()
/obj/item/storage/bag/tray/cookies_tray/sugarcookie
cookie = /obj/item/reagent_containers/food/snacks/sugarcookie
/*
* Chemistry bag
*/
@@ -486,5 +499,5 @@
storage_slots = 25
max_combined_w_class = 200
w_class = WEIGHT_CLASS_TINY
can_hold = list(/obj/item/slime_extract,/obj/item/reagent_containers/food/snacks/monkeycube,/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/autoinjector)
can_hold = list(/obj/item/slime_extract,/obj/item/reagent_containers/food/snacks/monkeycube,/obj/item/reagent_containers/syringe,/obj/item/reagent_containers/glass/beaker,/obj/item/reagent_containers/glass/bottle,/obj/item/reagent_containers/iv_bag,/obj/item/reagent_containers/hypospray/autoinjector)
burn_state = FLAMMABLE
@@ -88,7 +88,7 @@
update_icon()
/obj/item/storage/belt/utility/chief
name = "Chief Engineer's toolbelt"
name = "advanced toolbelt"
desc = "Holds tools, looks snazzy"
icon_state = "utilitybelt_ce"
item_state = "utility_ce"
@@ -112,6 +112,7 @@
icon_state = "medicalbelt"
item_state = "medical"
use_item_overlays = 1
max_w_class = WEIGHT_CLASS_NORMAL
can_hold = list(
/obj/item/healthanalyzer,
/obj/item/dnainjector,
@@ -133,13 +134,14 @@
/obj/item/rad_laser,
/obj/item/sensor_device,
/obj/item/wrench/medical,
/obj/item/handheld_defibrillator
)
/obj/item/storage/belt/medical/surgery
max_w_class = WEIGHT_CLASS_NORMAL
max_combined_w_class = 17
use_to_pickup = 1
name = "Surgical Belt"
name = "surgical belt"
desc = "Can hold various surgical tools."
storage_slots = 9
use_item_overlays = 1
@@ -295,6 +297,10 @@
item_state = "military"
max_w_class = WEIGHT_CLASS_SMALL
/obj/item/storage/belt/military/sst
icon_state = "assaultbelt"
item_state = "assault"
/obj/item/storage/belt/military/traitor
name = "tool-belt"
desc = "Can hold various tools. This model seems to have additional compartments."
@@ -302,6 +308,48 @@
item_state = "utility"
use_item_overlays = 1 // So it will still show tools in it in case sec get lazy and just glance at it.
/obj/item/storage/belt/grenade
name = "grenadier belt"
desc = "A belt for holding grenades."
icon_state = "assaultbelt"
item_state = "assault"
storage_slots = 30
max_combined_w_class = 60
display_contents_with_number = 1
can_hold = list(
/obj/item/grenade,
/obj/item/lighter,
/obj/item/reagent_containers/food/drinks/bottle/molotov
)
/obj/item/storage/belt/grenade/full/New()
..()
new /obj/item/grenade/smokebomb(src) //4
new /obj/item/grenade/smokebomb(src)
new /obj/item/grenade/smokebomb(src)
new /obj/item/grenade/smokebomb(src)
new /obj/item/grenade/empgrenade(src) //2
new /obj/item/grenade/empgrenade(src)
new /obj/item/grenade/gluon(src) //4
new /obj/item/grenade/gluon(src)
new /obj/item/grenade/gluon(src)
new /obj/item/grenade/gluon(src)
new /obj/item/grenade/chem_grenade/facid(src) //1
new /obj/item/grenade/gas/plasma(src) //2
new /obj/item/grenade/gas/plasma(src)
new /obj/item/grenade/frag(src) //10
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/frag(src)
new /obj/item/grenade/syndieminibomb(src) //2
new /obj/item/grenade/syndieminibomb(src)
/obj/item/storage/belt/military/abductor
name = "agent belt"
desc = "A belt used by abductor agents."
@@ -9,9 +9,10 @@
var/mob/affecting = null
var/deity_name = "Christ"
suicide_act(mob/user)
to_chat(viewers(user), "<span class='warning'><b>[user] stares into [src.name] and attempts to trascend understanding of the universe!</b></span>")
return (user.dust())
/obj/item/storage/bible/suicide_act(mob/user)
to_chat(viewers(user), "<span class='warning'><b>[user] stares into [src.name] and attempts to transcend understanding of the universe!</b></span>")
user.dust()
return OBLITERATION
/obj/item/storage/bible/booze
@@ -38,10 +39,6 @@
return
/obj/item/storage/bible/attack(mob/living/M as mob, mob/living/user as mob)
var/chaplain = 0
if(user.mind && (user.mind.assigned_role == "Chaplain"))
chaplain = 1
add_attack_logs(user, M, "Hit with [src]")
if(!iscarbon(user))
M.LAssailant = null
@@ -51,7 +48,7 @@
if(!(istype(user, /mob/living/carbon/human) || ticker) && ticker.mode.name != "monkey")
to_chat(user, "<span class='warning'>You don't have the dexterity to do this!</span>")
return
if(!chaplain)
if(!user.mind || !user.mind.isholy)
to_chat(user, "<span class='warning'>The book sizzles in your hands.</span>")
user.take_organ_damage(0,10)
return
@@ -62,14 +59,7 @@
user.Paralyse(20)
return
// if(..() == BLOCKED)
// return
if(M.stat !=2)
/*if((M.mind in ticker.mode.cult) && (prob(20)))
to_chat(M, "<span class='warning'>The power of [src.deity_name] clears your mind of heresy!</span>")
to_chat(user, "<span class='warning'>You see how [M]'s eyes become clear, the cult no longer holds control over [M.p_them()]!</span>")
ticker.mode.remove_cultist(M.mind)*/
if((istype(M, /mob/living/carbon/human) && prob(60)))
bless(M)
for(var/mob/O in viewers(M, null))
@@ -94,11 +84,11 @@
return
if(istype(A, /turf/simulated/floor))
to_chat(user, "<span class='notice'>You hit the floor with the bible.</span>")
if(user.mind && (user.mind.assigned_role == "Chaplain"))
if(user.mind && (user.mind.isholy))
for(var/obj/effect/rune/R in A)
if(R.invisibility)
R.talismanreveal()
if(user.mind && (user.mind.assigned_role == "Chaplain"))
if(user.mind && (user.mind.isholy))
if(A.reagents && A.reagents.has_reagent("water")) //blesses all the water in the holder
to_chat(user, "<span class='notice'>You bless [A].</span>")
var/water2holy = A.reagents.get_reagent_amount("water")
@@ -72,8 +72,31 @@
new /obj/item/clothing/mask/breath( src )
new /obj/item/tank/emergency_oxygen( src )
new /obj/item/reagent_containers/hypospray/autoinjector( src )
new /obj/item/flashlight/flare/glowstick/emergency( src )
return
/obj/item/storage/box/survival_vox
icon_state = "box_vox"
/obj/item/storage/box/survival_vox/New()
..()
contents = list()
new /obj/item/clothing/mask/breath/vox(src)
new /obj/item/tank/emergency_oxygen/nitrogen(src)
new /obj/item/reagent_containers/hypospray/autoinjector(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/survival_plasmaman
icon_state = "box_plasma"
/obj/item/storage/box/survival_plasmaman/New()
..()
contents = list()
new /obj/item/clothing/mask/breath(src)
new /obj/item/tank/emergency_oxygen/plasma(src)
new /obj/item/reagent_containers/hypospray/autoinjector(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/engineer
icon_state = "box_eng"
New()
@@ -82,6 +105,7 @@
new /obj/item/clothing/mask/breath( src )
new /obj/item/tank/emergency_oxygen/engi( src )
new /obj/item/reagent_containers/hypospray/autoinjector( src )
new /obj/item/flashlight/flare/glowstick/emergency( src )
return
/obj/item/storage/box/survival_mining
@@ -93,6 +117,18 @@
new /obj/item/tank/emergency_oxygen/engi(src)
new /obj/item/crowbar/red(src)
new /obj/item/reagent_containers/hypospray/autoinjector(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/survival_syndi
icon_state = "box_syndi"
New()
..()
contents = list()
new /obj/item/clothing/mask/gas/syndicate(src)
new /obj/item/tank/emergency_oxygen/syndi(src)
new /obj/item/reagent_containers/hypospray/autoinjector(src)
new /obj/item/reagent_containers/food/pill/initropidril(src)
new /obj/item/flashlight/flare/glowstick/red(src)
/obj/item/storage/box/gloves
name = "box of latex gloves"
@@ -155,6 +191,21 @@
new /obj/item/reagent_containers/glass/beaker( src )
new /obj/item/reagent_containers/glass/beaker( src )
/obj/item/storage/box/iv_bags
name = "IV Bags"
desc = "A box full of empty IV bags."
icon_state = "beaker"
/obj/item/storage/box/iv_bags/New()
..()
new /obj/item/reagent_containers/iv_bag( src )
new /obj/item/reagent_containers/iv_bag( src )
new /obj/item/reagent_containers/iv_bag( src )
new /obj/item/reagent_containers/iv_bag( src )
new /obj/item/reagent_containers/iv_bag( src )
new /obj/item/reagent_containers/iv_bag( src )
new /obj/item/reagent_containers/iv_bag( src )
/obj/item/storage/box/injectors
name = "\improper DNA injectors"
desc = "This box contains injectors it seems."
@@ -644,6 +695,56 @@
new /obj/item/clothing/head/syndicatefake(src)
new /obj/item/clothing/suit/syndicatefake(src)
/obj/item/storage/box/enforcer_rubber
name = "enforcer pistol kit (rubber)"
desc = "A box marked with pictures of an enforcer pistol, two ammo clips, and the word 'NON-LETHAL'."
icon_state = "box_ert"
/obj/item/storage/box/enforcer_rubber/New()
..()
new /obj/item/gun/projectile/automatic/pistol/enforcer(src) // loaded with rubber by default
new /obj/item/ammo_box/magazine/enforcer(src)
new /obj/item/ammo_box/magazine/enforcer(src)
/obj/item/storage/box/enforcer_lethal
name = "enforcer pistol kit (lethal)"
desc = "A box marked with pictures of an enforcer pistol, two ammo clips, and the word 'LETHAL'."
icon_state = "box_ert"
/obj/item/storage/box/enforcer_lethal/New()
..()
new /obj/item/gun/projectile/automatic/pistol/enforcer/lethal(src)
new /obj/item/ammo_box/magazine/enforcer/lethal(src)
new /obj/item/ammo_box/magazine/enforcer/lethal(src)
/obj/item/storage/box/bartender_rare_ingredients_kit
name = "bartender rare reagents kit"
desc = "A box intended for experienced bartenders."
/obj/item/storage/box/bartender_rare_ingredients_kit/New()
..()
var/list/reagent_list = list("sacid", "radium", "ether", "methamphetamine", "plasma", "gold", "silver", "capsaicin", "psilocybin")
for(var/reag in reagent_list)
var/obj/item/reagent_containers/glass/bottle/B = new(src)
B.reagents.add_reagent(reag, 30)
B.name = "[reag] bottle"
/obj/item/storage/box/chef_rare_ingredients_kit
name = "chef rare reagents kit"
desc = "A box intended for experienced chefs."
/obj/item/storage/box/chef_rare_ingredients_kit/New()
..()
new /obj/item/reagent_containers/food/condiment/soysauce(src)
new /obj/item/reagent_containers/food/condiment/enzyme(src)
new /obj/item/reagent_containers/food/condiment/pack/hotsauce(src)
new /obj/item/kitchen/knife/butcher(src)
var/list/reagent_list = list("msg", "triple_citrus", "salglu_solution", "nutriment", "gravy", "honey", "vitfro")
for(var/reag in reagent_list)
var/obj/item/reagent_containers/glass/bottle/B = new(src)
B.reagents.add_reagent(reag, 30)
B.name = "[reag] bottle"
/obj/item/storage/box/mousetraps
name = "box of Pest-B-Gon mousetraps"
desc = "<B><FONT color='red'>WARNING:</FONT></B> <I>Keep out of reach of children</I>."
@@ -672,6 +773,20 @@
new /obj/item/storage/pill_bottle( src )
new /obj/item/storage/pill_bottle( src )
/obj/item/storage/box/patch_packs
name = "box of patch packs"
desc = "It has pictures of patch packs on its front."
/obj/item/storage/box/patch_packs/New()
..()
new /obj/item/storage/pill_bottle/patch_pack(src)
new /obj/item/storage/pill_bottle/patch_pack(src)
new /obj/item/storage/pill_bottle/patch_pack(src)
new /obj/item/storage/pill_bottle/patch_pack(src)
new /obj/item/storage/pill_bottle/patch_pack(src)
new /obj/item/storage/pill_bottle/patch_pack(src)
new /obj/item/storage/pill_bottle/patch_pack(src)
/obj/item/storage/box/bodybags
name = "body bags"
desc = "This box contains body bags."
@@ -912,6 +1027,23 @@
new /obj/item/reagent_containers/food/pill/patch/synthflesh(src)
new /obj/item/reagent_containers/hypospray/autoinjector(src)
/obj/item/storage/box/clown
name = "clown box"
desc = "A colorful cardboard box for the clown"
icon_state = "box_clown"
/obj/item/storage/box/rndboards
name = "the Liberator's legacy"
desc = "A box containing a gift for worthy golems."
/obj/item/storage/box/rndboards/New()
..()
contents = list()
new /obj/item/circuitboard/protolathe(src)
new /obj/item/circuitboard/destructive_analyzer(src)
new /obj/item/circuitboard/circuit_imprinter(src)
new /obj/item/circuitboard/rdconsole/public(src)
#undef NODESIGN
#undef NANOTRASEN
#undef SYNDI
@@ -234,6 +234,7 @@
/*
* Pill Bottles
*/
/obj/item/storage/pill_bottle
name = "pill bottle"
desc = "It's an airtight container for storing medication."
@@ -241,18 +242,38 @@
icon = 'icons/obj/chemical.dmi'
item_state = "contsolid"
w_class = WEIGHT_CLASS_SMALL
can_hold = list(/obj/item/reagent_containers/food/pill, /obj/item/dice, /obj/item/paper)
allow_quick_gather = 1
use_to_pickup = 1
storage_slots = 14
display_contents_with_number = 1
can_hold = list(/obj/item/reagent_containers/food/pill)
cant_hold = list(/obj/item/reagent_containers/food/pill/patch)
allow_quick_gather = TRUE
use_to_pickup = TRUE
storage_slots = 50
max_combined_w_class = 50
display_contents_with_number = TRUE
var/base_name = ""
var/label_text = ""
var/applying_meds = FALSE //To Prevent spam clicking and generating runtimes from apply a deleting pill multiple times.
var/rapid_intake_message = "unscrews the cap on the pill bottle and begins dumping the entire contents down their throat!"
var/rapid_post_instake_message = "downs the entire bottle of pills in one go!"
/obj/item/storage/pill_bottle/New()
..()
base_name = name
/obj/item/storage/pill_bottle/attack(mob/M, mob/user)
if(iscarbon(M) && contents.len)
if(applying_meds)
to_chat(user, "<span class='warning'>You are already applying meds.</span>")
return
applying_meds = TRUE
for(var/obj/item/reagent_containers/food/pill/P in contents)
if(P.attack(M, user))
applying_meds = FALSE
else
applying_meds = FALSE
break
else
return ..()
/obj/item/storage/pill_bottle/ert/New()
..()
new /obj/item/reagent_containers/food/pill/salicylic(src)
@@ -262,29 +283,23 @@
new /obj/item/reagent_containers/food/pill/charcoal(src)
new /obj/item/reagent_containers/food/pill/charcoal(src)
/obj/item/storage/pill_bottle/MouseDrop(obj/over_object as obj) //Quick pillbottle fix. -Agouri
if(ishuman(usr)) //Can monkeys even place items in the pocket slots? Leaving this in just in case~
var/mob/M = usr
if(!( istype(over_object, /obj/screen) ))
return ..()
if((!( M.restrained() ) && !( M.stat ) /*&& M.pocket == src*/))
switch(over_object.name)
if("r_hand")
M.unEquip(src)
M.put_in_r_hand(src)
if("l_hand")
M.unEquip(src)
M.put_in_l_hand(src)
src.add_fingerprint(usr)
/obj/item/storage/pill_bottle/MouseDrop(obj/over_object as obj) // Best utilized if you're a cantankerous doctor with a Vicodin habit.
if(iscarbon(over_object))
var/mob/living/carbon/C = over_object
if(loc == C && src == C.get_active_hand())
if(!contents.len)
to_chat(C, "<span class='notice'>There is nothing in [src]!</span>")
return
C.visible_message("<span class='danger'>[C] [rapid_intake_message]</span>")
if(do_mob(C, C, 100)) // 10 seconds
for(var/obj/item/reagent_containers/food/pill/P in contents)
P.attack(C, C)
C.visible_message("<span class='danger'>[C] [rapid_post_instake_message]</span>")
return
if(over_object == usr && in_range(src, usr) || usr.contents.Find(src))
if(usr.s_active)
usr.s_active.close(usr)
src.show_to(usr)
return
return
/obj/item/storage/pill_bottle/attackby(var/obj/item/I, mob/user as mob, params)
return ..()
/obj/item/storage/pill_bottle/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/pen) || istype(I, /obj/item/flashlight/pen))
var/tmp_label = sanitize(input(user, "Enter a label for [name]","Label",label_text))
if(length(tmp_label) > MAX_NAME_LEN)
@@ -294,7 +309,7 @@
label_text = tmp_label
update_name_label()
else
..()
return ..()
/obj/item/storage/pill_bottle/proc/update_name_label()
if(label_text == "")
@@ -302,6 +317,14 @@
else
name = "[base_name] ([label_text])"
/obj/item/storage/pill_bottle/patch_pack
name = "Patch Pack"
icon_state = "patch_pack"
can_hold = list(/obj/item/reagent_containers/food/pill/patch)
cant_hold = list()
rapid_intake_message = "flips the lid of the Patch Pack open and begins rapidly stamping patches on themselves!"
rapid_post_instake_message = "stamps the entire contents of the Patch Pack all over their entire body!"
/obj/item/storage/pill_bottle/charcoal
name = "Pill bottle (Charcoal)"
desc = "Contains pills used to counter toxins."
@@ -330,3 +353,9 @@
new /obj/item/reagent_containers/food/pill/salicylic(src)
new /obj/item/reagent_containers/food/pill/salicylic(src)
new /obj/item/reagent_containers/food/pill/salicylic(src)
/obj/item/storage/pill_bottle/fakedeath/New()
..()
new /obj/item/reagent_containers/food/pill/fakedeath(src)
new /obj/item/reagent_containers/food/pill/fakedeath(src)
new /obj/item/reagent_containers/food/pill/fakedeath(src)
@@ -24,6 +24,8 @@
if(locked)
icon_state = icon_locked
to_chat(user, "<span class='warning'>You lock \the [src]!</span>")
if(user.s_active)
user.s_active.close(user)
return
else
icon_state = icon_closed
@@ -67,7 +69,7 @@
origin_tech = null //wipe out any origin tech if it's unlocked in any way so you can't double-dip tech levels at R&D.
return
/obj/item/storage/lockbox/hear_talk(mob/living/M as mob, msg)
/obj/item/storage/lockbox/hear_talk(mob/living/M as mob, list/message_pieces)
/obj/item/storage/lockbox/hear_message(mob/living/M as mob, msg)
@@ -131,5 +133,5 @@
/obj/item/storage/lockbox/t4/New()
..()
for(var/i = 0, i < 3, i++)
for(var/i in 0 to 2)
new /obj/item/grenade/plastic/x4/thermite(src)

Some files were not shown because too many files have changed in this diff Show More