mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-12 11:13:16 +00:00
[MIRROR] refactors most spans (#9139)
Co-authored-by: Heroman3003 <31296024+Heroman3003@users.noreply.github.com> Co-authored-by: Kashargul <KashL@t-online.de>
This commit is contained in:
@@ -119,7 +119,7 @@ var/list/overminds = list()
|
||||
if(message)
|
||||
client.handle_spam_prevention(MUTE_IC)
|
||||
if((client.prefs.muted & MUTE_IC) || say_disabled)
|
||||
to_chat(src, "<span class='warning'>You cannot speak in IC (Muted).</span>")
|
||||
to_chat(src, span_warning("You cannot speak in IC (Muted)."))
|
||||
return
|
||||
|
||||
//These will contain the main receivers of the message
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/mob/observer/blob/proc/can_buy(cost = 15)
|
||||
if(blob_points < cost)
|
||||
to_chat(src, "<span class='warning'>You cannot afford this, you need at least [cost] resources!</span>")
|
||||
to_chat(src, span_warning("You cannot afford this, you need at least [cost] resources!"))
|
||||
return FALSE
|
||||
add_points(-cost)
|
||||
return TRUE
|
||||
@@ -19,20 +19,20 @@
|
||||
var/obj/structure/blob/B = (locate(/obj/structure/blob) in T)
|
||||
|
||||
if(!B)
|
||||
to_chat(src, "<span class='warning'>There is no blob here!</span>")
|
||||
to_chat(src, span_warning("There is no blob here!"))
|
||||
return
|
||||
|
||||
if(B.overmind != src)
|
||||
to_chat(src, span_warning("This blob isn't controlled by you."))
|
||||
|
||||
if(!istype(B, /obj/structure/blob/normal))
|
||||
to_chat(src, "<span class='warning'>Unable to use this blob, find a normal one.</span>")
|
||||
to_chat(src, span_warning("Unable to use this blob, find a normal one."))
|
||||
return
|
||||
|
||||
if(nearEquals)
|
||||
for(var/obj/structure/blob/L in orange(nearEquals, T))
|
||||
if(L.type == blobType)
|
||||
to_chat(src, "<span class='warning'>There is a similar blob nearby, move more than [nearEquals] tiles away from it!</span>")
|
||||
to_chat(src, span_warning("There is a similar blob nearby, move more than [nearEquals] tiles away from it!"))
|
||||
return
|
||||
|
||||
if(!can_buy(price))
|
||||
@@ -197,7 +197,7 @@
|
||||
break
|
||||
|
||||
if(!B)
|
||||
to_chat(src, "<span class='warning'>There is no blob cardinally adjacent to the target tile!</span>")
|
||||
to_chat(src, span_warning("There is no blob cardinally adjacent to the target tile!"))
|
||||
return
|
||||
|
||||
if(!can_buy(4))
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
/datum/blob_type/classic/on_chunk_use(obj/item/blobcore_chunk/B, mob/living/user)
|
||||
var/turf/T = get_turf(B)
|
||||
|
||||
to_chat(user, "<span class='alien'>\The [B] produces a soothing ooze!</span>")
|
||||
to_chat(user, span_alien("\The [B] produces a soothing ooze!"))
|
||||
|
||||
T.visible_message("<span class='alium'>\The [B] shudders at \the [user]'s touch, before disgorging a disgusting ooze.</span>")
|
||||
T.visible_message(span_alium("\The [B] shudders at \the [user]'s touch, before disgorging a disgusting ooze."))
|
||||
|
||||
for(var/turf/simulated/floor/F in view(2, T))
|
||||
spawn()
|
||||
@@ -34,4 +34,4 @@
|
||||
blood.reagents.add_reagent("tricorlidaze", 5)
|
||||
blood.update_icon()
|
||||
|
||||
return
|
||||
return
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
/datum/blob_type/ectoplasmic_horror/on_pulse(var/obj/structure/blob/B)
|
||||
if(B.type == /obj/structure/blob && (locate(/obj/structure/blob/node) in oview(2, get_turf(B))))
|
||||
B.visible_message("<span class='alien'>The [name] quakes, before hardening.</span>")
|
||||
B.visible_message(span_alien("The [name] quakes, before hardening."))
|
||||
new/obj/structure/blob/shield(get_turf(B), B.overmind)
|
||||
qdel(B)
|
||||
|
||||
@@ -47,12 +47,12 @@
|
||||
break
|
||||
|
||||
if(!beamtarget_exists && GetAnomalySusceptibility(L) >= 0.5)
|
||||
B.visible_message("<span class='danger'>\The [B] lashes out at \the [L]!</span>")
|
||||
B.visible_message(span_danger("\The [B] lashes out at \the [L]!"))
|
||||
var/datum/beam/drain_beam = beam_origin.Beam(L, icon_state = "drain_life", time = 10 SECONDS)
|
||||
active_beams |= drain_beam
|
||||
spawn(9 SECONDS)
|
||||
if(B && drain_beam)
|
||||
B.visible_message("<span class='alien'>\The [B] siphons energy from \the [L]</span>")
|
||||
B.visible_message(span_alien("\The [B] siphons energy from \the [L]"))
|
||||
L.add_modifier(/datum/modifier/berserk_exhaustion, 60 SECONDS)
|
||||
B.overmind.add_points(rand(10,30))
|
||||
if(!QDELETED(drain_beam))
|
||||
@@ -60,7 +60,7 @@
|
||||
|
||||
/datum/blob_type/ectoplasmic_horror/on_received_damage(var/obj/structure/blob/B, damage, damage_type)
|
||||
if(prob(round(damage * 0.5)))
|
||||
B.visible_message("<span class='alien'>\The [B] shimmers, distorting through some unseen dimension.</span>")
|
||||
B.visible_message(span_alien("\The [B] shimmers, distorting through some unseen dimension."))
|
||||
var/initial_alpha = B.alpha
|
||||
spawn()
|
||||
animate(B,alpha = initial_alpha, alpha = 10, time = 10)
|
||||
@@ -94,12 +94,12 @@
|
||||
break
|
||||
|
||||
if(!beamtarget_exists && GetAnomalySusceptibility(L) >= 0.5)
|
||||
carrier.visible_message("<span class='danger'>[icon2html(B,viewers(carrier))] \The [B] lashes out at \the [L]!</span>")
|
||||
carrier.visible_message(span_danger("[icon2html(B,viewers(carrier))] \The [B] lashes out at \the [L]!"))
|
||||
var/datum/beam/drain_beam = carrier.Beam(L, icon_state = "drain_life", time = 10 SECONDS)
|
||||
active_beams |= drain_beam
|
||||
spawn(9 SECONDS)
|
||||
if(B && drain_beam)
|
||||
carrier.visible_message("<span class='alien'>\The [B] siphons energy from \the [L]</span>")
|
||||
carrier.visible_message(span_alien("\The [B] siphons energy from \the [L]"))
|
||||
L.add_modifier(/datum/modifier/berserk_exhaustion, 30 SECONDS)
|
||||
var/total_heal = 0
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
|
||||
var/obj/item/projectile/P = new spore_projectile(get_turf(B))
|
||||
|
||||
carrier.visible_message("<span class='danger'>\The [B] discharges energy toward \the [L]!</span>")
|
||||
carrier.visible_message(span_danger("\The [B] discharges energy toward \the [L]!"))
|
||||
P.launch_projectile(L, BP_TORSO, carrier)
|
||||
|
||||
return
|
||||
return
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
if(damage > 0)
|
||||
var/reinforce_probability = min(damage, 70)
|
||||
if(prob(reinforce_probability))
|
||||
B.visible_message("<span class='danger'>The [name] quakes, before rapidly hardening!</span>")
|
||||
B.visible_message(span_danger("The [name] quakes, before rapidly hardening!"))
|
||||
new/obj/structure/blob/shield(get_turf(B), B.overmind)
|
||||
qdel(B)
|
||||
return ..()
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
/datum/blob_type/fulminant_organism/on_death(obj/structure/blob/B)
|
||||
if(prob(33)) // 33% chance to make a spore when dying.
|
||||
var/mob/living/simple_mob/blob/spore/S = new spore_type(get_turf(B))
|
||||
B.visible_message("<span class='danger'>\The [S] floats free from the [name]!</span>")
|
||||
B.visible_message(span_danger("\The [S] floats free from the [name]!"))
|
||||
if(istype(S))
|
||||
S.overmind = B.overmind
|
||||
S.faction = faction
|
||||
|
||||
@@ -27,11 +27,11 @@
|
||||
B.adjust_integrity(10)
|
||||
else
|
||||
B = new /obj/structure/blob/normal(T, S.overmind) // Otherwise spread it.
|
||||
B.visible_message("<span class='danger'>\A [B] forms on \the [T] as \the [S] bursts!</span>")
|
||||
B.visible_message(span_danger("\A [B] forms on \the [T] as \the [S] bursts!"))
|
||||
|
||||
/datum/blob_type/fungal_bloom/on_chunk_use(obj/item/blobcore_chunk/B, mob/living/user)
|
||||
var/mob/living/simple_mob/blob/spore/S = new spore_type(get_turf(B))
|
||||
S.faction = user.faction
|
||||
S.blob_type = src
|
||||
S.update_icons()
|
||||
S.ai_holder.forget_everything()
|
||||
S.ai_holder.forget_everything()
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
T.wet_floor()
|
||||
|
||||
/datum/blob_type/pressurized_slime/on_death(obj/structure/blob/B)
|
||||
B.visible_message("<span class='danger'>The blob ruptures, spraying the area with liquid!</span>")
|
||||
B.visible_message(span_danger("The blob ruptures, spraying the area with liquid!"))
|
||||
wet_surroundings(B, 50)
|
||||
|
||||
/datum/blob_type/pressurized_slime/proc/wet_surroundings(var/obj/structure/blob/B, var/probability = 50)
|
||||
@@ -53,4 +53,4 @@
|
||||
/datum/blob_type/pressurized_slime/on_chunk_use(obj/item/blobcore_chunk/B, mob/living/user) // Drenches you in water.
|
||||
if(user)
|
||||
user.ExtinguishMob()
|
||||
user.fire_stacks = CLAMP(user.fire_stacks - 1, -25, 25)
|
||||
user.fire_stacks = CLAMP(user.fire_stacks - 1, -25, 25)
|
||||
|
||||
@@ -34,14 +34,14 @@
|
||||
/datum/blob_type/ravenous_macrophage/on_death(obj/structure/blob/B)
|
||||
var/obj/structure/blob/other = locate() in oview(2, B)
|
||||
if(other)
|
||||
B.visible_message("<span class='danger'>The dying mass is rapidly consumed by the nearby [other]!</span>")
|
||||
B.visible_message(span_danger("The dying mass is rapidly consumed by the nearby [other]!"))
|
||||
if(other.overmind)
|
||||
other.overmind.add_points(rand(1,4))
|
||||
|
||||
/datum/blob_type/ravenous_macrophage/on_chunk_tick(obj/item/blobcore_chunk/B)
|
||||
var/mob/living/L = locate() in range(world.view, B)
|
||||
if(prob(5) && !L.stat) // There's some active living thing nearby, produce offgas.
|
||||
B.visible_message("<span class='alien'>[icon2html(B,viewers(B))] \The [B] disgorches a cloud of noxious gas!</span>")
|
||||
B.visible_message(span_alien("[icon2html(B,viewers(B))] \The [B] disgorches a cloud of noxious gas!"))
|
||||
var/turf/T = get_turf(B)
|
||||
var/datum/effect/effect/system/smoke_spread/noxious/BS = new /datum/effect/effect/system/smoke_spread/noxious
|
||||
BS.attach(T)
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
// Even if the melee attack is enough to one-shot this blob, it gets to retaliate at least once.
|
||||
/datum/blob_type/reactive_spines/on_received_damage(var/obj/structure/blob/B, damage, damage_type, mob/living/attacker)
|
||||
if(damage > 0 && attacker && get_dist(B, attacker) <= 1)
|
||||
B.visible_message("<span class='danger'>The [name] retaliates, lashing out at \the [attacker]!</span>")
|
||||
B.visible_message(span_danger("The [name] retaliates, lashing out at \the [attacker]!"))
|
||||
B.blob_attack_animation(attacker, B.overmind)
|
||||
attacker.blob_act(B)
|
||||
return ..()
|
||||
@@ -49,7 +49,7 @@
|
||||
|
||||
var/obj/item/projectile/P = new spore_projectile(get_turf(B))
|
||||
|
||||
carrier.visible_message("<span class='danger'>\The [B] fires a spine at \the [L]!</span>")
|
||||
carrier.visible_message(span_danger("\The [B] fires a spine at \the [L]!"))
|
||||
P.launch_projectile(L, BP_TORSO, carrier)
|
||||
|
||||
return
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
|
||||
var/obj/item/projectile/P = new spore_projectile(get_turf(B))
|
||||
|
||||
user.visible_message("<span class='danger'>[icon2html(B,viewers(user))] \The [B] discharges energy toward \the [L]!</span>")
|
||||
user.visible_message(span_danger("[icon2html(B,viewers(user))] \The [B] discharges energy toward \the [L]!"))
|
||||
P.launch_projectile(L, BP_TORSO, user)
|
||||
|
||||
return
|
||||
|
||||
@@ -68,5 +68,5 @@
|
||||
carrier.adjustFireLoss(-3 / nearby_mobs.len)
|
||||
|
||||
if(need_beam)
|
||||
carrier.visible_message("<span class='alien'>[icon2html(B,viewers(carrier))] \The [B] sends noxious spores toward \the [victim]!</span>")
|
||||
carrier.visible_message(span_alien("[icon2html(B,viewers(carrier))] \The [B] sends noxious spores toward \the [victim]!"))
|
||||
carrier.Beam(victim, icon_state = "lichbeam", time = 2 SECONDS)
|
||||
|
||||
@@ -36,10 +36,10 @@
|
||||
if(I)
|
||||
if((I.sharp || I.edge) && !istype(I, /obj/item/gun))
|
||||
I.forceMove(get_turf(B)) // Disarmed entirely.
|
||||
B.visible_message("<span class='danger'>The [name] heaves, \the [attacker]'s weapon becoming stuck in the churning mass!</span>")
|
||||
B.visible_message(span_danger("The [name] heaves, \the [attacker]'s weapon becoming stuck in the churning mass!"))
|
||||
else
|
||||
I.throw_at(B, 2, 4) // Just yoinked.
|
||||
B.visible_message("<span class='danger'>The [name] heaves, pulling \the [attacker]'s weapon from their hands!</span>")
|
||||
B.visible_message(span_danger("The [name] heaves, pulling \the [attacker]'s weapon from their hands!"))
|
||||
B.blob_attack_animation(attacker, B.overmind)
|
||||
return ..()
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
var/damage = amount * 4
|
||||
B.adjust_integrity(-(damage))
|
||||
if(B && prob(damage))
|
||||
B.visible_message("<span class='danger'>The [name] begins to crumble!</span>")
|
||||
B.visible_message(span_danger("The [name] begins to crumble!"))
|
||||
|
||||
/datum/blob_type/volatile_alluvium/on_chunk_use(obj/item/blobcore_chunk/B, mob/living/user)
|
||||
if(user)
|
||||
|
||||
Reference in New Issue
Block a user