[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:
CHOMPStation2
2024-10-04 06:00:17 -07:00
committed by GitHub
parent 43ee646816
commit ab154b48b2
1511 changed files with 12497 additions and 12357 deletions

View File

@@ -124,10 +124,10 @@ GLOBAL_LIST_INIT(generic_fishing_chance_list, list(FISHING_RARE = 5, FISHING_UNC
if(istype(P, /obj/item/material/fishing_rod) && !being_fished)
var/obj/item/material/fishing_rod/R = P
if(!R.strung)
to_chat(user, "<span class='notice'>It is hard to go fishing without any line!</span>")
to_chat(user, span_notice("It is hard to go fishing without any line!"))
return
if(R.cast)
to_chat(user, "<span class='notice'>You can only cast one line at a time!</span>")
to_chat(user, span_notice("You can only cast one line at a time!"))
return
playsound(src, 'sound/effects/slosh.ogg', 5, 1, 5)
to_chat(user,"You cast \the [P.name] into \the [src].")
@@ -136,7 +136,7 @@ GLOBAL_LIST_INIT(generic_fishing_chance_list, list(FISHING_RARE = 5, FISHING_UNC
var/fishing_time = rand(min_fishing_time SECONDS,max_fishing_time SECONDS) * R.toolspeed
if(do_after(user,fishing_time,user))
playsound(src, 'sound/effects/slosh.ogg', 5, 1, 5)
to_chat(user,"<span class='notice'>You feel a tug and begin pulling!</span>")
to_chat(user,span_notice("You feel a tug and begin pulling!"))
if(world.time >= last_fished + fishing_cooldown)
pick_fish()
last_fished = world.time
@@ -146,7 +146,7 @@ GLOBAL_LIST_INIT(generic_fishing_chance_list, list(FISHING_RARE = 5, FISHING_UNC
has_fish = FALSE
//List of possible outcomes.
if(!fish_type)
to_chat(user,"<span class='filter_notice'>You caught... nothing. How sad.</span>")
to_chat(user,span_filter_notice("You caught... nothing. How sad."))
else
var/fished = new fish_type(get_turf(user))
if(isliving(fished))
@@ -155,10 +155,10 @@ GLOBAL_LIST_INIT(generic_fishing_chance_list, list(FISHING_RARE = 5, FISHING_UNC
if(prob(rand(L.mob_size) + 10) && R.line_break)
R.strung = FALSE
R.update_icon()
user.visible_message("<span class='danger'>\The [R]'s string snaps!</span>")
user.visible_message(span_danger("\The [R]'s string snaps!"))
if(prob(33)) // Dead on hook. Good for food, not so much for live catch.
L.death()
to_chat(user,"<span class='notice'>You fish out \the [fished] from the water with [P.name]!</span>")
to_chat(user,span_notice("You fish out \the [fished] from the water with [P.name]!"))
R.cast = FALSE
being_fished = FALSE
else ..()

View File

@@ -45,13 +45,13 @@
accept = TRUE
for(var/atom/At in src.contents)
if(isliving(At))
to_chat(user, "<span class='notice'>Your net is already holding something!</span>")
to_chat(user, span_notice("Your net is already holding something!"))
accept = FALSE
if(!accept)
to_chat(user, "<span class='filter_notice'>[A] can't be trapped in \the [src].</span>")
to_chat(user, span_filter_notice("[A] can't be trapped in \the [src]."))
return
var/mob/L = A
user.visible_message("<span class='notice'>[user] snatches [L] with \the [src].</span>", "<span class='notice'>You snatch [L] with \the [src].</span>")
user.visible_message(span_notice("[user] snatches [L] with \the [src]."), span_notice("You snatch [L] with \the [src]."))
L.forceMove(src)
update_icon()
update_weight()
@@ -61,10 +61,10 @@
/obj/item/material/fishing_net/attack_self(var/mob/user)
for(var/mob/M in src)
M.forceMove(get_turf(src))
user.visible_message("<span class='notice'>[user] releases [M] from \the [src].</span>", "<span class='notice'>You release [M] from \the [src].</span>")
user.visible_message(span_notice("[user] releases [M] from \the [src]."), span_notice("You release [M] from \the [src]."))
for(var/obj/item/I in src)
I.forceMove(get_turf(src))
user.visible_message("<span class='notice'>[user] dumps \the [I] out of \the [src].</span>", "<span class='notice'>You dump \the [I] out of \the [src].</span>")
user.visible_message(span_notice("[user] dumps \the [I] out of \the [src]."), span_notice("You dump \the [I] out of \the [src]."))
update_icon()
update_weight()
return
@@ -154,13 +154,13 @@
accept = TRUE
for(var/atom/At in src.contents)
if(isliving(At))
to_chat(user, "<span class='notice'>Your net is already holding something!</span>")
to_chat(user, span_notice("Your net is already holding something!"))
accept = FALSE
if(!accept)
to_chat(user, "<span class='filter_notice'>[A] can't be trapped in \the [src].</span>")
to_chat(user, span_filter_notice("[A] can't be trapped in \the [src]."))
return
var/mob/L = A
user.visible_message("<span class='notice'>[user] snatches [L] with \the [src].</span>", "<span class='notice'>You snatch [L] with \the [src].</span>")
user.visible_message(span_notice("[user] snatches [L] with \the [src]."), span_notice("You snatch [L] with \the [src]."))
L.forceMove(src)
playsound(src, 'sound/effects/plop.ogg', 50, 1)
update_icon()
@@ -173,13 +173,13 @@
if(!user.get_inactive_hand()) //Check if the inactive hand is empty
M.forceMove(get_turf(src))
M.attempt_to_scoop(user)
user.visible_message("<span class='notice'>[user] scoops [M] out from \the [src].</span>", "<span class='notice'>You pull [M] from \the [src].</span>")
user.visible_message(span_notice("[user] scoops [M] out from \the [src]."), span_notice("You pull [M] from \the [src]."))
else
M.forceMove(get_turf(src))
user.visible_message("<span class='notice'>[user] releases [M] from \the [src].</span>", "<span class='notice'>You release [M] from \the [src].</span>")
user.visible_message(span_notice("[user] releases [M] from \the [src]."), span_notice("You release [M] from \the [src]."))
for(var/obj/item/I in src)
I.forceMove(get_turf(src))
user.visible_message("<span class='notice'>[user] dumps \the [I] out of \the [src].</span>", "<span class='notice'>You dump \the [I] out of \the [src].</span>")
user.visible_message(span_notice("[user] dumps \the [I] out of \the [src]."), span_notice("You dump \the [I] out of \the [src]."))
update_icon()
update_weight()
return
@@ -187,11 +187,11 @@
/obj/item/material/fishing_net/butterfly_net/container_resist(mob/living/M)
if(prob(20))
M.forceMove(get_turf(src))
to_chat(M, "<span class='warning'>You climb out of \the [src].</span>")
to_chat(M, span_warning("You climb out of \the [src]."))
update_icon()
update_weight()
else
to_chat(M, "<span class='warning'>You fail to escape \the [src].</span>")
to_chat(M, span_warning("You fail to escape \the [src]."))
/obj/item/material/fishing_net/butterfly_net/update_icon() // Also updates name and desc
underlays.Cut()

View File

@@ -35,13 +35,13 @@
/obj/item/material/fishing_rod/examine(mob/user)
. = ..()
if(Bait)
. += "<span class='notice'>It has [Bait] hanging on its hook: </span>"
. += span_notice("It has [Bait] hanging on its hook: ")
. += Bait.examine(user)
/obj/item/material/fishing_rod/CtrlClick(mob/user)
if((src.loc == user || Adjacent(user)) && Bait)
Bait.forceMove(get_turf(user))
to_chat(user, "<span class='notice'>You remove the bait from \the [src].</span>")
to_chat(user, span_notice("You remove the bait from \the [src]."))
Bait = null
else
..()
@@ -53,24 +53,24 @@
/obj/item/material/fishing_rod/attackby(obj/item/I as obj, mob/user as mob)
if(I.has_tool_quality(TOOL_WIRECUTTER) && strung)
strung = FALSE
to_chat(user, "<span class='notice'>You cut \the [src]'s string!</span>")
to_chat(user, span_notice("You cut \the [src]'s string!"))
update_icon()
return
else if(istype(I, /obj/item/stack/cable_coil) && !strung)
var/obj/item/stack/cable_coil/C = I
if(C.get_amount() < 5)
to_chat(user, "<span class='warning'>You do not have enough length in \the [C] to string this!</span>")
to_chat(user, span_warning("You do not have enough length in \the [C] to string this!"))
return
if(do_after(user, rand(10 SECONDS, 20 SECONDS)))
C.use(5)
strung = TRUE
to_chat(user, "<span class='notice'>You string \the [src]!</span>")
to_chat(user, span_notice("You string \the [src]!"))
update_icon()
return
else if(istype(I, bait_type))
if(Bait)
Bait.forceMove(get_turf(user))
to_chat(user, "<span class='notice'>You swap \the [Bait] with \the [I].</span>")
to_chat(user, span_notice("You swap \the [Bait] with \the [I]."))
Bait = I
user.drop_from_inventory(Bait)
Bait.forceMove(src)
@@ -104,7 +104,7 @@
/obj/item/material/fishing_rod/attack(var/mob/M as mob, var/mob/user as mob, var/def_zone)
if(cast)
to_chat(user, "<span class='notice'>You cannot cast \the [src] when it is already in use!</span>")
to_chat(user, span_notice("You cannot cast \the [src] when it is already in use!"))
return FALSE
update_bait()
return ..()
@@ -128,4 +128,4 @@
desc = "Mass produced, but somewhat reliable."
default_material = "plastic"
toolspeed = 0.9
toolspeed = 0.9