Files
Alexis 21b4095dfd [MDB IGNORE] [IDB IGNORE] Upstream Sync - 04/17/2026 (#5453)
Upstream 04/17/2026

fixes https://github.com/Bubberstation/Bubberstation/issues/5549

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: tgstation-ci[bot] <179393467+tgstation-ci[bot]@users.noreply.github.com>
Co-authored-by: ArcaneMusic <41715314+ArcaneMusic@users.noreply.github.com>
Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
Co-authored-by: Rhials <28870487+Rhials@users.noreply.github.com>
Co-authored-by: rageguy505 <54517726+rageguy505@users.noreply.github.com>
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
Co-authored-by: Aliceee2ch <160794176+Aliceee2ch@users.noreply.github.com>
Co-authored-by: Time-Green <7501474+Time-Green@users.noreply.github.com>
Co-authored-by: Tsar-Salat <62388554+Tsar-Salat@users.noreply.github.com>
Co-authored-by: SmArtKar <44720187+SmArtKar@users.noreply.github.com>
Co-authored-by: Maxipat <108554989+Maxipat112@users.noreply.github.com>
Co-authored-by: SyncIt21 <110812394+SyncIt21@users.noreply.github.com>
Co-authored-by: deltanedas <39013340+deltanedas@users.noreply.github.com>
Co-authored-by: SimplyLogan <47579821+loganuk@users.noreply.github.com>
Co-authored-by: loganuk <fakeemail123@aol.com>
Co-authored-by: Leland Kemble <70413276+lelandkemble@users.noreply.github.com>
Co-authored-by: FalloutFalcon <86381784+FalloutFalcon@users.noreply.github.com>
Co-authored-by: Roxy <75404941+TealSeer@users.noreply.github.com>
Co-authored-by: Lucy <lucy@absolucy.moe>
Co-authored-by: siliconOpossum <138069572+siliconOpossum@users.noreply.github.com>
Co-authored-by: Isratosh <Isratosh@hotmail.com>
Co-authored-by: TheRyeGuyWhoWillNowDie <70169560+TheRyeGuyWhoWillNowDie@users.noreply.github.com>
Co-authored-by: Neocloudy <88008002+Neocloudy@users.noreply.github.com>
Co-authored-by: Alexander V. <volas@ya.ru>
Co-authored-by: ElGitificador <168473461+ElGitificador@users.noreply.github.com>
Co-authored-by: Twaticus <46540570+Twaticus@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
Co-authored-by: Cameron Lennox <killer65311@gmail.com>
Co-authored-by: Tim <timothymtorres@gmail.com>
Co-authored-by: Iamgoofball <iamgoofball@gmail.com>
Co-authored-by: Layzu666 <121319428+Layzu666@users.noreply.github.com>
Co-authored-by: Arturlang <24881678+Arturlang@users.noreply.github.com>
Co-authored-by: _0Steven <42909981+00-Steven@users.noreply.github.com>
Co-authored-by: mrmanlikesbt <99309552+mrmanlikesbt@users.noreply.github.com>
Co-authored-by: Ben10Omintrix <138636438+Ben10Omintrix@users.noreply.github.com>
Co-authored-by: John F. Kennedy <54908920+MacaroniCritter@users.noreply.github.com>
Co-authored-by: Cursor <102828457+theselfish@users.noreply.github.com>
Co-authored-by: Josh <josh.adam.powell@gmail.com>
Co-authored-by: Josh Powell <josh.powell@softwire.com>
Co-authored-by: Yobrocharlie <Charliemiller5617@gmail.com>
Co-authored-by: Hardly3D <66234359+Hardly3D@users.noreply.github.com>
Co-authored-by: shayoki <96078776+shayoki@users.noreply.github.com>
Co-authored-by: LT3 <83487515+lessthnthree@users.noreply.github.com>
2026-05-16 00:56:00 +02:00

128 lines
4.4 KiB
Plaintext

/obj/item/grenade/gas_crystal
desc = "Some kind of crystal, this shouldn't spawn"
name = "Gas Crystal"
icon = 'icons/obj/weapons/grenade.dmi'
icon_state = "bluefrag"
inhand_icon_state = "flashbang"
resistance_flags = FIRE_PROOF
/obj/item/grenade/gas_crystal/arm_grenade(mob/user, delayoverride, msg = TRUE, volume = 60)
log_grenade(user) //Inbuilt admin procs already handle null users
if(user)
add_fingerprint(user)
if(msg)
to_chat(user, span_warning("You crush the [src]! [capitalize(DisplayTimeText(det_time))]!"))
if(shrapnel_type && shrapnel_radius)
shrapnel_initialized = TRUE
AddComponent(/datum/component/pellet_cloud, projectile_type = shrapnel_type, magnitude = shrapnel_radius)
active = TRUE
icon_state = initial(icon_state) + "_active"
playsound(src, 'sound/effects/hit_on_shattered_glass.ogg', volume, TRUE)
SEND_SIGNAL(src, COMSIG_GRENADE_ARMED, det_time, delayoverride)
if(user)
SEND_SIGNAL(src, COMSIG_MOB_GRENADE_ARMED, user, src, det_time, delayoverride)
addtimer(CALLBACK(src, PROC_REF(detonate)), isnull(delayoverride)? det_time : delayoverride)
/obj/item/grenade/gas_crystal/healium_crystal
name = "Healium crystal"
desc = "A crystal made from the Healium gas, it's cold to the touch."
icon_state = "healium_crystal"
///Range of the grenade that will cool down and affect mobs
var/fix_range = 7
/obj/item/grenade/gas_crystal/healium_crystal/detonate(mob/living/lanced_by)
. = ..()
if(!.)
return
update_mob()
playsound(src, 'sound/effects/spray2.ogg', 100, TRUE)
var/list/turf_list = RANGE_TURFS(fix_range, src)
var/datum/gas_mixture/base_mix = SSair.parse_gas_string(OPENTURF_DEFAULT_ATMOS)
for(var/turf/open/turf_fix in turf_list)
if(turf_fix.blocks_air)
continue
turf_fix.copy_air(base_mix.copy())
turf_fix.air_update_turf(update = FALSE, remove = FALSE)
qdel(src)
/obj/item/grenade/gas_crystal/proto_nitrate_crystal
name = "Proto Nitrate crystal"
desc = "A crystal made from the Proto Nitrate gas, you can see the liquid gases inside."
icon_state = "proto_nitrate_crystal"
///Range of the grenade air refilling
var/refill_range = 5
///Amount of Nitrogen gas released (close to the grenade)
var/n2_gas_amount = 80
///Amount of Oxygen gas released (close to the grenade)
var/o2_gas_amount = 30
/obj/item/grenade/gas_crystal/proto_nitrate_crystal/detonate(mob/living/lanced_by)
. = ..()
if(!.)
return
update_mob()
playsound(src, 'sound/effects/spray2.ogg', 100, TRUE)
for(var/turf/turf_loc in view(refill_range, loc))
if(!isopenturf(turf_loc))
continue
var/distance_from_center = max(get_dist(turf_loc, loc), 1)
var/turf/open/floor_loc = turf_loc
floor_loc.atmos_spawn_air("[GAS_N2]=[n2_gas_amount / distance_from_center];[GAS_O2]=[o2_gas_amount / distance_from_center];[TURF_TEMPERATURE(273)]")
qdel(src)
/obj/item/grenade/gas_crystal/nitrous_oxide_crystal
name = "N2O crystal"
desc = "A crystal made from the N2O gas, you can see the liquid gases inside."
icon_state = "n2o_crystal"
///Range of the grenade air refilling
var/fill_range = 1
///Amount of n2o gas released (close to the grenade)
var/n2o_gas_amount = 10
/obj/item/grenade/gas_crystal/nitrous_oxide_crystal/detonate(mob/living/lanced_by)
. = ..()
if(!.)
return
update_mob()
playsound(src, 'sound/effects/spray2.ogg', 100, TRUE)
for(var/turf/turf_loc in view(fill_range, loc))
if(!isopenturf(turf_loc))
continue
var/distance_from_center = max(get_dist(turf_loc, loc), 1)
var/turf/open/floor_loc = turf_loc
floor_loc.atmos_spawn_air("[GAS_N2O]=[n2o_gas_amount / distance_from_center];[TURF_TEMPERATURE(273)]")
qdel(src)
/obj/item/grenade/gas_crystal/crystal_foam
name = "crystal foam"
desc = "A crystal with a foggy inside"
icon_state = "crystal_foam"
var/breach_range = 7
/obj/item/grenade/gas_crystal/crystal_foam/detonate(mob/living/lanced_by)
. = ..()
var/datum/reagents/first_batch = new
var/datum/reagents/second_batch = new
var/list/datum/reagents/reactants = list()
first_batch.add_reagent(/datum/reagent/aluminium, 75)
second_batch.add_reagent(/datum/reagent/smart_foaming_agent, 25)
second_batch.add_reagent(/datum/reagent/toxin/acid/fluacid, 25)
reactants += first_batch
reactants += second_batch
var/turf/detonation_turf = get_turf(src)
chem_splash(detonation_turf, null, breach_range, reactants)
playsound(src, 'sound/effects/spray2.ogg', 100, TRUE)
log_game("A grenade detonated at [AREACOORD(detonation_turf)]")
update_mob()
qdel(src)