Ports the radiation subsystem and cleans up damage flags. (#15715)

This commit is contained in:
Matt Atlas
2023-02-07 13:22:47 +01:00
committed by GitHub
parent 5527fc0810
commit 31c73ead85
198 changed files with 981 additions and 649 deletions

View File

@@ -85,7 +85,7 @@
C.adjustBruteLoss(rand(5,25) * weakness)
C.adjustFireLoss(rand(5,25) * weakness)
C.adjustBrainLoss(rand(5,25) * weakness)
C.apply_damage(25 * weakness, IRRADIATE, damage_flags = DAM_DISPERSED)
C.apply_damage(25 * weakness, DAMAGE_RADIATION, damage_flags = DAMAGE_FLAG_DISPERSED)
C.adjustNutritionLoss(50 * weakness)
C.adjustHydrationLoss(50 * weakness)
C.make_dizzy(6 * weakness)
@@ -314,27 +314,21 @@
/datum/artifact_effect/radiate/New()
..()
radiation_amount = rand(1, 10)
radiation_amount = rand(10, 50)
effect_type = pick(4,5)
/datum/artifact_effect/radiate/DoEffectTouch(var/mob/living/user)
if(user)
user.apply_effect(radiation_amount * 5,IRRADIATE,0)
user.apply_damage(radiation_amount * 5, DAMAGE_RADIATION, damage_flags = DAMAGE_FLAG_DISPERSED)
user.updatehealth()
return TRUE
/datum/artifact_effect/radiate/DoEffectAura()
if(holder)
var/turf/T = get_turf(holder)
for (var/mob/living/M in range(src.effectrange,T))
M.apply_effect(radiation_amount,IRRADIATE,0)
M.updatehealth()
SSradiation.radiate(holder, radiation_amount)
return TRUE
/datum/artifact_effect/radiate/DoEffectPulse()
if(holder)
var/turf/T = get_turf(holder)
for (var/mob/living/M in range(src.effectrange,T))
M.apply_damage(radiation_amount * 25, IRRADIATE, damage_flags = DAM_DISPERSED)
M.updatehealth()
SSradiation.radiate(holder, radiation_amount)
return TRUE

View File

@@ -142,7 +142,7 @@
nearby_mobs.Add(M)
var/target = pick(M.organs_by_name)
M.apply_damage(rand(5, 10), BRUTE, target)
M.apply_damage(rand(5, 10), DAMAGE_BRUTE, target)
to_chat(M, "<span class='warning'>The skin on your [parse_zone(target)] feels like it's ripping apart, and a stream of blood flies out.</span>")
var/obj/effect/decal/cleanable/blood/splatter/animated/B = new(M.loc)
B.target_turf = pick(seen_turfs_in_range(src, 1))

View File

@@ -199,7 +199,7 @@
if(!rad_shield)
//irradiate nearby mobs
for(var/mob/living/M in view(7,src))
M.apply_damage(radiation / 25, IRRADIATE, damage_flags = DAM_DISPERSED)
M.apply_damage(radiation / 25, DAMAGE_RADIATION, damage_flags = DAMAGE_FLAG_DISPERSED)
else
t_left_radspike = pick(10,15,25)