Improve extended examination text for many objects (#31381)

Plurality, capitalization, punctuation, and item icons have been
improved. Status displays now show the same text on examination that
they do visually. Inducers only show a success message when they
actually succeed.
This commit is contained in:
Tad Hardesty
2017-10-10 01:06:46 -07:00
committed by CitadelStationBot
parent eb9737912c
commit 01ecdff51a
47 changed files with 143 additions and 128 deletions
@@ -55,7 +55,7 @@
/obj/effect/clockwork/spatial_gateway/examine(mob/user)
..()
if(is_servant_of_ratvar(user) || isobserver(user))
to_chat(user, "<span class='brass'>It has [uses] uses remaining.</span>")
to_chat(user, "<span class='brass'>It has [uses] use\s remaining.</span>")
/obj/effect/clockwork/spatial_gateway/attack_ghost(mob/user)
if(linked_gateway)
@@ -122,7 +122,7 @@
continue
var/datum/clockwork_scripture/quickbind_slot = quickbound[i]
to_chat(user, "<b>Quickbind</b> button: <span class='[get_component_span(initial(quickbind_slot.primary_component))]'>[initial(quickbind_slot.name)]</span>.")
to_chat(user, "<b>Available Power:</b> <span class='bold brass'>[DisplayPower(get_clockwork_power())]</span>")
to_chat(user, "<b>Available power:</b> <span class='bold brass'>[DisplayPower(get_clockwork_power())].</span>")
//Slab actions; Hierophant, Quickbind
/obj/item/clockwork/slab/ui_action_click(mob/user, action)
+1 -1
View File
@@ -503,7 +503,7 @@
/obj/item/device/cult_shift/examine(mob/user)
..()
if(uses)
to_chat(user, "<span class='cult'>It has [uses] uses remaining.</span>")
to_chat(user, "<span class='cult'>It has [uses] use\s remaining.</span>")
else
to_chat(user, "<span class='cult'>It seems drained.</span>")
+1 -1
View File
@@ -16,7 +16,7 @@
to_chat(user, msg)
for(var/obj/machinery/nuclearbomb/bomb in GLOB.machines)
if(bomb.timing)
to_chat(user, "Extreme danger. Arming signal detected. Time remaining: [bomb.get_time_left()]")
to_chat(user, "Extreme danger. Arming signal detected. Time remaining: [bomb.get_time_left()].")
/obj/item/pinpointer/nuke/process()
..()
+1 -1
View File
@@ -174,7 +174,7 @@
/obj/machinery/sleeper/emag_act(mob/user)
scramble_chem_buttons()
to_chat(user, "<span class='warning'>You scramble the sleepers user interface!</span>")
to_chat(user, "<span class='warning'>You scramble the sleeper's user interface!</span>")
/obj/machinery/sleeper/proc/inject_chem(chem)
if((chem in available_chems) && chem_allowed(chem))
+3 -3
View File
@@ -443,14 +443,14 @@ Class Procs:
return 0
/obj/machinery/proc/display_parts(mob/user)
to_chat(user, "<span class='notice'>Following parts detected in the machine:</span>")
to_chat(user, "<span class='notice'>It contains the following parts:</span>")
for(var/obj/item/C in component_parts)
to_chat(user, "<span class='notice'>[icon2html(C, user)] [C.name]</span>")
to_chat(user, "<span class='notice'>[icon2html(C, user)] \A [C].</span>")
/obj/machinery/examine(mob/user)
..()
if(stat & BROKEN)
to_chat(user, "<span class='notice'>It looks broken and non functional.</span>")
to_chat(user, "<span class='notice'>It looks broken and non-functional.</span>")
if(!(resistance_flags & INDESTRUCTIBLE))
if(resistance_flags & ON_FIRE)
to_chat(user, "<span class='warning'>It's on fire!</span>")
+1 -1
View File
@@ -27,7 +27,7 @@
..()
to_chat(user, "There's [charging ? "a" : "no"] cell in the charger.")
if(charging)
to_chat(user, "Current charge: [round(charging.percent(), 1)]%")
to_chat(user, "Current charge: [round(charging.percent(), 1)]%.")
/obj/machinery/cell_charger/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/stock_parts/cell))
+10 -10
View File
@@ -568,24 +568,24 @@
if(panel_open)
switch(security_level)
if(AIRLOCK_SECURITY_NONE)
to_chat(user, "Wires are exposed!")
to_chat(user, "Its wires are exposed!")
if(AIRLOCK_SECURITY_METAL)
to_chat(user, "Wires are hidden behind welded metal cover")
to_chat(user, "Its wires are hidden behind a welded metal cover.")
if(AIRLOCK_SECURITY_PLASTEEL_I_S)
to_chat(user, "There is some shredded plasteel inside")
to_chat(user, "There is some shredded plasteel inside.")
if(AIRLOCK_SECURITY_PLASTEEL_I)
to_chat(user, "Wires are behind inner layer of plasteel")
to_chat(user, "Its wires are behind an inner layer of plasteel.")
if(AIRLOCK_SECURITY_PLASTEEL_O_S)
to_chat(user, "There is some shredded plasteel inside")
to_chat(user, "There is some shredded plasteel inside.")
if(AIRLOCK_SECURITY_PLASTEEL_O)
to_chat(user, "There is welded plasteel cover hiding wires")
to_chat(user, "There is a welded plasteel cover hiding its wires.")
if(AIRLOCK_SECURITY_PLASTEEL)
to_chat(user, "There is protective grille over panel")
to_chat(user, "There is a protective grille over its panel.")
else if(security_level)
if(security_level == AIRLOCK_SECURITY_METAL)
to_chat(user, "It looks a bit stronger")
to_chat(user, "It looks a bit stronger.")
else
to_chat(user, "It looks very robust")
to_chat(user, "It looks very robust.")
/obj/machinery/door/airlock/attack_ai(mob/user)
if(!src.canAIControl(user))
@@ -1015,7 +1015,7 @@
if(S.get_amount() < 2)
to_chat(user, "<span class='warning'>You need at least 2 metal sheets to reinforce [src].</span>")
return
to_chat(user, "<span class='notice'>You start reinforcing [src]</span>")
to_chat(user, "<span class='notice'>You start reinforcing [src].</span>")
if(do_after(user, 20, 1, target = src))
if(!panel_open || !S.use(2))
return
+5 -7
View File
@@ -33,14 +33,12 @@
..()
if(!density)
to_chat(user, "<span class='notice'>It is open, but could be <b>pried</b> closed.</span>")
else if(!welded)
to_chat(user, "<span class='notice'>It is closed, but could be <i>pried</i> open. Deconstruction would require it to be <b>welded</b> shut.</span>")
else if(boltslocked)
to_chat(user, "<span class='notice'>It is <i>welded</i> shut. The floor bolts have been locked by <b>screws</b>.</span>")
else
if(!welded)
to_chat(user, "<span class='notice'>It is closed, but could be <i>pried</i> open. Deconstruction would require it to be <b>welded</b> shut.</span>")
else
if(boltslocked)
to_chat(user, "<span class='notice'>It is <i>welded</i> shut. The floor bolt have been locked by <b>screws</b>.</span>")
else
to_chat(user, "<span class='notice'>The bolt locks have been <i>unscrewed</i>, but the bolts themselves are still <b>wrenched</b> to the floor.</span>")
to_chat(user, "<span class='notice'>The bolt locks have been <i>unscrewed</i>, but the bolts themselves are still <b>wrenched</b> to the floor.</span>")
/obj/machinery/door/firedoor/proc/CalculateAffectingAreas()
remove_from_areas()
+15 -32
View File
@@ -4,9 +4,7 @@
/obj/machinery/droneDispenser //Most customizable machine 2015
name = "drone shell dispenser"
desc = "A hefty machine that, when supplied with metal and glass, \
will periodically create a drone shell. \
Does not need to be manually operated."
desc = "A hefty machine that, when supplied with metal and glass, will periodically create a drone shell. Does not need to be manually operated."
icon = 'icons/obj/machines/droneDispenser.dmi'
icon_state = "on"
@@ -46,8 +44,7 @@
var/begin_create_message = "whirs to life!"
var/end_create_message = "dispenses a drone shell."
var/recharge_message = "pings."
var/recharging_text = "It is whirring and clicking. \
It seems to be recharging."
var/recharging_text = "It is whirring and clicking. It seems to be recharging."
var/break_message = "lets out a tinny alarm before falling dark."
var/break_sound = 'sound/machines/warning-buzzer.ogg'
@@ -72,18 +69,14 @@
/obj/machinery/droneDispenser/syndrone/badass //Please forgive me
name = "badass syndrone shell dispenser"
desc = "A suspicious machine that will create Syndicate \
exterminator drones when supplied with metal and glass. \
Disgusting. This one seems ominous."
desc = "A suspicious machine that will create Syndicate exterminator drones when supplied with metal and glass. Disgusting. This one seems ominous."
dispense_type = /obj/item/drone_shell/syndrone/badass
end_create_message = "dispenses an ominous suspicious drone shell."
// I don't need your forgiveness, this is awesome.
/obj/machinery/droneDispenser/snowflake
name = "snowflake drone shell dispenser"
desc = "A hefty machine that, when supplied with metal and glass, \
will periodically create a snowflake drone shell. \
Does not need to be manually operated."
desc = "A hefty machine that, when supplied with metal and glass, will periodically create a snowflake drone shell. Does not need to be manually operated."
dispense_type = /obj/item/drone_shell/snowflake
end_create_message = "dispenses a snowflake drone shell."
// Those holoprojectors aren't cheap
@@ -96,8 +89,7 @@
// This one requires no materials and creates basic hivebots
/obj/machinery/droneDispenser/hivebot
name = "hivebot fabricator"
desc = "A large, bulky machine that whirs with activity, \
steam hissing from vents in its sides."
desc = "A large, bulky machine that whirs with activity, steam hissing from vents in its sides."
icon = 'icons/obj/objects.dmi'
icon_state = "hivebot_fab"
icon_off = "hivebot_fab"
@@ -110,14 +102,13 @@
cooldownTime = 10 //Only 1 second - hivebots are extremely weak
dispense_type = /mob/living/simple_animal/hostile/hivebot
begin_create_message = "closes and begins fabricating something within."
end_create_message = "slams open, revealing out a hivebot!"
end_create_message = "slams open, revealing a hivebot!"
recharge_sound = null
recharge_message = null
/obj/machinery/droneDispenser/swarmer
name = "swarmer fabricator"
desc = "An alien machine of unknown origin. \
It whirs and hums with green-blue light, the air above it shimmering."
desc = "An alien machine of unknown origin. It whirs and hums with green-blue light, the air above it shimmering."
icon = 'icons/obj/machines/gateway.dmi'
icon_state = "toffcenter"
icon_off = "toffcenter"
@@ -129,10 +120,8 @@
cooldownTime = 300 //30 seconds
maximum_idle = 0 // Swarmers have no restraint
dispense_type = /obj/effect/mob_spawn/swarmer
begin_create_message = "hums softly as an interface appears above it, \
scrolling by at unreadable speed."
end_create_message = "materializes a strange shell, which drops to the \
ground."
begin_create_message = "hums softly as an interface appears above it, scrolling by at unreadable speed."
end_create_message = "materializes a strange shell, which drops to the ground."
recharging_text = "Its lights are slowly increasing in brightness."
work_sound = 'sound/effects/empulse.ogg'
create_sound = 'sound/effects/phasein.ogg'
@@ -171,8 +160,7 @@
if(maximum_idle && (count_shells() >= maximum_idle))
return // then do nothing; check again next tick
if(begin_create_message)
visible_message("<span class='notice'>\
[src] [begin_create_message]</span>")
visible_message("<span class='notice'>[src] [begin_create_message]</span>")
if(work_sound)
playsound(src, work_sound, 50, 1)
mode = DRONE_PRODUCTION
@@ -190,8 +178,7 @@
if(create_sound)
playsound(src, create_sound, 50, 1)
if(end_create_message)
visible_message("<span class='notice'>[src] \
[end_create_message]</span>")
visible_message("<span class='notice'>[src] [end_create_message]</span>")
mode = DRONE_RECHARGING
timer = world.time + cooldownTime
@@ -201,8 +188,7 @@
if(recharge_sound)
playsound(src, recharge_sound, 50, 1)
if(recharge_message)
visible_message("<span class='notice'>\
[src] [recharge_message]</span>")
visible_message("<span class='notice'>[src] [recharge_message]</span>")
mode = DRONE_READY
update_icon()
@@ -246,10 +232,8 @@
playsound(src, WT.usesound, 50, 1)
user.visible_message(
"<span class='notice'>[user] begins patching up \
[src] with [WT].</span>",
"<span class='notice'>You begin restoring the \
damage to [src]...</span>")
"<span class='notice'>[user] begins patching up [src] with [WT].</span>",
"<span class='notice'>You begin restoring the damage to [src]...</span>")
if(!do_after(user, 40*O.toolspeed, target = src))
return
@@ -270,8 +254,7 @@
if(!(flags_1 & NODECONSTRUCT_1))
if(!(stat & BROKEN))
if(break_message)
audible_message("<span class='warning'>[src] \
[break_message]</span>")
audible_message("<span class='warning'>[src] [break_message]</span>")
if(break_sound)
playsound(src, break_sound, 50, 1)
stat |= BROKEN
+31 -4
View File
@@ -123,10 +123,37 @@
/obj/machinery/status_display/examine(mob/user)
. = ..()
switch(mode)
if(1,2,4,5)
to_chat(user, "The display says:<br>\t<xmp>[message1]</xmp><br>\t<xmp>[message2]</xmp>")
if(mode == 1 && SSshuttle.emergency)
to_chat(user, "Current Shuttle: [SSshuttle.emergency.name]")
if(1,5) // Emergency or generic shuttle
var/obj/docking_port/mobile/shuttle
if(mode == 1)
shuttle = SSshuttle.emergency
else
shuttle = SSshuttle.getShuttle(shuttle_id)
if (!shuttle)
to_chat(user, "The display says:<br>\t<xmp>Shuttle?</xmp>")
else if (shuttle.timer)
to_chat(user, "The display says:<br>\t<xmp>[shuttle.getModeStr()]: [shuttle.getTimerStr()]</xmp>")
if (mode == 1 && shuttle)
to_chat(user, "Current shuttle: [shuttle.name].")
if(4) // Supply shuttle
var/obj/docking_port/mobile/shuttle = SSshuttle.supply
var/shuttleMsg = null
if (shuttle.mode == SHUTTLE_IDLE)
if (shuttle.z in GLOB.station_z_levels)
shuttleMsg = "Docked"
else
shuttleMsg = "[shuttle.getModeStr()]: [shuttle.getTimerStr()]"
if (shuttleMsg)
to_chat(user, "The display says:<br>\t<xmp>[shuttleMsg]</xmp>")
if(2) // Custom message
if (message1 || message2)
var/msg = "The display says:"
if (message1)
msg += "<br>\t<xmp>[message1]</xmp>"
if (message2)
msg += "<br>\t<xmp>[message2]</xmp>"
to_chat(user, msg)
/obj/machinery/status_display/proc/set_message(m1, m2)
+1 -1
View File
@@ -276,7 +276,7 @@
if(equipment && equipment.len)
to_chat(user, "It's equipped with:")
for(var/obj/item/mecha_parts/mecha_equipment/ME in equipment)
to_chat(user, "[icon2html(ME, user)] [ME]")
to_chat(user, "[icon2html(ME, user)] \A [ME].")
//processing internal damage, temperature, air regulation, alert updates, lights power use.
/obj/mecha/process()
+1 -1
View File
@@ -20,7 +20,7 @@
/obj/effect/countdown/examine(mob/user)
. = ..()
to_chat(user, "This countdown is displaying: [displayed_text]")
to_chat(user, "This countdown is displaying: [displayed_text].")
/obj/effect/countdown/proc/attach(atom/A)
attached_to = A
@@ -174,7 +174,7 @@
. += "You recognise the footprints as belonging to:\n"
for(var/shoe in shoe_types)
var/obj/item/clothing/shoes/S = shoe
. += "some <B>[initial(S.name)]</B> [icon2html(initial(S.icon), user)]\n"
. += "[icon2html(initial(S.icon), user)] Some <B>[initial(S.name)]</B>.\n"
to_chat(user, .)
+2 -1
View File
@@ -36,7 +36,8 @@
/obj/item/bodybag/bluespace/examine(mob/user)
..()
if(contents.len)
to_chat(user, "<span class='notice'>You can make out the shapes of [contents.len] objects through the fabric.</span>")
var/s = contents.len == 1 ? "" : "s"
to_chat(user, "<span class='notice'>You can make out the shape[s] of [contents.len] object[s] through the fabric.</span>")
/obj/item/bodybag/bluespace/Destroy()
for(var/atom/movable/A in contents)
+1 -1
View File
@@ -549,7 +549,7 @@
/obj/item/toy/crayon/spraycan/examine(mob/user)
. = ..()
if(charges_left)
to_chat(user, "It has [charges_left] uses left.")
to_chat(user, "It has [charges_left] use\s left.")
else
to_chat(user, "It is empty.")
@@ -512,9 +512,9 @@
/obj/item/device/radio/examine(mob/user)
..()
if (b_stat)
to_chat(user, "<span class='notice'>[name] can be attached and modified.</span>")
to_chat(user, "<span class='notice'>It can be attached and modified.</span>")
else
to_chat(user, "<span class='notice'>[name] can not be modified or attached.</span>")
to_chat(user, "<span class='notice'>It cannot be modified or attached.</span>")
/obj/item/device/radio/attackby(obj/item/W, mob/user, params)
add_fingerprint(user)
+1 -1
View File
@@ -68,7 +68,7 @@
/obj/item/extinguisher/examine(mob/user)
..()
if(reagents.total_volume)
to_chat(user, "It contains [round(reagents.total_volume)] units.")
to_chat(user, "It contains [round(reagents.total_volume)] unit\s.")
to_chat(user, "<span class='notice'>Alt-click to empty it.</span>")
else
to_chat(user, "It is empty.")
+1 -1
View File
@@ -144,7 +144,7 @@
/obj/item/flamethrower/examine(mob/user)
..()
if(ptank)
to_chat(user, "<span class='notice'>\The [src] has \the [ptank] attached. Alt-click to remove it.</span>")
to_chat(user, "<span class='notice'>\The [src] has \a [ptank] attached. Alt-click to remove it.</span>")
/obj/item/flamethrower/proc/toggle_igniter(mob/user)
if(!ptank)
+16 -13
View File
@@ -48,15 +48,15 @@
/obj/item/inducer/proc/cantbeused(mob/user)
if(!user.IsAdvancedToolUser())
to_chat(user, "<span class='warning'>You don't have the dexterity to use \the [src]!</span>")
to_chat(user, "<span class='warning'>You don't have the dexterity to use [src]!</span>")
return TRUE
if(!cell)
to_chat(user, "<span class='warning'>\The [src] doesn't have a power cell installed!</span>")
to_chat(user, "<span class='warning'>[src] doesn't have a power cell installed!</span>")
return TRUE
if(!cell.charge)
to_chat(user, "<span class='warning'>\The [src]'s battery is dead!</span>")
to_chat(user, "<span class='warning'>[src]'s battery is dead!</span>")
return TRUE
return FALSE
@@ -79,12 +79,12 @@
if(!cell)
if(!user.transferItemToLoc(W, src))
return
to_chat(user, "<span class='notice'>You insert \the [W] into \the [src].</span>")
to_chat(user, "<span class='notice'>You insert [W] into [src].</span>")
cell = W
update_icon()
return
else
to_chat(user, "<span class='notice'>\The [src] already has \a [cell] installed!</span>")
to_chat(user, "<span class='notice'>[src] already has \a [cell] installed!</span>")
return
if(cantbeused(user))
@@ -110,15 +110,17 @@
if(istype(A, /obj))
O = A
if(C)
var/done_any = FALSE
if(C.charge >= C.maxcharge)
to_chat(user, "<span class='notice'>\The [A] is fully charged!</span>")
to_chat(user, "<span class='notice'>[A] is fully charged!</span>")
recharging = FALSE
return TRUE
user.visible_message("[user] starts recharging \the [A] with \the [src]","<span class='notice'>You start recharging [A] with \the [src]</span>")
user.visible_message("[user] starts recharging [A] with [src].","<span class='notice'>You start recharging [A] with [src].</span>")
while(C.charge < C.maxcharge)
if(E)
E.chambered = null // Prevents someone from firing continuously while recharging the gun.
if(do_after(user, 10, target = user) && cell.charge)
done_any = TRUE
induce(C, coefficient)
do_sparks(1, FALSE, A)
if(O)
@@ -127,7 +129,8 @@
break
if(E)
E.recharge_newshot() //We're done charging, so we'll let someone fire it now.
user.visible_message("[user] recharged \the [A]!","<span class='notice'>You recharged \the [A]!</span>")
if(done_any) // Only show a message if we succeeded at least once
user.visible_message("[user] recharged [A]!","<span class='notice'>You recharged [A]!</span>")
recharging = FALSE
return TRUE
recharging = FALSE
@@ -147,7 +150,7 @@
/obj/item/inducer/attack_self(mob/user)
if(opened && cell)
user.visible_message("[user] removes \the [cell] from \the [src]!","<span class='notice'>You remove \the [cell].</span>")
user.visible_message("[user] removes [cell] from [src]!","<span class='notice'>You remove [cell].</span>")
cell.update_icon()
user.put_in_hands(cell)
cell = null
@@ -157,11 +160,11 @@
/obj/item/inducer/examine(mob/living/M)
..()
if(cell)
to_chat(M, "<span class='notice'>It's display shows: [DisplayPower(cell.charge)]</span>")
to_chat(M, "<span class='notice'>Its display shows: [DisplayPower(cell.charge)].</span>")
else
to_chat(M,"<span class='notice'>It's display is dark.</span>")
to_chat(M,"<span class='notice'>Its display is dark.</span>")
if(opened)
to_chat(M,"<span class='notice'>It's battery compartment is open.</span>")
to_chat(M,"<span class='notice'>Its battery compartment is open.</span>")
/obj/item/inducer/update_icon()
cut_overlays()
@@ -174,7 +177,7 @@
/obj/item/inducer/sci
icon_state = "inducer-sci"
item_state = "inducer-sci"
desc = "A tool for inductively charging internal power cells. This one has a science color scheme, and is less potent than it's engineering counterpart."
desc = "A tool for inductively charging internal power cells. This one has a science color scheme, and is less potent than its engineering counterpart."
cell_type = null
powertransfer = 500
opened = TRUE
+2 -2
View File
@@ -38,10 +38,10 @@
out += "<span class='notice'>You'll need to get closer to see any more.</span>"
return
for(var/obj/item/I in loadedItems)
out += "<span class='info'>[icon2html(I, user)] It has \the [I] loaded.</span>"
out += "<span class='info'>[icon2html(I, user)] It has \a [I] loaded.</span>"
CHECK_TICK
if(tank)
out += "<span class='notice'>[icon2html(tank, user)] It has \the [tank] mounted onto it.</span>"
out += "<span class='notice'>[icon2html(tank, user)] It has \a [tank] mounted onto it.</span>"
to_chat(user, out.Join("<br>"))
/obj/item/pneumatic_cannon/attackby(obj/item/W, mob/user, params)
+1 -1
View File
@@ -26,7 +26,7 @@
to_chat(user, "<span class='notice'>You'll need to get closer to see any more.</span>")
return
if(tank)
to_chat(user, "<span class='notice'>[icon2html(tank, user)] It has \the [tank] mounted onto it.</span>")
to_chat(user, "<span class='notice'>[icon2html(tank, user)] It has \a [tank] mounted onto it.</span>")
/obj/item/melee/powerfist/attackby(obj/item/W, mob/user, params)
+1 -1
View File
@@ -840,7 +840,7 @@
if(ishuman(user))
var/mob/living/carbon/human/cardUser = user
if(cardUser.is_holding(src))
cardUser.visible_message("[cardUser] checks [cardUser.p_their()] card.", "<span class='notice'>The card reads: [cardname]</span>")
cardUser.visible_message("[cardUser] checks [cardUser.p_their()] card.", "<span class='notice'>The card reads: [cardname].</span>")
else
to_chat(cardUser, "<span class='warning'>You need to have the card in your hand to check it!</span>")
@@ -144,7 +144,7 @@
/obj/item/roller/robo/examine(mob/user)
..()
to_chat(user, "The dock is [loaded ? "loaded" : "empty"]")
to_chat(user, "The dock is [loaded ? "loaded" : "empty"].")
/obj/item/roller/robo/deploy_roller(mob/user, atom/location)
if(loaded)