mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-30 15:38:02 +01:00
refactors most spans
This commit is contained in:
@@ -166,13 +166,13 @@
|
||||
if(weedlevel > 0)
|
||||
nymph.reagents.add_reagent("glucose", weedlevel)
|
||||
weedlevel = 0
|
||||
nymph.visible_message("<span class='notice'><b>[nymph]</b> begins rooting through [src], ripping out weeds and eating them noisily.</span>","<span class='notice'>You begin rooting through [src], ripping out weeds and eating them noisily.</span>")
|
||||
nymph.visible_message(span_notice("<b>[nymph]</b> begins rooting through [src], ripping out weeds and eating them noisily."),span_notice("You begin rooting through [src], ripping out weeds and eating them noisily."))
|
||||
else if(nymph.nutrition > 100 && nutrilevel < 10)
|
||||
nymph.nutrition -= ((10-nutrilevel)*5)
|
||||
nutrilevel = 10
|
||||
nymph.visible_message("<span class='notice'><b>[nymph]</b> secretes a trickle of green liquid, refilling [src].</span>","<span class='notice'>You secrete a trickle of green liquid, refilling [src].</span>")
|
||||
nymph.visible_message(span_notice("<b>[nymph]</b> secretes a trickle of green liquid, refilling [src]."),span_notice("You secrete a trickle of green liquid, refilling [src]."))
|
||||
else
|
||||
nymph.visible_message("<span class='notice'><b>[nymph]</b> rolls around in [src] for a bit.</span>","<span class='notice'>You roll around in [src] for a bit.</span>")
|
||||
nymph.visible_message(span_notice("<b>[nymph]</b> rolls around in [src] for a bit."),span_notice("You roll around in [src] for a bit."))
|
||||
return
|
||||
|
||||
/obj/machinery/portable_atmospherics/hydroponics/Initialize()
|
||||
@@ -330,7 +330,7 @@
|
||||
|
||||
if(closed_system)
|
||||
if(user)
|
||||
to_chat(user, "<span class='filter_notice'>You can't harvest from the plant while the lid is shut.</span>")
|
||||
to_chat(user, span_filter_notice("You can't harvest from the plant while the lid is shut."))
|
||||
return
|
||||
|
||||
if(user)
|
||||
@@ -357,7 +357,7 @@
|
||||
if(!user || !dead) return
|
||||
|
||||
if(closed_system)
|
||||
to_chat(user, "<span class='filter_notice'>You can't remove the dead plant while the lid is shut.</span>")
|
||||
to_chat(user, span_filter_notice("You can't remove the dead plant while the lid is shut."))
|
||||
return
|
||||
|
||||
seed = null
|
||||
@@ -367,7 +367,7 @@
|
||||
yield_mod = 0
|
||||
mutation_mod = 0
|
||||
|
||||
to_chat(user, "<span class='filter_notice'>You remove the dead plant.</span>")
|
||||
to_chat(user, span_filter_notice("You remove the dead plant."))
|
||||
lastproduce = 0
|
||||
check_health()
|
||||
return
|
||||
@@ -392,7 +392,7 @@
|
||||
pestlevel = 0
|
||||
sampled = 0
|
||||
update_icon()
|
||||
visible_message("<span class='notice'>\The [previous_plant ? previous_plant : initial(name)] has been overtaken by [seed.display_name].</span>")
|
||||
visible_message(span_notice("\The [previous_plant ? previous_plant : initial(name)] has been overtaken by [seed.display_name]."))
|
||||
|
||||
return
|
||||
|
||||
@@ -426,11 +426,11 @@
|
||||
return
|
||||
if(ishuman(usr) || istype(usr, /mob/living/silicon/robot))
|
||||
if(labelled)
|
||||
to_chat(usr, "<span class='filter_notice'>You remove the label.</span>")
|
||||
to_chat(usr, span_filter_notice("You remove the label."))
|
||||
labelled = null
|
||||
update_icon()
|
||||
else
|
||||
to_chat(usr, "<span class='filter_notice'>There is no label to remove.</span>")
|
||||
to_chat(usr, span_filter_notice("There is no label to remove."))
|
||||
return
|
||||
|
||||
/obj/machinery/portable_atmospherics/hydroponics/verb/setlight()
|
||||
@@ -444,7 +444,7 @@
|
||||
var/new_light = tgui_input_list(usr, "Specify a light level.", "Light Level", list(0,1,2,3,4,5,6,7,8,9,10))
|
||||
if(new_light)
|
||||
tray_light = new_light
|
||||
to_chat(usr, "<span class='filter_notice'>You set the tray to a light level of [tray_light] lumens.</span>")
|
||||
to_chat(usr, span_filter_notice("You set the tray to a light level of [tray_light] lumens."))
|
||||
return
|
||||
|
||||
/obj/machinery/portable_atmospherics/hydroponics/proc/check_level_sanity()
|
||||
@@ -480,7 +480,7 @@
|
||||
weedlevel = 0
|
||||
|
||||
update_icon()
|
||||
visible_message("<span class='danger'>The <span class='notice'>[previous_plant]</span> has suddenly mutated into <span class='notice'>[seed.display_name]!</span></span>")
|
||||
visible_message(span_danger("The <span class='notice'>[previous_plant]</span> has suddenly mutated into <span class='notice'>[seed.display_name]!</span>"))
|
||||
|
||||
return
|
||||
|
||||
@@ -492,15 +492,15 @@
|
||||
if(O.has_tool_quality(TOOL_WIRECUTTER) || istype(O, /obj/item/surgical/scalpel))
|
||||
|
||||
if(!seed)
|
||||
to_chat(user, "<span class='filter_notice'>There is nothing to take a sample from in \the [src].</span>")
|
||||
to_chat(user, span_filter_notice("There is nothing to take a sample from in \the [src]."))
|
||||
return
|
||||
|
||||
if(sampled)
|
||||
to_chat(user, "<span class='filter_notice'>You have already sampled from this plant.</span>")
|
||||
to_chat(user, span_filter_notice("You have already sampled from this plant."))
|
||||
return
|
||||
|
||||
if(dead)
|
||||
to_chat(user, "<span class='filter_notice'>The plant is dead.</span>")
|
||||
to_chat(user, span_filter_notice("The plant is dead."))
|
||||
return
|
||||
|
||||
// Create a sample.
|
||||
@@ -525,14 +525,14 @@
|
||||
if(seed)
|
||||
return ..()
|
||||
else
|
||||
to_chat(user, "<span class='filter_notice'>There's no plant to inject.</span>")
|
||||
to_chat(user, span_filter_notice("There's no plant to inject."))
|
||||
return 1
|
||||
else
|
||||
if(seed)
|
||||
//Leaving this in in case we want to extract from plants later.
|
||||
to_chat(user, "<span class='filter_notice'>You can't get any extract out of this plant.</span>")
|
||||
to_chat(user, span_filter_notice("You can't get any extract out of this plant."))
|
||||
else
|
||||
to_chat(user, "<span class='filter_notice'>There's nothing to draw something from.</span>")
|
||||
to_chat(user, span_filter_notice("There's nothing to draw something from."))
|
||||
return 1
|
||||
|
||||
else if (istype(O, /obj/item/seeds))
|
||||
@@ -543,24 +543,24 @@
|
||||
user.remove_from_mob(O)
|
||||
|
||||
if(!S.seed)
|
||||
to_chat(user, "<span class='filter_notice'>The packet seems to be empty. You throw it away.</span>")
|
||||
to_chat(user, span_filter_notice("The packet seems to be empty. You throw it away."))
|
||||
qdel(O)
|
||||
return
|
||||
|
||||
to_chat(user, "<span class='filter_notice'>You plant the [S.seed.seed_name] [S.seed.seed_noun].</span>")
|
||||
to_chat(user, span_filter_notice("You plant the [S.seed.seed_name] [S.seed.seed_noun]."))
|
||||
plant_seeds(S)
|
||||
|
||||
else
|
||||
to_chat(user, "<span class='danger'>\The [src] already has seeds in it!</span>")
|
||||
to_chat(user, span_danger("\The [src] already has seeds in it!"))
|
||||
|
||||
else if (istype(O, /obj/item/material/minihoe)) // The minihoe
|
||||
|
||||
if(weedlevel > 0)
|
||||
user.visible_message("<span class='danger'>[user] starts uprooting the weeds.</span>", "<span class='danger'>You remove the weeds from the [src].</span>")
|
||||
user.visible_message(span_danger("[user] starts uprooting the weeds."), span_danger("You remove the weeds from the [src]."))
|
||||
weedlevel = 0
|
||||
update_icon()
|
||||
else
|
||||
to_chat(user, "<span class='danger'>This plot is completely devoid of weeds. It doesn't need uprooting.</span>")
|
||||
to_chat(user, span_danger("This plot is completely devoid of weeds. It doesn't need uprooting."))
|
||||
|
||||
else if (istype(O, /obj/item/storage/bag/plants))
|
||||
|
||||
@@ -579,7 +579,7 @@
|
||||
toxins += spray.toxicity
|
||||
pestlevel -= spray.pest_kill_str
|
||||
weedlevel -= spray.weed_kill_str
|
||||
to_chat(user, "<span class='filter_notice'>You spray [src] with [O].</span>")
|
||||
to_chat(user, span_filter_notice("You spray [src] with [O]."))
|
||||
playsound(src, 'sound/effects/spray3.ogg', 50, 1, -6)
|
||||
qdel(O)
|
||||
check_health()
|
||||
@@ -592,23 +592,23 @@
|
||||
|
||||
playsound(src, O.usesound, 50, 1)
|
||||
anchored = !anchored
|
||||
to_chat(user, "<span class='filter_notice'>You [anchored ? "wrench" : "unwrench"] \the [src].</span>")
|
||||
to_chat(user, span_filter_notice("You [anchored ? "wrench" : "unwrench"] \the [src]."))
|
||||
|
||||
else if(istype(O,/obj/item/multitool))
|
||||
if(!anchored)
|
||||
to_chat(user, "<span class='warning'>Anchor it first!</span>")
|
||||
to_chat(user, span_warning("Anchor it first!"))
|
||||
return
|
||||
if(frozen == -1)
|
||||
to_chat(user, "<span class='warning'>You see no way to use \the [O] on [src].</span>")
|
||||
to_chat(user, span_warning("You see no way to use \the [O] on [src]."))
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You [frozen ? "disable" : "enable"] the cryogenic freezing.</span>")
|
||||
to_chat(user, span_notice("You [frozen ? "disable" : "enable"] the cryogenic freezing."))
|
||||
frozen = !frozen
|
||||
update_icon()
|
||||
return
|
||||
|
||||
else if(O.force && seed)
|
||||
user.setClickCooldown(user.get_attack_speed(O))
|
||||
user.visible_message("<span class='danger'>\The [seed.display_name] has been attacked by [user] with \the [O]!</span>")
|
||||
user.visible_message(span_danger("\The [seed.display_name] has been attacked by [user] with \the [O]!"))
|
||||
if(!dead)
|
||||
health -= O.force
|
||||
check_health()
|
||||
@@ -626,7 +626,7 @@
|
||||
if(istype(usr,/mob/living/silicon))
|
||||
return
|
||||
if(frozen == 1)
|
||||
to_chat(user, "<span class='warning'>Disable the cryogenic freezing first!</span>")
|
||||
to_chat(user, span_warning("Disable the cryogenic freezing first!"))
|
||||
if(harvest)
|
||||
harvest(user)
|
||||
else if(dead)
|
||||
@@ -636,7 +636,7 @@
|
||||
. = ..()
|
||||
|
||||
if(seed)
|
||||
. += "<span class='notice'>[seed.display_name] are growing here.</span>"
|
||||
. += span_notice("[seed.display_name] are growing here.")
|
||||
else
|
||||
. += "It is empty."
|
||||
|
||||
@@ -656,7 +656,7 @@
|
||||
else if(health <= (seed.get_trait(TRAIT_ENDURANCE)/ 2))
|
||||
. += "It has <span class='danger'>an unhealthy plant</span>!"
|
||||
if(frozen == 1)
|
||||
. += "<span class='notice'>It is cryogenically frozen.</span>"
|
||||
. += span_notice("It is cryogenically frozen.")
|
||||
if(mechanical)
|
||||
var/turf/T = loc
|
||||
var/datum/gas_mixture/environment
|
||||
@@ -694,5 +694,5 @@
|
||||
|
||||
/obj/machinery/portable_atmospherics/hydroponics/proc/close_lid(var/mob/living/user)
|
||||
closed_system = !closed_system
|
||||
to_chat(user, "<span class='filter_notice'>You [closed_system ? "close" : "open"] the tray's lid.</span>")
|
||||
to_chat(user, span_filter_notice("You [closed_system ? "close" : "open"] the tray's lid."))
|
||||
update_icon()
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
if(do_after(user, 5 SECONDS, exclusive = TASK_USER_EXCLUSIVE))
|
||||
qdel(src)
|
||||
else
|
||||
to_chat(user, "<span class='notice'>There is something growing here.</span>")
|
||||
to_chat(user, span_notice("There is something growing here."))
|
||||
else
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -100,20 +100,20 @@
|
||||
|
||||
var/obj/machinery/portable_atmospherics/hydroponics/H = target
|
||||
if(H.frozen == 1)
|
||||
to_chat(user, "<span class='warning'>Disable the cryogenic freezing first!</span>")
|
||||
to_chat(user, span_warning("Disable the cryogenic freezing first!"))
|
||||
return
|
||||
grown_seed = H.seed
|
||||
grown_reagents = H.reagents
|
||||
|
||||
if(!grown_seed)
|
||||
to_chat(user, "<span class='danger'>[src] can tell you nothing about \the [target].</span>")
|
||||
to_chat(user, span_danger("[src] can tell you nothing about \the [target]."))
|
||||
return
|
||||
|
||||
last_seed = grown_seed.diverge()
|
||||
if(!istype(last_seed))
|
||||
last_seed = grown_seed // TRAIT_IMMUTABLE makes diverge() return null
|
||||
|
||||
user.visible_message("<span class='notice'>[user] runs the scanner over \the [target].</span>")
|
||||
user.visible_message(span_notice("[user] runs the scanner over \the [target]."))
|
||||
|
||||
last_reagents = list()
|
||||
if(grown_reagents && grown_reagents.reagent_list && grown_reagents.reagent_list.len)
|
||||
@@ -137,7 +137,7 @@
|
||||
/obj/item/analyzer/plant_analyzer/proc/print_report(var/mob/living/user)
|
||||
var/datum/seed/grown_seed = last_seed
|
||||
if(!istype(grown_seed))
|
||||
to_chat(user, "<span class='warning'>There is no scan data to print.</span>")
|
||||
to_chat(user, span_warning("There is no scan data to print."))
|
||||
return
|
||||
|
||||
var/form_title = "[grown_seed.seed_name] (#[grown_seed.uid])"
|
||||
@@ -306,4 +306,4 @@
|
||||
amount = "small amounts of "
|
||||
data["trait_info"] += "It will consume [amount][gas_data.name[gas]] from the environment."
|
||||
|
||||
return data
|
||||
return data
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
if(!seed.growth_stages)
|
||||
seed.update_growth_stages()
|
||||
if(!seed.growth_stages)
|
||||
to_world("<span class='danger'>Seed type [seed.get_trait(TRAIT_PLANT_ICON)] cannot find a growth stage value.</span>")
|
||||
to_world(span_danger("Seed type [seed.get_trait(TRAIT_PLANT_ICON)] cannot find a growth stage value."))
|
||||
return
|
||||
var/overlay_stage = 1
|
||||
if(age >= seed.get_trait(TRAIT_MATURATION))
|
||||
|
||||
Reference in New Issue
Block a user