mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-18 18:44:48 +01:00
Cryogenic anomalies & armor (#21603)
* cryogenic anomaly * sprite * reactive gelidic armor * america number 1 raaah * sprite (thanks atp) * qwerty suggestion * floor freezing * Update code/game/objects/effects/anomalies.dm Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com> * steel review commit 2 * whitespace apparently? idk * whitespace fix (real) * vetus * Update code/game/objects/effects/anomalies.dm Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> * Update code/game/objects/effects/anomalies.dm Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> * Update code/game/objects/effects/anomalies.dm Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> * Update code/modules/clothing/suits/armor_suits.dm Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> * Update code/modules/clothing/suits/armor_suits.dm Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> * Update code/modules/mob/living/simple_animal/hostile/megafauna/ancient_robot.dm Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com> * early return thing --------- Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com> Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
This commit is contained in:
@@ -138,6 +138,9 @@
|
||||
if(flag & LINDA_SPAWN_HEAT)
|
||||
G.temperature += 1000
|
||||
|
||||
if(flag & LINDA_SPAWN_COLD)
|
||||
G.temperature = TCMB
|
||||
|
||||
if(flag & LINDA_SPAWN_TOXINS)
|
||||
G.toxins += amount
|
||||
|
||||
|
||||
@@ -517,6 +517,54 @@
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/obj/item/clothing/suit/armor/reactive/cryo
|
||||
name = "reactive gelidic armor" //is "gelidic" a word? probably not, but it sounds cool
|
||||
desc = "This armor harnesses a cryogenic anomaly core to defend its user from the cold and attacks alike. Its unstable thermal regulation system occasionally vents gasses."
|
||||
|
||||
/obj/item/clothing/suit/armor/reactive/cryo/equipped(mob/user, slot)
|
||||
..()
|
||||
if(slot != slot_wear_suit)
|
||||
return
|
||||
ADD_TRAIT(user, TRAIT_RESISTCOLD, "[UID()]")
|
||||
|
||||
/obj/item/clothing/suit/armor/reactive/cryo/dropped(mob/user, silent)
|
||||
..()
|
||||
REMOVE_TRAIT(user, TRAIT_RESISTCOLD, "[UID()]")
|
||||
|
||||
/obj/item/clothing/suit/armor/reactive/cryo/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
|
||||
if(!active)
|
||||
return FALSE
|
||||
if(reaction_check(hitby) && use_power())
|
||||
owner.visible_message("<span class='danger'>[src] blocks [attack_text], sending out freezing bolts!</span>")
|
||||
|
||||
for(var/mob/M in oview(get_turf(src), 7))
|
||||
shootAt(M)
|
||||
|
||||
if(prob(10)) //rarely vent gasses
|
||||
owner.visible_message("<span class='warning'>[src] vents excess coolant!</span>")
|
||||
playsound(loc, 'sound/effects/refill.ogg', 50, TRUE)
|
||||
|
||||
var/turf/simulated/T = get_turf(src)
|
||||
if(istype(T))
|
||||
T.atmos_spawn_air(LINDA_SPAWN_COLD | LINDA_SPAWN_N2O | LINDA_SPAWN_CO2, 20)
|
||||
|
||||
disable(rand(1, 3))
|
||||
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/obj/item/clothing/suit/armor/reactive/cryo/proc/shootAt(atom/movable/target)
|
||||
var/turf/T = get_turf(src)
|
||||
var/turf/U = get_turf(target)
|
||||
if(!T || !U)
|
||||
return
|
||||
var/obj/item/projectile/temp/basilisk/O = new /obj/item/projectile/temp/basilisk(T)
|
||||
playsound(get_turf(src), 'sound/weapons/taser2.ogg', 75, TRUE)
|
||||
O.current = T
|
||||
O.yo = U.y - T.y
|
||||
O.xo = U.x - T.x
|
||||
O.fire()
|
||||
|
||||
|
||||
/obj/item/clothing/suit/armor/reactive/stealth
|
||||
name = "reactive stealth armor"
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
/datum/event/anomaly/anomaly_cryo
|
||||
name = "Anomaly: Cryogenic"
|
||||
startWhen = 3
|
||||
announceWhen = 10
|
||||
anomaly_path = /obj/effect/anomaly/cryo
|
||||
|
||||
/datum/event/anomaly/anomaly_cryo/announce()
|
||||
GLOB.minor_announcement.Announce("Cryogenic anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert", 'sound/AI/anomaly_pyro.ogg')
|
||||
@@ -5,4 +5,4 @@
|
||||
anomaly_path = /obj/effect/anomaly/pyro
|
||||
|
||||
/datum/event/anomaly/anomaly_pyro/announce()
|
||||
GLOB.minor_announcement.Announce("Atmospheric anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert", 'sound/AI/anomaly_pyro.ogg')
|
||||
GLOB.minor_announcement.Announce("Pyroclastic anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert", 'sound/AI/anomaly_pyro.ogg')
|
||||
|
||||
@@ -70,7 +70,7 @@ GLOBAL_LIST_EMPTY(event_last_fired)
|
||||
for(var/event_meta in last_event_time) if(possible_events[event_meta])
|
||||
var/time_passed = world.time - GLOB.event_last_fired[event_meta]
|
||||
var/half_of_round = GLOB.configuration.event.expected_round_length / 2
|
||||
var/weight_modifier = min(1, 1 - ((half_of_round - time_passed) / half_of_round))
|
||||
var/weight_modifier = min(1, 1 - ((half_of_round - time_passed) / half_of_round))
|
||||
//With this formula, an event ran 30 minutes ago has half weight, and an event ran an hour ago, has 100 % weight. This works better in general for events, as super high weight events are impacted in a meaningful way.
|
||||
var/new_weight = max(possible_events[event_meta] * weight_modifier, 0)
|
||||
if(new_weight)
|
||||
@@ -179,6 +179,7 @@ GLOBAL_LIST_EMPTY(event_last_fired)
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Vent Clog", /datum/event/vent_clog, 250),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Wormholes", /datum/event/wormholes, 150),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Pyro Anomaly", /datum/event/anomaly/anomaly_pyro, 75, list(ASSIGNMENT_ENGINEER = 60)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Cryo Anomaly", /datum/event/anomaly/anomaly_cryo, 75, list(ASSIGNMENT_ENGINEER = 60)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Vortex Anomaly", /datum/event/anomaly/anomaly_vortex, 75, list(ASSIGNMENT_ENGINEER = 25)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Bluespace Anomaly", /datum/event/anomaly/anomaly_bluespace, 75, list(ASSIGNMENT_ENGINEER = 25)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Flux Anomaly", /datum/event/anomaly/anomaly_flux, 75, list(ASSIGNMENT_ENGINEER = 50)),
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#define PYRO 3
|
||||
#define FLUX 4
|
||||
#define VORTEX 5
|
||||
#define CRYO 6
|
||||
#define TOP_RIGHT 1
|
||||
#define TOP_LEFT 2
|
||||
#define BOTTOM_RIGHT 3
|
||||
@@ -101,7 +102,7 @@ Difficulty: Hard
|
||||
BR = new /mob/living/simple_animal/hostile/ancient_robot_leg(loc, src, BOTTOM_RIGHT)
|
||||
BL = new /mob/living/simple_animal/hostile/ancient_robot_leg(loc, src, BOTTOM_LEFT)
|
||||
beam = new /obj/effect/abstract(loc)
|
||||
mode = pick(BLUESPACE, GRAV, PYRO, FLUX, VORTEX) //picks one of the 5 cores.
|
||||
mode = pick(BLUESPACE, GRAV, PYRO, FLUX, VORTEX, CRYO) //picks one of the 6 cores
|
||||
if(mode == FLUX) // Main attack is shock, so flux makes it stronger
|
||||
melee_damage_lower = 25
|
||||
melee_damage_upper = 25
|
||||
@@ -160,6 +161,8 @@ Difficulty: Hard
|
||||
core_type = /obj/item/assembly/signaler/anomaly/flux
|
||||
if(VORTEX)
|
||||
core_type = /obj/item/assembly/signaler/anomaly/vortex
|
||||
if(CRYO)
|
||||
core_type = /obj/item/assembly/signaler/anomaly/cryo
|
||||
|
||||
var/crate_type = pick(loot)
|
||||
var/obj/structure/closet/crate/C = new crate_type(loc)
|
||||
@@ -345,6 +348,10 @@ Difficulty: Hard
|
||||
for(var/turf/turf in range(9,get_turf(target)))
|
||||
if(prob(15))
|
||||
new /obj/effect/temp_visual/target/ancient(turf)
|
||||
if(CRYO)
|
||||
visible_message("<span class='danger'>[src]'s shell opens slightly, as sensors begin locking on to everyone around it!</span>")
|
||||
for(var/mob/living/carbon/human/H in view(7, src))
|
||||
H.apply_status_effect(STATUS_EFFECT_CRYO_BEAM, src)
|
||||
|
||||
/mob/living/simple_animal/hostile/megafauna/ancient_robot/proc/spawn_anomalies()
|
||||
say(pick("JKVRUEOTM XGC VUCKX", "KXXUX OT GTUSGRE IUTZGOTSKTZ", "YZGHOROZE OT OTYZGHOROZE OT YZGHOROZE OT OTYZGH-"))
|
||||
@@ -373,6 +380,8 @@ Difficulty: Hard
|
||||
A.knockdown = TRUE
|
||||
if(VORTEX)
|
||||
new /obj/effect/anomaly/bhole(spot, 150, FALSE)
|
||||
if(CRYO)
|
||||
new /obj/effect/anomaly/cryo(spot, 150, FALSE)
|
||||
anomalies++
|
||||
return
|
||||
|
||||
@@ -518,6 +527,14 @@ Difficulty: Hard
|
||||
for(var/atom/A in T)
|
||||
A.ex_act(3) //Body is immune to explosions of this strength.
|
||||
T.ex_act(3)
|
||||
if(mode == CRYO)
|
||||
var/turf/simulated/S = get_turf(src)
|
||||
S.MakeSlippery(TURF_WET_ICE)
|
||||
for(var/turf/T in range (1, src))
|
||||
new /obj/effect/snowcloud(T)
|
||||
for(var/mob/living/carbon/C in T.contents)
|
||||
C.bodytemperature = max(0, C.bodytemperature - 300) //Take a chill pill.
|
||||
C.apply_status_effect(/datum/status_effect/freon/watcher) // 0.8 seconds of no moving, should be funny.
|
||||
|
||||
beam.forceMove(get_turf(src))
|
||||
return ..()
|
||||
@@ -775,4 +792,5 @@ Difficulty: Hard
|
||||
#undef GRAV
|
||||
#undef PYRO
|
||||
#undef FLUX
|
||||
#undef CRYO
|
||||
#undef VORTEX
|
||||
|
||||
@@ -24,6 +24,13 @@
|
||||
anomaly_type = /obj/effect/anomaly/pyro
|
||||
origin_tech = "plasmatech=7"
|
||||
|
||||
/obj/item/assembly/signaler/anomaly/cryo
|
||||
name = "\improper cryogenic anomaly core"
|
||||
desc = "The neutralized core of a cryogenic anomaly. Rime is forming on its cold surface. It'd probably be valuable for research."
|
||||
icon_state = "cryo_core"
|
||||
anomaly_type = /obj/effect/anomaly/cryo
|
||||
origin_tech = "biotech=7"
|
||||
|
||||
/obj/item/assembly/signaler/anomaly/grav
|
||||
name = "\improper gravitational anomaly core"
|
||||
desc = "The neutralized core of a gravitational anomaly. It feels much heavier than it looks. It'd probably be valuable for research."
|
||||
@@ -57,7 +64,7 @@
|
||||
|
||||
/obj/item/assembly/signaler/anomaly/random/New()
|
||||
..()
|
||||
var/list/types = list(/obj/item/assembly/signaler/anomaly/pyro, /obj/item/assembly/signaler/anomaly/grav, /obj/item/assembly/signaler/anomaly/flux, /obj/item/assembly/signaler/anomaly/bluespace, /obj/item/assembly/signaler/anomaly/vortex)
|
||||
var/list/types = list(/obj/item/assembly/signaler/anomaly/pyro, /obj/item/assembly/signaler/anomaly/cryo, /obj/item/assembly/signaler/anomaly/grav, /obj/item/assembly/signaler/anomaly/flux, /obj/item/assembly/signaler/anomaly/bluespace, /obj/item/assembly/signaler/anomaly/vortex)
|
||||
var/A = pick(types)
|
||||
new A(loc)
|
||||
qdel(src)
|
||||
@@ -74,23 +81,17 @@
|
||||
/obj/item/assembly/signaler/anomaly/grav = /obj/item/clothing/suit/armor/reactive/repulse,
|
||||
/obj/item/assembly/signaler/anomaly/flux = /obj/item/clothing/suit/armor/reactive/tesla,
|
||||
/obj/item/assembly/signaler/anomaly/bluespace = /obj/item/clothing/suit/armor/reactive/teleport,
|
||||
/obj/item/assembly/signaler/anomaly/pyro = /obj/item/clothing/suit/armor/reactive/fire
|
||||
/obj/item/assembly/signaler/anomaly/pyro = /obj/item/clothing/suit/armor/reactive/fire,
|
||||
/obj/item/assembly/signaler/anomaly/cryo = /obj/item/clothing/suit/armor/reactive/cryo,
|
||||
/obj/item/assembly/signaler/anomaly/vortex = /obj/item/clothing/suit/armor/reactive/stealth
|
||||
)
|
||||
|
||||
if(istype(I, /obj/item/assembly/signaler/anomaly))
|
||||
var/obj/item/assembly/signaler/anomaly/A = I
|
||||
var/armour_path = /obj/item/clothing/suit/armor/reactive/stealth //Fallback
|
||||
if(istype(I, /obj/item/assembly/signaler/anomaly/grav))
|
||||
armour_path = /obj/item/clothing/suit/armor/reactive/repulse
|
||||
if(istype(I, /obj/item/assembly/signaler/anomaly/flux))
|
||||
armour_path = /obj/item/clothing/suit/armor/reactive/tesla
|
||||
if(istype(I, /obj/item/assembly/signaler/anomaly/bluespace))
|
||||
armour_path = /obj/item/clothing/suit/armor/reactive/teleport
|
||||
if(istype(I, /obj/item/assembly/signaler/anomaly/pyro))
|
||||
armour_path = /obj/item/clothing/suit/armor/reactive/fire
|
||||
if(istype(I, /obj/item/assembly/signaler/anomaly/vortex))
|
||||
armour_path = /obj/item/clothing/suit/armor/reactive/stealth // Vortex needs one, this is just temporary(TM) till one is coded for them.
|
||||
to_chat(user, "<span class='notice'>You insert [A] into the chest plate, and the armour gently hums to life.</span>")
|
||||
var/armour_path = anomaly_armour_types[A.type]
|
||||
if(!armour_path)
|
||||
armour_path = /obj/item/clothing/suit/armor/reactive/stealth //Fallback
|
||||
to_chat(user, "<span class='notice'>You insert [A] into the chest plate, and the armor gently hums to life.</span>")
|
||||
new armour_path(get_turf(src))
|
||||
qdel(src)
|
||||
qdel(A)
|
||||
|
||||
Reference in New Issue
Block a user