mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-29 07:59:01 +01:00
Merge branch 'Aurorastation/development' into Map-Development
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
|
||||
//switching opacity on after the smoke has spawned, and then turning it off before it is deleted results in cleaner
|
||||
//lighting and view range updates (Is this still true with the new lighting system?)
|
||||
opacity = 1
|
||||
set_opacity(1)
|
||||
|
||||
//float over to our destination, if we have one
|
||||
destination = dest_turf
|
||||
@@ -34,7 +34,7 @@
|
||||
walk_to(src, destination)
|
||||
|
||||
/obj/effect/effect/smoke/chem/Destroy()
|
||||
opacity = 0
|
||||
set_opacity(0)
|
||||
fadeOut()
|
||||
..()
|
||||
|
||||
@@ -250,7 +250,7 @@
|
||||
if(passed_smoke)
|
||||
smoke = passed_smoke
|
||||
else
|
||||
smoke = PoolOrNew(/obj/effect/effect/smoke/chem, list(location, smoke_duration + rand(smoke_duration*-0.25, smoke_duration*0.25), T, I))
|
||||
smoke = getFromPool(/obj/effect/effect/smoke/chem, list(location, smoke_duration + rand(smoke_duration*-0.25, smoke_duration*0.25), T, I))
|
||||
|
||||
if(chemholder.reagents.reagent_list.len)
|
||||
chemholder.reagents.trans_to_obj(smoke, chemholder.reagents.total_volume / dist, copy = 1) //copy reagents to the smoke so mob/breathe() can handle inhaling the reagents
|
||||
@@ -261,7 +261,7 @@
|
||||
|
||||
|
||||
/datum/effect/effect/system/smoke_spread/chem/spores/spawnSmoke(var/turf/T, var/smoke_duration, var/icon/I, var/dist = 1)
|
||||
var/obj/effect/effect/smoke/chem/spores = PoolOrNew(/obj/effect/effect/smoke/chem, location)
|
||||
var/obj/effect/effect/smoke/chem/spores = getFromPool(/obj/effect/effect/smoke/chem, location)
|
||||
spores.name = "cloud of [seed.seed_name] [seed.seed_noun]"
|
||||
..(T, I, smoke_duration, dist, spores)
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@
|
||||
F.amount += amount
|
||||
return
|
||||
|
||||
F = PoolOrNew(/obj/effect/effect/foam, list(location, metal))
|
||||
F = getFromPool(/obj/effect/effect/foam, list(location, metal))
|
||||
F.amount = amount
|
||||
|
||||
if(!metal) // don't carry other chemicals if a metal foam
|
||||
|
||||
@@ -221,7 +221,7 @@ var/global/list/image/splatter_cache=list()
|
||||
for (var/i = 0, i < pick(1, 200; 2, 150; 3, 50; 4), i++)
|
||||
sleep(3)
|
||||
if (i > 0)
|
||||
var/obj/effect/decal/cleanable/blood/b = PoolOrNew(/obj/effect/decal/cleanable/blood/splatter, src.loc)
|
||||
var/obj/effect/decal/cleanable/blood/b = getFromPool(/obj/effect/decal/cleanable/blood/splatter, src.loc)
|
||||
b.basecolor = src.basecolor
|
||||
b.update_icon()
|
||||
for(var/datum/disease/D in src.viruses)
|
||||
|
||||
@@ -75,7 +75,7 @@ steam.start() -- spawns the effect
|
||||
spawn(0)
|
||||
if(holder)
|
||||
src.location = get_turf(holder)
|
||||
var/obj/effect/effect/steam/steam = PoolOrNew(/obj/effect/effect/steam, src.location)
|
||||
var/obj/effect/effect/steam/steam = getFromPool(/obj/effect/effect/steam, src.location)
|
||||
var/direction
|
||||
if(src.cardinals)
|
||||
direction = pick(cardinal)
|
||||
@@ -146,7 +146,7 @@ steam.start() -- spawns the effect
|
||||
spawn(0)
|
||||
if(holder)
|
||||
src.location = get_turf(holder)
|
||||
var/obj/effect/sparks/sparks = PoolOrNew(/obj/effect/sparks, src.location)
|
||||
var/obj/effect/sparks/sparks = getFromPool(/obj/effect/sparks, src.location)
|
||||
src.total_sparks++
|
||||
var/direction
|
||||
if(src.cardinals)
|
||||
@@ -331,7 +331,7 @@ steam.start() -- spawns the effect
|
||||
spawn(0)
|
||||
if(holder)
|
||||
src.location = get_turf(holder)
|
||||
var/obj/effect/effect/smoke/smoke = PoolOrNew(smoke_type, src.location)
|
||||
var/obj/effect/effect/smoke/smoke = getFromPool(smoke_type, src.location)
|
||||
src.total_smoke++
|
||||
var/direction = src.direction
|
||||
if(!direction)
|
||||
@@ -389,7 +389,7 @@ steam.start() -- spawns the effect
|
||||
var/turf/T = get_turf(src.holder)
|
||||
if(T != src.oldposition)
|
||||
if(istype(T, /turf/space))
|
||||
var/obj/effect/effect/ion_trails/I = PoolOrNew(/obj/effect/effect/ion_trails, src.oldposition)
|
||||
var/obj/effect/effect/ion_trails/I = getFromPool(/obj/effect/effect/ion_trails, src.oldposition)
|
||||
src.oldposition = T
|
||||
I.set_dir(src.holder.dir)
|
||||
flick("ion_fade", I)
|
||||
@@ -435,7 +435,7 @@ steam.start() -- spawns the effect
|
||||
src.processing = 0
|
||||
spawn(0)
|
||||
if(src.number < 3)
|
||||
var/obj/effect/effect/steam/I = PoolOrNew(/obj/effect/effect/steam, src.oldposition)
|
||||
var/obj/effect/effect/steam/I = getFromPool(/obj/effect/effect/steam, src.oldposition)
|
||||
src.number++
|
||||
src.oldposition = get_turf(holder)
|
||||
I.set_dir(src.holder.dir)
|
||||
@@ -475,7 +475,7 @@ steam.start() -- spawns the effect
|
||||
|
||||
start()
|
||||
if (amount <= 2)
|
||||
var/datum/effect/effect/system/spark_spread/s = PoolOrNew(/datum/effect/effect/system/spark_spread)
|
||||
var/datum/effect/effect/system/spark_spread/s = getFromPool(/datum/effect/effect/system/spark_spread)
|
||||
s.set_up(2, 1, location)
|
||||
s.start()
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
qdel(D)
|
||||
|
||||
if(sparks)
|
||||
var/datum/effect/effect/system/spark_spread/s = PoolOrNew(/datum/effect/effect/system/spark_spread)
|
||||
var/datum/effect/effect/system/spark_spread/s = getFromPool(/datum/effect/effect/system/spark_spread)
|
||||
s.set_up(2, 1, get_turf(location)) // Not sure if it's safe to pass an arbitrary object to set_up, todo
|
||||
s.start()
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
call(src,triggerproc)(M)
|
||||
|
||||
/obj/effect/mine/proc/triggerrad(obj)
|
||||
var/datum/effect/effect/system/spark_spread/s = PoolOrNew(/datum/effect/effect/system/spark_spread)
|
||||
var/datum/effect/effect/system/spark_spread/s = getFromPool(/datum/effect/effect/system/spark_spread)
|
||||
s.set_up(3, 1, src)
|
||||
s.start()
|
||||
obj:radiation += 50
|
||||
@@ -39,7 +39,7 @@
|
||||
if(ismob(obj))
|
||||
var/mob/M = obj
|
||||
M.Stun(30)
|
||||
var/datum/effect/effect/system/spark_spread/s = PoolOrNew(/datum/effect/effect/system/spark_spread)
|
||||
var/datum/effect/effect/system/spark_spread/s = getFromPool(/datum/effect/effect/system/spark_spread)
|
||||
s.set_up(3, 1, src)
|
||||
s.start()
|
||||
spawn(0)
|
||||
@@ -67,7 +67,7 @@
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/mine/proc/triggerkick(obj)
|
||||
var/datum/effect/effect/system/spark_spread/s = PoolOrNew(/datum/effect/effect/system/spark_spread)
|
||||
var/datum/effect/effect/system/spark_spread/s = getFromPool(/datum/effect/effect/system/spark_spread)
|
||||
s.set_up(3, 1, src)
|
||||
s.start()
|
||||
qdel(obj:client)
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
O = loc
|
||||
|
||||
for(var/i=0, i<num, i++)
|
||||
var/spiderling = PoolOrNew(/obj/effect/spider/spiderling, list(src.loc, src))
|
||||
var/spiderling = getFromPool(/obj/effect/spider/spiderling, list(src.loc, src))
|
||||
if(O)
|
||||
O.implants += spiderling
|
||||
qdel(src)
|
||||
@@ -141,7 +141,7 @@
|
||||
|
||||
/obj/effect/spider/spiderling/proc/die()
|
||||
visible_message("<span class='alert'>[src] dies!</span>")
|
||||
PoolOrNew(/obj/effect/decal/cleanable/spiderling_remains, src.loc)
|
||||
getFromPool(/obj/effect/decal/cleanable/spiderling_remains, src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/spider/spiderling/healthcheck()
|
||||
|
||||
@@ -15,7 +15,7 @@ proc/empulse(turf/epicenter, heavy_range, light_range, log=0)
|
||||
log_game("EMP with size ([heavy_range], [light_range]) in area [epicenter.loc.name] ")
|
||||
|
||||
if(heavy_range > 1)
|
||||
var/obj/effect/overlay/pulse = PoolOrNew(/obj/effect/overlay, epicenter)
|
||||
var/obj/effect/overlay/pulse = getFromPool(/obj/effect/overlay, epicenter)
|
||||
pulse.icon = 'icons/effects/effects.dmi'
|
||||
pulse.icon_state = "emppulse"
|
||||
pulse.name = "emp pulse"
|
||||
|
||||
@@ -12,8 +12,8 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
w_class = 2.0
|
||||
slot_flags = SLOT_ID | SLOT_BELT
|
||||
sprite_sheets = list("Resomi" = 'icons/mob/species/resomi/id.dmi')
|
||||
offset_light = 1
|
||||
diona_restricted_light = 1//Light emitted by this object or creature has limited interaction with diona
|
||||
//offset_light = 1
|
||||
//diona_restricted_light = 1//Light emitted by this object or creature has limited interaction with diona
|
||||
|
||||
//Main variables
|
||||
var/owner = null
|
||||
@@ -49,6 +49,7 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
var/list/conversations = list() // For keeping up with who we have PDA messsages from.
|
||||
var/new_message = 0 //To remove hackish overlay check
|
||||
var/new_news = 0
|
||||
var/pdafilter = 0 //0-all,1-synth,2-command,3-sec,4-eng,5-sci,6-cargo,7-service,8-med
|
||||
|
||||
var/active_feed // The selected feed
|
||||
var/list/warrant // The warrant as we last knew it
|
||||
@@ -440,12 +441,39 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
if(conversations.Find("\ref[P]"))
|
||||
convopdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "1")))
|
||||
else
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
switch(pdafilter)
|
||||
if(0) //All
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(1) //Synth -- Not working
|
||||
if(P == /obj/item/device/pda/ai)
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(2) //Command
|
||||
if(P.icon_state == "pda-hop"||P.icon_state == "pda-hos"||P.icon_state == "pda-ce"||P.icon_state == "pda-cmo"||P.icon_state == "pda-rd"||P.icon_state == "pda-c"||P.icon_state == "pda-h")
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(3) //sec
|
||||
if(P.icon_state == "pda-hos"||P.icon_state == "pda-warden"||P.icon_state == "pda-det"||P.icon_state == "pda-sec"||P.icon_state == "pda-s")
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(4) //eng
|
||||
if(P.icon_state == "pda-ce"||P.icon_state == "pda-e"||P.icon_state == "pda-atmo")
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(5) //sci
|
||||
if(P.icon_state == "pda-rd"||P.icon_state == "pda-tox"||P.icon_state == "pda-v"||P.icon_state == "pda-robot")
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(6) //cargo
|
||||
if(P.icon_state == "pda-hop"||P.icon_state == "pda-cargo"||P.icon_state == "pda-q"||P.icon_state == "pda-miner")
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(7) //service
|
||||
if(P.icon_state == "pda-hop"||P.icon_state == "pda-j"||P.icon_state == "pda-bar"||P.icon_state == "pda-holy"||P.icon_state == "pda-lawyer"||P.icon_state == "pda-libb"||P.icon_state == "pda-hydro"||P.icon_state == "pda-chef")
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
if(8) //medical
|
||||
if(P.icon_state == "pda-cmo"||P.icon_state == "pda-v"||P.icon_state == "pda-m"||P.icon_state == "pda-chem")
|
||||
pdas.Add(list(list("Name" = "[P]", "Reference" = "\ref[P]", "Detonate" = "[P.detonate]", "inconvo" = "0")))
|
||||
count++
|
||||
|
||||
data["convopdas"] = convopdas
|
||||
data["pdas"] = pdas
|
||||
data["pda_count"] = count
|
||||
data["pdafilter"] = pdafilter
|
||||
|
||||
if(mode==21)
|
||||
data["messagescount"] = tnote.len
|
||||
@@ -702,7 +730,12 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
active_conversation = null
|
||||
if(mode==21)
|
||||
mode=2
|
||||
|
||||
|
||||
|
||||
if("Filter") // Filters through available pdas
|
||||
if (href_list["option"])
|
||||
pdafilter = sanitize_integer(text2num(href_list["option"]), 0, 8, pdafilter)
|
||||
|
||||
if("Ringtone")
|
||||
var/t = input(U, "Please enter new ringtone", name, ttone) as text|null
|
||||
if (in_range(src, U) && loc == U)
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
qdel(active_dummy)
|
||||
active_dummy = null
|
||||
usr << "<span class='notice'>You deactivate the [src].</span>"
|
||||
var/obj/effect/overlay/T = PoolOrNew(/obj/effect/overlay, get_turf(src))
|
||||
var/obj/effect/overlay/T = getFromPool(/obj/effect/overlay, get_turf(src))
|
||||
T.icon = 'icons/effects/effects.dmi'
|
||||
flick("emppulse",T)
|
||||
spawn(8) qdel(T)
|
||||
@@ -54,7 +54,7 @@
|
||||
playsound(get_turf(src), 'sound/effects/pop.ogg', 100, 1, -6)
|
||||
var/obj/O = new saved_item(src)
|
||||
if(!O) return
|
||||
var/obj/effect/dummy/chameleon/C = PoolOrNew(/obj/effect/dummy/chameleon, usr.loc)
|
||||
var/obj/effect/dummy/chameleon/C = getFromPool(/obj/effect/dummy/chameleon, usr.loc)
|
||||
C.activate(O, usr, saved_icon, saved_icon_state, saved_overlays, src)
|
||||
qdel(O)
|
||||
usr << "<span class='notice'>You activate the [src].</span>"
|
||||
|
||||
@@ -86,7 +86,7 @@
|
||||
var/obj/item/organ/eyes/E = H.internal_organs_by_name["eyes"]
|
||||
if(!E)
|
||||
return
|
||||
usr << "\red Your eyes burn with the intense light of the flash!."
|
||||
usr << span("alert", "Your eyes burn with the intense light of the flash!.")
|
||||
E.damage += rand(10, 11)
|
||||
if(E.damage > 12)
|
||||
M.eye_blurry += rand(3,6)
|
||||
|
||||
@@ -7,14 +7,15 @@
|
||||
w_class = 2
|
||||
flags = CONDUCT
|
||||
slot_flags = SLOT_BELT
|
||||
offset_light = 1
|
||||
diona_restricted_light = 1//Light emitted by this object or creature has limited interaction with diona
|
||||
light_color = LIGHT_COLOR_HALOGEN
|
||||
//offset_light = 1
|
||||
//diona_restricted_light = 1//Light emitted by this object or creature has limited interaction with diona
|
||||
|
||||
matter = list(DEFAULT_WALL_MATERIAL = 50,"glass" = 20)
|
||||
|
||||
action_button_name = "Toggle Flashlight"
|
||||
var/on = 0
|
||||
var/brightness_on = 4 //luminosity when on
|
||||
var/brightness_on = 3 //luminosity when on
|
||||
|
||||
/obj/item/device/flashlight/initialize()
|
||||
..()
|
||||
@@ -23,10 +24,10 @@
|
||||
/obj/item/device/flashlight/update_icon()
|
||||
if(on)
|
||||
icon_state = "[initial(icon_state)]-on"
|
||||
set_light(brightness_on)
|
||||
set_light(brightness_on, update_type = UPDATE_NOW)
|
||||
else
|
||||
icon_state = "[initial(icon_state)]"
|
||||
set_light(0)
|
||||
set_light(0, update_type = UPDATE_NOW)
|
||||
|
||||
/obj/item/device/flashlight/attack_self(mob/user)
|
||||
if(!isturf(user.loc))
|
||||
@@ -110,7 +111,7 @@
|
||||
desc = "A high-luminosity flashlight for specialist duties."
|
||||
icon_state = "heavyflashlight"
|
||||
item_state = "heavyflashlight"
|
||||
brightness_on = 7
|
||||
brightness_on = 4
|
||||
w_class = 3
|
||||
matter = list(DEFAULT_WALL_MATERIAL = 100,"glass" = 70)
|
||||
contained_sprite = 1
|
||||
@@ -166,15 +167,15 @@
|
||||
w_class = 2.0
|
||||
brightness_on = 8 // Pretty bright.
|
||||
light_power = 3
|
||||
light_color = "#e58775"
|
||||
light_color = LIGHT_COLOR_FLARE
|
||||
icon_state = "flare"
|
||||
item_state = "flare"
|
||||
action_button_name = null //just pull it manually, neckbeard.
|
||||
var/fuel = 0
|
||||
var/on_damage = 7
|
||||
var/produce_heat = 1500
|
||||
offset_light = 0//Emits light all around, not directional
|
||||
diona_restricted_light = 0
|
||||
//offset_light = 0//Emits light all around, not directional
|
||||
//diona_restricted_light = 0
|
||||
|
||||
/obj/item/device/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.
|
||||
@@ -224,12 +225,13 @@
|
||||
w_class = 1
|
||||
brightness_on = 6
|
||||
on = 1 //Bio-luminesence has one setting, on.
|
||||
offset_light = 0//Emits light all around, not directional
|
||||
diona_restricted_light = 0
|
||||
light_color = LIGHT_COLOR_SLIME_LAMP
|
||||
//offset_light = 0//Emits light all around, not directional
|
||||
//diona_restricted_light = 0
|
||||
|
||||
/obj/item/device/flashlight/slime/New()
|
||||
..()
|
||||
set_light(brightness_on)
|
||||
set_light(brightness_on, update_type = UPDATE_NOW)
|
||||
|
||||
/obj/item/device/flashlight/slime/update_icon()
|
||||
return
|
||||
@@ -243,15 +245,15 @@
|
||||
name = "green glowstick"
|
||||
desc = "A green military-grade glowstick."
|
||||
w_class = 2
|
||||
brightness_on = 3
|
||||
light_power = 2
|
||||
brightness_on = 1.5
|
||||
light_power = 1
|
||||
light_color = "#49F37C"
|
||||
icon = 'icons/obj/glowsticks.dmi'
|
||||
icon_state = "glowstick"
|
||||
item_state = "glowstick"
|
||||
contained_sprite = 1
|
||||
offset_light = 0
|
||||
diona_restricted_light = 0
|
||||
//offset_light = 0
|
||||
//diona_restricted_light = 0
|
||||
var/fuel = 0
|
||||
|
||||
/obj/item/device/flashlight/glowstick/New()
|
||||
@@ -296,27 +298,27 @@
|
||||
/obj/item/device/flashlight/glowstick/red
|
||||
name = "red glowstick"
|
||||
desc = "A red military-grade glowstick."
|
||||
light_color = "#FC0F29"
|
||||
light_color = LIGHT_COLOR_RED //"#FC0F29"
|
||||
icon_state = "glowstick_red"
|
||||
item_state = "glowstick_red"
|
||||
|
||||
/obj/item/device/flashlight/glowstick/blue
|
||||
name = "blue glowstick"
|
||||
desc = "A blue military-grade glowstick."
|
||||
light_color = "#599DFF"
|
||||
light_color = LIGHT_COLOR_BLUE //"#599DFF"
|
||||
icon_state = "glowstick_blue"
|
||||
item_state = "glowstick_blue"
|
||||
|
||||
/obj/item/device/flashlight/glowstick/orange
|
||||
name = "orange glowstick"
|
||||
desc = "A orange military-grade glowstick."
|
||||
light_color = "#FA7C0B"
|
||||
light_color = LIGHT_COLOR_ORANGE//"#FA7C0B"
|
||||
icon_state = "glowstick_orange"
|
||||
item_state = "glowstick_orange"
|
||||
|
||||
/obj/item/device/flashlight/glowstick/yellow
|
||||
name = "yellow glowstick"
|
||||
desc = "A yellow military-grade glowstick."
|
||||
light_color = "#FEF923"
|
||||
light_color = LIGHT_COLOR_YELLOW //"#FEF923"
|
||||
icon_state = "glowstick_yellow"
|
||||
item_state = "glowstick_yellow"
|
||||
|
||||
@@ -0,0 +1,55 @@
|
||||
// Light meter, intended for debugging.
|
||||
|
||||
/obj/item/device/light_meter
|
||||
name = "light meter"
|
||||
desc = "A simple device that measures ambient light levels."
|
||||
icon = 'icons/obj/device.dmi'
|
||||
icon_state = "locator"
|
||||
|
||||
// Copied from debugger.dm
|
||||
flags = CONDUCT
|
||||
force = 5.0
|
||||
w_class = 2.0
|
||||
throwforce = 5.0
|
||||
throw_range = 15
|
||||
throw_speed = 3
|
||||
matter = list(DEFAULT_WALL_MATERIAL = 50,"glass" = 20)
|
||||
var/low = 0
|
||||
var/high = 1
|
||||
|
||||
/obj/item/device/light_meter/attack_self(mob/user as mob)
|
||||
var/turf/T = get_turf(user.loc)
|
||||
if (!T)
|
||||
user << span("alert", "Unable to read light levels.")
|
||||
return
|
||||
|
||||
var/visible_reading = T.get_lumcount(low, high)
|
||||
var/uv_reading = T.get_uv_lumcount(low, high)
|
||||
|
||||
var/reading = "Light analysis for <b>\the [T]</b>.<br>"
|
||||
reading += "Visible light: <b>[visible_reading]</b> lx<br>"
|
||||
reading += "Ultraviolet light: <b>[uv_reading]</b> lx ([uv_reading * 5.5 - 1.5] adlx)"
|
||||
|
||||
usr << span("notice", reading)
|
||||
|
||||
/obj/item/device/light_meter/verb/set_low_bound()
|
||||
set category = "Object"
|
||||
set name = "Set Detector Low-Bound"
|
||||
set src in usr
|
||||
|
||||
var/num = input(usr, "Please enter the low-bound for the detector") as num|null
|
||||
if (null)
|
||||
return
|
||||
|
||||
low = num
|
||||
|
||||
/obj/item/device/light_meter/verb/set_high_bound()
|
||||
set category = "Object"
|
||||
set name = "Set Detector High-Bound"
|
||||
set src in usr
|
||||
|
||||
var/num = input(usr, "Please enter the high-bound for the detector") as num|null
|
||||
if (null)
|
||||
return
|
||||
|
||||
high = num
|
||||
@@ -116,7 +116,7 @@
|
||||
spawn(0)
|
||||
if(!src || !reagents.total_volume) return
|
||||
|
||||
var/obj/effect/effect/water/W = PoolOrNew(/obj/effect/effect/water, get_turf(src))
|
||||
var/obj/effect/effect/water/W = getFromPool(/obj/effect/effect/water, get_turf(src))
|
||||
var/turf/my_target
|
||||
if(a <= the_targets.len)
|
||||
my_target = the_targets[a]
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
if(ptank)
|
||||
ptank.loc = T
|
||||
ptank = null
|
||||
PoolOrNew(/obj/item/stack/rods, T)
|
||||
getFromPool(/obj/item/stack/rods, T)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
/obj/item/weapon/grenade/smokebomb/New()
|
||||
..()
|
||||
src.smoke = PoolOrNew(/datum/effect/effect/system/smoke_spread/bad)
|
||||
src.smoke = getFromPool(/datum/effect/effect/system/smoke_spread/bad)
|
||||
src.smoke.attach(src)
|
||||
|
||||
/obj/item/weapon/grenade/smokebomb/Destroy()
|
||||
|
||||
@@ -111,7 +111,7 @@
|
||||
. = ..()
|
||||
|
||||
if(.)
|
||||
var/datum/effect/effect/system/spark_spread/spark_system = PoolOrNew(/datum/effect/effect/system/spark_spread)
|
||||
var/datum/effect/effect/system/spark_spread/spark_system = getFromPool(/datum/effect/effect/system/spark_spread)
|
||||
spark_system.set_up(5, 0, user.loc)
|
||||
spark_system.start()
|
||||
playsound(user.loc, 'sound/weapons/blade1.ogg', 50, 1)
|
||||
|
||||
@@ -105,3 +105,80 @@
|
||||
update_force()
|
||||
user.visible_message(span("danger", "[user] smashes the [src] into [M], causing it to break open and strew its contents across the area"))
|
||||
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox
|
||||
name = "rainbow lunchbox"
|
||||
icon = 'icons/obj/lunchbox.dmi'
|
||||
force = 3
|
||||
throwforce = 5
|
||||
contained_sprite = 1
|
||||
icon_state = "lunchbox_rainbow"
|
||||
item_state = "lunchbox_rainbow"
|
||||
desc = "A little lunchbox. This one is the colors of the rainbow."
|
||||
attack_verb = list("lunched")
|
||||
w_class = 3
|
||||
max_storage_space = 8
|
||||
var/filled = FALSE
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/New()
|
||||
..()
|
||||
if(filled)
|
||||
var/list/lunches = lunchables_lunches()
|
||||
var/lunch = lunches[pick(lunches)]
|
||||
new lunch(src)
|
||||
|
||||
var/list/snacks = lunchables_snacks()
|
||||
var/snack = snacks[pick(snacks)]
|
||||
new snack(src)
|
||||
|
||||
var/list/drinks = lunchables_drinks()
|
||||
var/drink = drinks[pick(drinks)]
|
||||
new drink(src)
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/filled
|
||||
filled = TRUE
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/heart
|
||||
name = "heart lunchbox"
|
||||
icon_state = "lunchbox_hearts"
|
||||
item_state = "lunchbox_hearts"
|
||||
desc = "A little lunchbox. This one has little hearts on it."
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/heart/filled
|
||||
filled = TRUE
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/cat
|
||||
name = "cat lunchbox"
|
||||
icon_state = "lunchbox_cat"
|
||||
item_state = "lunchbox_cat"
|
||||
desc = "A little lunchbox. This one has a cat stamp on it."
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/cat/filled
|
||||
filled = TRUE
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/nt
|
||||
name = "NanoTrasen brand lunchbox"
|
||||
icon_state = "lunchbox_nanotrasen"
|
||||
item_state = "lunchbox_nanotrasen"
|
||||
desc = "A little lunchbox. This one is branded with the NanoTrasen logo."
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/nt/filled
|
||||
filled = TRUE
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/nymph
|
||||
name = "\improper diona nymph lunchbox"
|
||||
icon_state = "lunchbox_dionanymph"
|
||||
item_state = "lunchbox_dionanymph"
|
||||
desc = "A little lunchbox. This one has a diona nymph on the side."
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/nymph/filled
|
||||
filled = TRUE
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/syndicate
|
||||
name = "black and red lunchbox"
|
||||
icon_state = "lunchbox_syndie"
|
||||
item_state = "lunchbox_syndie"
|
||||
desc = "A little lunchbox. This one is a sleek black and red."
|
||||
|
||||
/obj/item/weapon/storage/toolbox/lunchbox/syndicate/filled
|
||||
filled = TRUE
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
..()
|
||||
|
||||
/obj/structure/curtain/proc/toggle()
|
||||
opacity = !opacity
|
||||
src.set_opacity(!src.opacity)
|
||||
if(opacity)
|
||||
icon_state = "closed"
|
||||
layer = SHOWER_CLOSED_LAYER
|
||||
|
||||
@@ -96,7 +96,7 @@
|
||||
if(iswirecutter(W))
|
||||
if(!shock(user, 100))
|
||||
playsound(loc, 'sound/items/Wirecutter.ogg', 100, 1)
|
||||
PoolOrNew(/obj/item/stack/rods, list(get_turf(src), destroyed ? 1 : 2))
|
||||
getFromPool(/obj/item/stack/rods, list(get_turf(src), destroyed ? 1 : 2))
|
||||
qdel(src)
|
||||
else if((isscrewdriver(W)) && (istype(loc, /turf/simulated) || anchored))
|
||||
if(!shock(user, 90))
|
||||
@@ -151,7 +151,7 @@
|
||||
|
||||
else if(!(W.flags & CONDUCT) || !shock(user, 70))
|
||||
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
|
||||
user.do_attack_animation(src)
|
||||
user.do_attack_animation(src)
|
||||
playsound(loc, 'sound/effects/grillehit.ogg', 80, 1)
|
||||
switch(W.damtype)
|
||||
if("fire")
|
||||
@@ -169,11 +169,11 @@
|
||||
density = 0
|
||||
destroyed = 1
|
||||
update_icon()
|
||||
PoolOrNew(/obj/item/stack/rods, get_turf(src))
|
||||
getFromPool(/obj/item/stack/rods, get_turf(src))
|
||||
|
||||
else
|
||||
if(health <= -6)
|
||||
PoolOrNew(/obj/item/stack/rods, get_turf(src))
|
||||
getFromPool(/obj/item/stack/rods, get_turf(src))
|
||||
qdel(src)
|
||||
return
|
||||
return
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
var/obj/item/weapon/weldingtool/WT = C
|
||||
if(WT.remove_fuel(0, user))
|
||||
user << "<span class='notice'>Slicing lattice joints ...</span>"
|
||||
PoolOrNew(/obj/item/stack/rods, src.loc)
|
||||
getFromPool(/obj/item/stack/rods, src.loc)
|
||||
qdel(src)
|
||||
|
||||
return
|
||||
|
||||
@@ -180,13 +180,13 @@
|
||||
spawn(50)
|
||||
if(src && on)
|
||||
ismist = 1
|
||||
mymist = PoolOrNew(/obj/effect/mist,loc)
|
||||
mymist = getFromPool(/obj/effect/mist,loc)
|
||||
else
|
||||
ismist = 1
|
||||
mymist = PoolOrNew(/obj/effect/mist,loc)
|
||||
mymist = getFromPool(/obj/effect/mist,loc)
|
||||
else if(ismist)
|
||||
ismist = 1
|
||||
mymist = PoolOrNew(/obj/effect/mist,loc)
|
||||
mymist = getFromPool(/obj/effect/mist,loc)
|
||||
spawn(250)
|
||||
if(src && !on)
|
||||
qdel(mymist)
|
||||
|
||||
@@ -79,7 +79,7 @@ obj/structure/windoor_assembly/Destroy()
|
||||
user << "<span class='notice'>You dissasembled the windoor assembly!</span>"
|
||||
new /obj/item/stack/material/glass/reinforced(get_turf(src), 5)
|
||||
if(secure)
|
||||
PoolOrNew(/obj/item/stack/rods, list(get_turf(src), 4))
|
||||
getFromPool(/obj/item/stack/rods, list(get_turf(src), 4))
|
||||
qdel(src)
|
||||
else
|
||||
user << "<span class='notice'>You need more welding fuel to dissassemble the windoor assembly.</span>"
|
||||
|
||||
@@ -91,11 +91,11 @@
|
||||
index = 0
|
||||
while(index < 2)
|
||||
new shardtype(loc) //todo pooling?
|
||||
if(reinf) PoolOrNew(/obj/item/stack/rods, loc)
|
||||
if(reinf) getFromPool(/obj/item/stack/rods, loc)
|
||||
index++
|
||||
else
|
||||
new shardtype(loc) //todo pooling?
|
||||
if(reinf) PoolOrNew(/obj/item/stack/rods, loc)
|
||||
if(reinf) getFromPool(/obj/item/stack/rods, loc)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
/obj/effect/wingrille_spawn/proc/activate()
|
||||
if(activated) return
|
||||
if (!locate(/obj/structure/grille) in get_turf(src))
|
||||
var/obj/structure/grille/G = PoolOrNew(/obj/structure/grille, src.loc)
|
||||
var/obj/structure/grille/G = getFromPool(/obj/structure/grille, src.loc)
|
||||
handle_grille_spawn(G)
|
||||
var/list/neighbours = list()
|
||||
for (var/dir in cardinal)
|
||||
@@ -49,7 +49,7 @@
|
||||
found_connection = 1
|
||||
qdel(W)
|
||||
if(!found_connection)
|
||||
var/obj/structure/window/new_win = PoolOrNew(win_path, src.loc)
|
||||
var/obj/structure/window/new_win = getFromPool(win_path, src.loc)
|
||||
new_win.set_dir(dir)
|
||||
handle_window_spawn(new_win)
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user