mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-25 06:00:16 +01:00
[MIRROR] Refactors most spans into span procs (#6315)
* Refactors most spans into span procs * AA * a * AAAAAAAAAAAAAAAAAAAAAA * Update species.dm Co-authored-by: Watermelon914 <37270891+Watermelon914@users.noreply.github.com> Co-authored-by: Gandalf <jzo123@hotmail.com>
This commit is contained in:
co-authored by
Watermelon914
Gandalf
parent
cd5dba4fbd
commit
7d1d0e1fad
@@ -35,7 +35,7 @@
|
||||
/obj/item/assembly/Destroy()
|
||||
holder = null
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/item/assembly/get_part_rating()
|
||||
return 1
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
|
||||
/obj/item/assembly/proc/is_secured(mob/user)
|
||||
if(!secured)
|
||||
to_chat(user, "<span class='warning'>The [name] is unsecured!</span>")
|
||||
to_chat(user, span_warning("The [name] is unsecured!"))
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
@@ -100,9 +100,9 @@
|
||||
if((!A.secured) && (!secured))
|
||||
holder = new/obj/item/assembly_holder(get_turf(src))
|
||||
holder.assemble(src,A,user)
|
||||
to_chat(user, "<span class='notice'>You attach and secure \the [A] to \the [src]!</span>")
|
||||
to_chat(user, span_notice("You attach and secure \the [A] to \the [src]!"))
|
||||
else
|
||||
to_chat(user, "<span class='warning'>Both devices must be in attachable mode to be attached together.</span>")
|
||||
to_chat(user, span_warning("Both devices must be in attachable mode to be attached together."))
|
||||
return
|
||||
..()
|
||||
|
||||
@@ -110,15 +110,15 @@
|
||||
if(..())
|
||||
return TRUE
|
||||
if(toggle_secure())
|
||||
to_chat(user, "<span class='notice'>\The [src] is ready!</span>")
|
||||
to_chat(user, span_notice("\The [src] is ready!"))
|
||||
else
|
||||
to_chat(user, "<span class='notice'>\The [src] can now be attached!</span>")
|
||||
to_chat(user, span_notice("\The [src] can now be attached!"))
|
||||
add_fingerprint(user)
|
||||
return TRUE
|
||||
|
||||
/obj/item/assembly/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>\The [src] [secured? "is secured and ready to be used!" : "can be attached to other things."]</span>"
|
||||
. += span_notice("\The [src] [secured? "is secured and ready to be used!" : "can be attached to other things."]")
|
||||
|
||||
/obj/item/assembly/attack_self(mob/user)
|
||||
if(!user)
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
/obj/item/onetankbomb/wrench_act(mob/living/user, obj/item/I)
|
||||
..()
|
||||
to_chat(user, "<span class='notice'>You disassemble [src]!</span>")
|
||||
to_chat(user, span_notice("You disassemble [src]!"))
|
||||
if(bombassembly)
|
||||
bombassembly.forceMove(drop_location())
|
||||
bombassembly.master = null
|
||||
@@ -52,7 +52,7 @@
|
||||
..()
|
||||
. = FALSE
|
||||
if(status)
|
||||
to_chat(user, "<span class='warning'>[bombtank] already has a pressure hole!</span>")
|
||||
to_chat(user, span_warning("[bombtank] already has a pressure hole!"))
|
||||
return
|
||||
if(!I.tool_start_check(user, amount=0))
|
||||
return
|
||||
@@ -60,7 +60,7 @@
|
||||
status = TRUE
|
||||
var/datum/gas_mixture/bomb_mix = bombtank.return_air()
|
||||
log_bomber(user, "welded a single tank bomb,", src, "| Temp: [bomb_mix.temperature-T0C]")
|
||||
to_chat(user, "<span class='notice'>A pressure hole has been bored to [bombtank] valve. \The [bombtank] can now be ignited.</span>")
|
||||
to_chat(user, span_notice("A pressure hole has been bored to [bombtank] valve. \The [bombtank] can now be ignited."))
|
||||
add_fingerprint(user)
|
||||
return TRUE
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
return
|
||||
|
||||
/obj/item/onetankbomb/receive_signal() //This is mainly called by the sensor through sense() to the holder, and from the holder to here.
|
||||
audible_message("<span class='warning'>[icon2html(src, hearers(src))] *beep* *beep* *beep*</span>")
|
||||
audible_message(span_warning("[icon2html(src, hearers(src))] *beep* *beep* *beep*"))
|
||||
playsound(src, 'sound/machines/triple_beep.ogg', ASSEMBLY_BEEP_VOLUME, TRUE)
|
||||
sleep(10)
|
||||
if(QDELETED(src))
|
||||
@@ -114,11 +114,11 @@
|
||||
return
|
||||
|
||||
if((src in user.get_equipped_items(TRUE)) && !user.canUnEquip(src))
|
||||
to_chat(user, "<span class='warning'>[src] is stuck to you!</span>")
|
||||
to_chat(user, span_warning("[src] is stuck to you!"))
|
||||
return
|
||||
|
||||
if(!user.canUnEquip(assembly))
|
||||
to_chat(user, "<span class='warning'>[assembly] is stuck to your hand!</span>")
|
||||
to_chat(user, span_warning("[assembly] is stuck to your hand!"))
|
||||
return
|
||||
|
||||
var/obj/item/onetankbomb/bomb = new
|
||||
@@ -135,7 +135,7 @@
|
||||
bomb.update_appearance()
|
||||
|
||||
user.put_in_hands(bomb) //Equips the bomb if possible, or puts it on the floor.
|
||||
to_chat(user, "<span class='notice'>You attach [assembly] to [src].</span>")
|
||||
to_chat(user, span_notice("You attach [assembly] to [src]."))
|
||||
return
|
||||
|
||||
/obj/item/tank/proc/ignite() //This happens when a bomb is told to explode
|
||||
|
||||
@@ -11,13 +11,13 @@
|
||||
/obj/item/assembly/control/examine(mob/user)
|
||||
. = ..()
|
||||
if(id)
|
||||
. += "<span class='notice'>Its channel ID is '[id]'.</span>"
|
||||
. += span_notice("Its channel ID is '[id]'.")
|
||||
|
||||
/obj/item/assembly/control/multitool_act(mob/living/user)
|
||||
var/change_id = input("Set the shutters/blast door/blast door controllers ID. It must be a number between 1 and 100.", "ID", id) as num|null
|
||||
if(change_id)
|
||||
id = clamp(round(change_id, 1), 1, 100)
|
||||
to_chat(user, "<span class='notice'>You change the ID to [id].</span>")
|
||||
to_chat(user, span_notice("You change the ID to [id]."))
|
||||
|
||||
/obj/item/assembly/control/activate()
|
||||
var/openclose
|
||||
@@ -38,7 +38,7 @@
|
||||
/obj/item/assembly/control/curtain/examine(mob/user)
|
||||
. = ..()
|
||||
if(id)
|
||||
. += "<span class='notice'>Its channel ID is '[id]'.</span>"
|
||||
. += span_notice("Its channel ID is '[id]'.")
|
||||
|
||||
/obj/item/assembly/control/curtain/activate()
|
||||
var/openclose
|
||||
|
||||
@@ -39,12 +39,12 @@
|
||||
|
||||
/obj/item/assembly/flash/suicide_act(mob/living/user)
|
||||
if(burnt_out)
|
||||
user.visible_message("<span class='suicide'>[user] raises \the [src] up to [user.p_their()] eyes and activates it ... but it's burnt out!</span>")
|
||||
user.visible_message(span_suicide("[user] raises \the [src] up to [user.p_their()] eyes and activates it ... but it's burnt out!"))
|
||||
return SHAME
|
||||
else if(user.is_blind())
|
||||
user.visible_message("<span class='suicide'>[user] raises \the [src] up to [user.p_their()] eyes and activates it ... but [user.p_theyre()] blind!</span>")
|
||||
user.visible_message(span_suicide("[user] raises \the [src] up to [user.p_their()] eyes and activates it ... but [user.p_theyre()] blind!"))
|
||||
return SHAME
|
||||
user.visible_message("<span class='suicide'>[user] raises \the [src] up to [user.p_their()] eyes and activates it! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
||||
user.visible_message(span_suicide("[user] raises \the [src] up to [user.p_their()] eyes and activates it! It looks like [user.p_theyre()] trying to commit suicide!"))
|
||||
attack(user,user)
|
||||
return FIRELOSS
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
/obj/item/assembly/flash/proc/burn_out() //Made so you can override it if you want to have an invincible flash from R&D or something.
|
||||
if(!burnt_out)
|
||||
burnt_out = TRUE
|
||||
loc?.visible_message("<span class='danger'>[src] burns out!</span>","<span class='userdanger'>[src] burns out!</span>")
|
||||
loc?.visible_message(span_danger("[src] burns out!"),span_userdanger("[src] burns out!"))
|
||||
update_appearance()
|
||||
|
||||
/obj/item/assembly/flash/proc/flash_recharge(interval = 10)
|
||||
@@ -155,7 +155,7 @@
|
||||
M.log_message("was [targeted? "flashed(targeted)" : "flashed(AOE)"]",LOG_ATTACK)
|
||||
|
||||
if(generic_message && M != user)
|
||||
to_chat(M, "<span class='danger'>[src] emits a blinding light!</span>")
|
||||
to_chat(M, span_danger("[src] emits a blinding light!"))
|
||||
|
||||
var/deviation = calculate_deviation(M, user ? user : src)
|
||||
|
||||
@@ -175,19 +175,19 @@
|
||||
// Did we try to flash them from behind?
|
||||
if(deviation == DEVIATION_FULL)
|
||||
// Headrevs can use a tacticool leaning technique so that they don't have to worry about facing for their conversions.
|
||||
to_chat(user, "<span class='notice'>You use the tacticool tier, lean over the shoulder technique to blind [M] with a flash!</span>")
|
||||
to_chat(user, span_notice("You use the tacticool tier, lean over the shoulder technique to blind [M] with a flash!"))
|
||||
deviation = DEVIATION_PARTIAL
|
||||
// Convert them. Terribly.
|
||||
terrible_conversion_proc(M, user)
|
||||
visible_message("<span class='danger'>[user] blinds [M] with the flash!</span>","<span class='userdanger'>[user] blinds you with the flash!</span>")
|
||||
visible_message(span_danger("[user] blinds [M] with the flash!"),span_userdanger("[user] blinds you with the flash!"))
|
||||
//easy way to make sure that you can only long stun someone who is facing in your direction
|
||||
//M.adjustStaminaLoss(rand(80,120)*(1-(deviation*0.5)))
|
||||
//M.Paralyze(rand(25,50)*(1-(deviation*0.5)))
|
||||
M.StaminaKnockdown(rand(30,40) * (1-(deviation*0.5))) //SKYRAT EDIT CHANGE - ORIGINAL ABOVE
|
||||
else if(user)
|
||||
visible_message("<span class='warning'>[user] fails to blind [M] with the flash!</span>","<span class='danger'>[user] fails to blind you with the flash!</span>")
|
||||
visible_message(span_warning("[user] fails to blind [M] with the flash!"),span_danger("[user] fails to blind you with the flash!"))
|
||||
else
|
||||
to_chat(M, "<span class='danger'>[src] fails to blind you!</span>")
|
||||
to_chat(M, span_danger("[src] fails to blind you!"))
|
||||
else
|
||||
if(M.flash_act())
|
||||
var/diff = power * CONFUSION_STACK_MAX_MULTIPLIER - M.get_confusion()
|
||||
@@ -254,22 +254,22 @@
|
||||
log_combat(user, flashed_borgo, "flashed", src)
|
||||
update_icon(ALL, TRUE)
|
||||
if(!flashed_borgo.flash_act(affect_silicon = TRUE))
|
||||
user.visible_message("<span class='warning'>[user] fails to blind [flashed_borgo] with the flash!</span>", "<span class='warning'>You fail to blind [flashed_borgo] with the flash!</span>")
|
||||
user.visible_message(span_warning("[user] fails to blind [flashed_borgo] with the flash!"), span_warning("You fail to blind [flashed_borgo] with the flash!"))
|
||||
return
|
||||
flashed_borgo.Paralyze(rand(80,120))
|
||||
var/diff = 5 * CONFUSION_STACK_MAX_MULTIPLIER - M.get_confusion()
|
||||
flashed_borgo.add_confusion(min(5, diff))
|
||||
user.visible_message("<span class='warning'>[user] overloads [flashed_borgo]'s sensors with the flash!</span>", "<span class='danger'>You overload [flashed_borgo]'s sensors with the flash!</span>")
|
||||
user.visible_message(span_warning("[user] overloads [flashed_borgo]'s sensors with the flash!"), span_danger("You overload [flashed_borgo]'s sensors with the flash!"))
|
||||
return
|
||||
|
||||
user.visible_message("<span class='warning'>[user] fails to blind [M] with the flash!</span>", "<span class='warning'>You fail to blind [M] with the flash!</span>")
|
||||
user.visible_message(span_warning("[user] fails to blind [M] with the flash!"), span_warning("You fail to blind [M] with the flash!"))
|
||||
|
||||
/obj/item/assembly/flash/attack_self(mob/living/carbon/user, flag = 0, emp = 0)
|
||||
if(holder)
|
||||
return FALSE
|
||||
if(!AOE_flash(FALSE, 3, 5, FALSE, user))
|
||||
return FALSE
|
||||
to_chat(user, "<span class='danger'>[src] emits a blinding light!</span>")
|
||||
to_chat(user, span_danger("[src] emits a blinding light!"))
|
||||
|
||||
/obj/item/assembly/flash/emp_act(severity)
|
||||
. = ..()
|
||||
@@ -298,10 +298,10 @@
|
||||
if(!aggressor.mind)
|
||||
return
|
||||
if(!victim.client)
|
||||
to_chat(aggressor, "<span class='warning'>This mind is so vacant that it is not susceptible to influence!</span>")
|
||||
to_chat(aggressor, span_warning("This mind is so vacant that it is not susceptible to influence!"))
|
||||
return
|
||||
if(victim.stat != CONSCIOUS)
|
||||
to_chat(aggressor, "<span class='warning'>They must be conscious before you can convert [victim.p_them()]!</span>")
|
||||
to_chat(aggressor, span_warning("They must be conscious before you can convert [victim.p_them()]!"))
|
||||
return
|
||||
//If this proc fires the mob must be a revhead
|
||||
var/datum/antagonist/rev/head/converter = aggressor.mind.has_antag_datum(/datum/antagonist/rev/head)
|
||||
@@ -310,7 +310,7 @@
|
||||
victim.say("You son of a bitch! I'm in.", forced = "That son of a bitch! They're in.")
|
||||
times_used -- //Flashes less likely to burn out for headrevs when used for conversion
|
||||
else
|
||||
to_chat(aggressor, "<span class='warning'>This mind seems resistant to the flash!</span>")
|
||||
to_chat(aggressor, span_warning("This mind seems resistant to the flash!"))
|
||||
|
||||
|
||||
/obj/item/assembly/flash/cyborg
|
||||
@@ -348,7 +348,7 @@
|
||||
/obj/item/assembly/flash/armimplant/burn_out()
|
||||
var/obj/item/organ/cyberimp/arm/flash/real_arm = arm.resolve()
|
||||
if(real_arm?.owner)
|
||||
to_chat(real_arm.owner, "<span class='warning'>Your photon projector implant overheats and deactivates!</span>")
|
||||
to_chat(real_arm.owner, span_warning("Your photon projector implant overheats and deactivates!"))
|
||||
real_arm.Retract()
|
||||
overheat = TRUE
|
||||
addtimer(CALLBACK(src, .proc/cooldown), flashcd * 2)
|
||||
@@ -357,7 +357,7 @@
|
||||
if(overheat)
|
||||
var/obj/item/organ/cyberimp/arm/flash/real_arm = arm.resolve()
|
||||
if(real_arm?.owner)
|
||||
to_chat(real_arm.owner, "<span class='warning'>Your photon projector is running too hot to be used again so quickly!</span>")
|
||||
to_chat(real_arm.owner, span_warning("Your photon projector is running too hot to be used again so quickly!"))
|
||||
return FALSE
|
||||
overheat = TRUE
|
||||
addtimer(CALLBACK(src, .proc/cooldown), flashcd)
|
||||
@@ -387,17 +387,17 @@
|
||||
else //caused by emp/remote signal
|
||||
M.log_message("was [targeted? "hypno-flashed(targeted)" : "hypno-flashed(AOE)"]",LOG_ATTACK)
|
||||
if(generic_message && M != user)
|
||||
to_chat(M, "<span class='notice'>[src] emits a soothing light...</span>")
|
||||
to_chat(M, span_notice("[src] emits a soothing light..."))
|
||||
if(targeted)
|
||||
if(M.flash_act(1, 1))
|
||||
var/hypnosis = FALSE
|
||||
if(M.hypnosis_vulnerable())
|
||||
hypnosis = TRUE
|
||||
if(user)
|
||||
user.visible_message("<span class='danger'>[user] blinds [M] with the flash!</span>", "<span class='danger'>You hypno-flash [M]!</span>")
|
||||
user.visible_message(span_danger("[user] blinds [M] with the flash!"), span_danger("You hypno-flash [M]!"))
|
||||
|
||||
if(!hypnosis)
|
||||
to_chat(M, "<span class='hypnophrase'>The light makes you feel oddly relaxed...</span>")
|
||||
to_chat(M, span_hypnophrase("The light makes you feel oddly relaxed..."))
|
||||
M.add_confusion(min(M.get_confusion() + 10, 20))
|
||||
M.dizziness += min(M.dizziness + 10, 20)
|
||||
M.drowsyness += min(M.drowsyness + 10, 20)
|
||||
@@ -406,12 +406,12 @@
|
||||
M.apply_status_effect(/datum/status_effect/trance, 200, TRUE)
|
||||
|
||||
else if(user)
|
||||
user.visible_message("<span class='warning'>[user] fails to blind [M] with the flash!</span>", "<span class='warning'>You fail to hypno-flash [M]!</span>")
|
||||
user.visible_message(span_warning("[user] fails to blind [M] with the flash!"), span_warning("You fail to hypno-flash [M]!"))
|
||||
else
|
||||
to_chat(M, "<span class='danger'>[src] fails to blind you!</span>")
|
||||
to_chat(M, span_danger("[src] fails to blind you!"))
|
||||
|
||||
else if(M.flash_act())
|
||||
to_chat(M, "<span class='notice'>Such a pretty light...</span>")
|
||||
to_chat(M, span_notice("Such a pretty light..."))
|
||||
M.add_confusion(min(M.get_confusion() + 4, 20))
|
||||
M.dizziness += min(M.dizziness + 4, 20)
|
||||
M.drowsyness += min(M.drowsyness + 4, 20)
|
||||
|
||||
@@ -33,10 +33,10 @@
|
||||
/obj/item/assembly/health/AltClick(mob/living/user)
|
||||
if(alarm_health == HEALTH_THRESHOLD_CRIT)
|
||||
alarm_health = HEALTH_THRESHOLD_DEAD
|
||||
to_chat(user, "<span class='notice'>You toggle [src] to \"detect death\" mode.</span>")
|
||||
to_chat(user, span_notice("You toggle [src] to \"detect death\" mode."))
|
||||
else
|
||||
alarm_health = HEALTH_THRESHOLD_CRIT
|
||||
to_chat(user, "<span class='notice'>You toggle [src] to \"detect critical state\" mode.</span>")
|
||||
to_chat(user, span_notice("You toggle [src] to \"detect critical state\" mode."))
|
||||
|
||||
/obj/item/assembly/health/process()
|
||||
if(!scanning || !secured)
|
||||
@@ -71,5 +71,5 @@
|
||||
|
||||
/obj/item/assembly/health/attack_self(mob/user)
|
||||
. = ..()
|
||||
to_chat(user, "<span class='notice'>You toggle [src] [src.scanning ? "off" : "on"].</span>")
|
||||
to_chat(user, span_notice("You toggle [src] [src.scanning ? "off" : "on"]."))
|
||||
toggle_scan()
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
/obj/item/assembly_holder/screwdriver_act(mob/user, obj/item/tool)
|
||||
if(..())
|
||||
return TRUE
|
||||
to_chat(user, "<span class='notice'>You disassemble [src]!</span>")
|
||||
to_chat(user, span_notice("You disassemble [src]!"))
|
||||
if(a_left)
|
||||
a_left.on_detach()
|
||||
a_left = null
|
||||
@@ -116,7 +116,7 @@
|
||||
/obj/item/assembly_holder/attack_self(mob/user)
|
||||
src.add_fingerprint(user)
|
||||
if(!a_left || !a_right)
|
||||
to_chat(user, "<span class='danger'>Assembly part missing!</span>")
|
||||
to_chat(user, span_danger("Assembly part missing!"))
|
||||
return
|
||||
if(istype(a_left,a_right.type))//If they are the same type it causes issues due to window code
|
||||
switch(tgui_alert(usr,"Which side would you like to use?",,list("Left","Right")))
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
pickup_sound = 'sound/items/handling/component_pickup.ogg'
|
||||
|
||||
/obj/item/assembly/igniter/suicide_act(mob/living/carbon/user)
|
||||
user.visible_message("<span class='suicide'>[user] is trying to ignite [user.p_them()]self with \the [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
||||
user.visible_message(span_suicide("[user] is trying to ignite [user.p_them()]self with \the [src]! It looks like [user.p_theyre()] trying to commit suicide!"))
|
||||
user.IgniteMob()
|
||||
return FIRELOSS
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
add_fingerprint(user)
|
||||
|
||||
/obj/item/assembly/igniter/ignition_effect(atom/A, mob/user)
|
||||
. = "<span class='notice'>[user] fiddles with [src], and manages to light [A].</span>"
|
||||
. = span_notice("[user] fiddles with [src], and manages to light [A].")
|
||||
activate()
|
||||
add_fingerprint(user)
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
|
||||
/obj/item/assembly/infra/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>The infrared trigger is [on?"on":"off"].</span>"
|
||||
. += span_notice("The infrared trigger is [on?"on":"off"].")
|
||||
|
||||
/obj/item/assembly/infra/activate()
|
||||
if(!..())
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
/obj/item/assembly/mousetrap/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>The pressure plate is [armed?"primed":"safe"].</span>"
|
||||
. += span_notice("The pressure plate is [armed?"primed":"safe"].")
|
||||
|
||||
/obj/item/assembly/mousetrap/activate()
|
||||
if(..())
|
||||
@@ -32,7 +32,7 @@
|
||||
if(ishuman(usr))
|
||||
var/mob/living/carbon/human/user = usr
|
||||
if((HAS_TRAIT(user, TRAIT_DUMB) || HAS_TRAIT(user, TRAIT_CLUMSY)) && prob(50))
|
||||
to_chat(user, "<span class='warning'>Your hand slips, setting off the trigger!</span>")
|
||||
to_chat(user, span_warning("Your hand slips, setting off the trigger!"))
|
||||
pulse(FALSE)
|
||||
update_appearance()
|
||||
playsound(src, 'sound/weapons/handcuffs.ogg', 30, TRUE, -3)
|
||||
@@ -79,15 +79,15 @@
|
||||
H.update_damage_overlays()
|
||||
else if(ismouse(target))
|
||||
var/mob/living/simple_animal/mouse/M = target
|
||||
visible_message("<span class='boldannounce'>SPLAT!</span>")
|
||||
visible_message(span_boldannounce("SPLAT!"))
|
||||
M.splat()
|
||||
else if(israt(target))
|
||||
var/mob/living/simple_animal/hostile/rat/ratt = target
|
||||
visible_message("<span class='boldannounce'>Clink!</span>")
|
||||
visible_message(span_boldannounce("Clink!"))
|
||||
ratt.apply_damage(5) //Not lethal, but just enought to make a mark.
|
||||
ratt.Stun(1 SECONDS)
|
||||
else if(isregalrat(target))
|
||||
visible_message("<span class='boldannounce'>Skreeeee!</span>") //He's simply too large to be affected by a tiny mouse trap.
|
||||
visible_message(span_boldannounce("Skreeeee!")) //He's simply too large to be affected by a tiny mouse trap.
|
||||
playsound(src, 'sound/effects/snap.ogg', 50, TRUE)
|
||||
armed = FALSE
|
||||
update_appearance()
|
||||
@@ -96,17 +96,17 @@
|
||||
|
||||
/obj/item/assembly/mousetrap/attack_self(mob/living/carbon/human/user)
|
||||
if(!armed)
|
||||
to_chat(user, "<span class='notice'>You arm [src].</span>")
|
||||
to_chat(user, span_notice("You arm [src]."))
|
||||
else
|
||||
if((HAS_TRAIT(user, TRAIT_DUMB) || HAS_TRAIT(user, TRAIT_CLUMSY)) && prob(50))
|
||||
var/which_hand = BODY_ZONE_PRECISE_L_HAND
|
||||
if(!(user.active_hand_index % 2))
|
||||
which_hand = BODY_ZONE_PRECISE_R_HAND
|
||||
triggered(user, which_hand)
|
||||
user.visible_message("<span class='warning'>[user] accidentally sets off [src], breaking their fingers.</span>", \
|
||||
"<span class='warning'>You accidentally trigger [src]!</span>")
|
||||
user.visible_message(span_warning("[user] accidentally sets off [src], breaking their fingers."), \
|
||||
span_warning("You accidentally trigger [src]!"))
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You disarm [src].</span>")
|
||||
to_chat(user, span_notice("You disarm [src]."))
|
||||
armed = !armed
|
||||
update_appearance()
|
||||
playsound(src, 'sound/weapons/handcuffs.ogg', 30, TRUE, -3)
|
||||
@@ -120,8 +120,8 @@
|
||||
if(!(user.active_hand_index % 2))
|
||||
which_hand = BODY_ZONE_PRECISE_R_HAND
|
||||
triggered(user, which_hand)
|
||||
user.visible_message("<span class='warning'>[user] accidentally sets off [src], breaking their fingers.</span>", \
|
||||
"<span class='warning'>You accidentally trigger [src]!</span>")
|
||||
user.visible_message(span_warning("[user] accidentally sets off [src], breaking their fingers."), \
|
||||
span_warning("You accidentally trigger [src]!"))
|
||||
return
|
||||
return ..()
|
||||
|
||||
@@ -136,8 +136,8 @@
|
||||
var/mob/living/carbon/H = AM
|
||||
if(H.m_intent == MOVE_INTENT_RUN)
|
||||
INVOKE_ASYNC(src, .proc/triggered, H)
|
||||
H.visible_message("<span class='warning'>[H] accidentally steps on [src].</span>", \
|
||||
"<span class='warning'>You accidentally step on [src]</span>")
|
||||
H.visible_message(span_warning("[H] accidentally steps on [src]."), \
|
||||
span_warning("You accidentally step on [src]"))
|
||||
else if(ismouse(MM) || israt(MM) || isregalrat(MM))
|
||||
INVOKE_ASYNC(src, .proc/triggered, MM)
|
||||
else if(AM.density) // For mousetrap grenades, set off by anything heavy
|
||||
@@ -146,12 +146,12 @@
|
||||
/obj/item/assembly/mousetrap/on_found(mob/finder)
|
||||
if(armed)
|
||||
if(finder)
|
||||
finder.visible_message("<span class='warning'>[finder] accidentally sets off [src], breaking their fingers.</span>", \
|
||||
"<span class='warning'>You accidentally trigger [src]!</span>")
|
||||
finder.visible_message(span_warning("[finder] accidentally sets off [src], breaking their fingers."), \
|
||||
span_warning("You accidentally trigger [src]!"))
|
||||
triggered(finder, (finder.active_hand_index % 2 == 0) ? BODY_ZONE_PRECISE_R_HAND : BODY_ZONE_PRECISE_L_HAND)
|
||||
return TRUE //end the search!
|
||||
else
|
||||
visible_message("<span class='warning'>[src] snaps shut!</span>")
|
||||
visible_message(span_warning("[src] snaps shut!"))
|
||||
triggered(loc)
|
||||
return FALSE
|
||||
return FALSE
|
||||
@@ -160,7 +160,7 @@
|
||||
/obj/item/assembly/mousetrap/hitby(atom/movable/AM, skipcatch, hitpush, blocked, datum/thrownthing/throwingdatum)
|
||||
if(!armed)
|
||||
return ..()
|
||||
visible_message("<span class='warning'>[src] is triggered by [AM].</span>")
|
||||
visible_message(span_warning("[src] is triggered by [AM]."))
|
||||
triggered(null)
|
||||
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
/obj/item/assembly/prox_sensor/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>The proximity sensor is [timing ? "arming" : (scanning ? "armed" : "disarmed")].</span>"
|
||||
. += span_notice("The proximity sensor is [timing ? "arming" : (scanning ? "armed" : "disarmed")].")
|
||||
|
||||
/obj/item/assembly/prox_sensor/activate()
|
||||
if(!..())
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
/obj/item/assembly/shock_kit/wrench_act(mob/living/user, obj/item/I)
|
||||
..()
|
||||
to_chat(user, "<span class='notice'>You disassemble [src].</span>")
|
||||
to_chat(user, span_notice("You disassemble [src]."))
|
||||
if(helmet_part)
|
||||
helmet_part.forceMove(drop_location())
|
||||
helmet_part.master = null
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
var/last_receive_signal_log
|
||||
|
||||
/obj/item/assembly/signaler/suicide_act(mob/living/carbon/user)
|
||||
user.visible_message("<span class='suicide'>[user] eats \the [src]! If it is signaled, [user.p_they()] will die!</span>")
|
||||
user.visible_message(span_suicide("[user] eats \the [src]! If it is signaled, [user.p_they()] will die!"))
|
||||
playsound(src, 'sound/items/eatfood.ogg', 50, TRUE)
|
||||
moveToNullspace()
|
||||
suicider = user.mind
|
||||
@@ -36,9 +36,9 @@
|
||||
if(!istype(user))
|
||||
return
|
||||
if(suicide_mob == REF(user))
|
||||
user.visible_message("<span class='suicide'>[user]'s [src] receives a signal, killing [user.p_them()] instantly!</span>")
|
||||
user.visible_message(span_suicide("[user]'s [src] receives a signal, killing [user.p_them()] instantly!"))
|
||||
else
|
||||
user.visible_message("<span class='suicide'>[user]'s [src] receives a signal and [user.p_they()] die[user.p_s()] like a gamer!</span>")
|
||||
user.visible_message(span_suicide("[user]'s [src] receives a signal and [user.p_they()] die[user.p_s()] like a gamer!"))
|
||||
user.set_suicide(TRUE)
|
||||
user.adjustOxyLoss(200)//it sends an electrical pulse to their heart, killing them. or something.
|
||||
user.death(0)
|
||||
@@ -179,7 +179,7 @@
|
||||
|
||||
/obj/item/assembly/signaler/receiver/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>The radio receiver is [on?"on":"off"].</span>"
|
||||
. += span_notice("The radio receiver is [on?"on":"off"].")
|
||||
|
||||
/obj/item/assembly/signaler/receiver/receive_signal(datum/signal/signal)
|
||||
if(!on)
|
||||
|
||||
@@ -14,13 +14,13 @@
|
||||
var/hearing_range = 3
|
||||
|
||||
/obj/item/assembly/timer/suicide_act(mob/living/user)
|
||||
user.visible_message("<span class='suicide'>[user] looks at the timer and decides [user.p_their()] fate! It looks like [user.p_theyre()] going to commit suicide!</span>")
|
||||
user.visible_message(span_suicide("[user] looks at the timer and decides [user.p_their()] fate! It looks like [user.p_theyre()] going to commit suicide!"))
|
||||
activate()//doesnt rely on timer_end to prevent weird metas where one person can control the timer and therefore someone's life. (maybe that should be how it works...)
|
||||
addtimer(CALLBACK(src, .proc/manual_suicide, user), time SECONDS)//kill yourself once the time runs out
|
||||
return MANUAL_SUICIDE
|
||||
|
||||
/obj/item/assembly/timer/proc/manual_suicide(mob/living/user)
|
||||
user.visible_message("<span class='suicide'>[user]'s time is up!</span>")
|
||||
user.visible_message(span_suicide("[user]'s time is up!"))
|
||||
user.adjustOxyLoss(200)
|
||||
user.death(0)
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
|
||||
/obj/item/assembly/timer/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>The timer is [timing ? "counting down from [time]":"set for [time] seconds"].</span>"
|
||||
. += span_notice("The timer is [timing ? "counting down from [time]":"set for [time] seconds"].")
|
||||
|
||||
/obj/item/assembly/timer/activate()
|
||||
if(!..())
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
/obj/item/assembly/voice/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>Use a multitool to swap between \"inclusive\", \"exclusive\", \"recognizer\", and \"voice sensor\" mode.</span>"
|
||||
. += span_notice("Use a multitool to swap between \"inclusive\", \"exclusive\", \"recognizer\", and \"voice sensor\" mode.")
|
||||
|
||||
/obj/item/assembly/voice/Hear(message, atom/movable/speaker, message_language, raw_message, radio_freq, list/spans, list/message_mods = list())
|
||||
. = ..()
|
||||
@@ -93,7 +93,7 @@
|
||||
..()
|
||||
mode %= modes.len
|
||||
mode++
|
||||
to_chat(user, "<span class='notice'>You set [src] into [modes[mode]] mode.</span>")
|
||||
to_chat(user, span_notice("You set [src] into [modes[mode]] mode."))
|
||||
listening = FALSE
|
||||
recorded = ""
|
||||
return TRUE
|
||||
|
||||
Reference in New Issue
Block a user