Updates macro/span use.

This commit is contained in:
PsiOmegaDelta
2015-12-02 09:16:04 +01:00
committed by Jon
parent 7ef07aeca6
commit ba423361bd
3 changed files with 65 additions and 65 deletions

View File

@@ -45,7 +45,7 @@
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\red [user] rips the larva out of [target]'s ribcage!",
user.visible_message("<span class='warning'>[user] rips the larva out of [target]'s ribcage!</span>",
"You rip the larva out of [target]'s ribcage!")
for(var/obj/item/alien_embryo/A in target)
@@ -112,8 +112,8 @@
for(var/obj/item/organ/I in affected.internal_organs)
if(I && I.damage > 0)
if(I.robotic < 2)
user.visible_message("\blue [user] treats damage to [target]'s [I.name] with [tool_name].", \
"\blue You treat damage to [target]'s [I.name] with [tool_name]." )
user.visible_message("<span class='notice'>[user] treats damage to [target]'s [I.name] with [tool_name].</span>", \
"<span class='notice'>You treat damage to [target]'s [I.name] with [tool_name].</span>" )
I.damage = 0
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
@@ -122,8 +122,8 @@
return
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s hand slips, getting mess and tearing the inside of [target]'s [affected.name] with \the [tool]!", \
"\red Your hand slips, getting mess and tearing the inside of [target]'s [affected.name] with \the [tool]!")
user.visible_message("<span class='warning'>[user]'s hand slips, getting mess and tearing the inside of [target]'s [affected.name] with \the [tool]!</span>", \
"<span class='warning'>Your hand slips, getting mess and tearing the inside of [target]'s [affected.name] with \the [tool]!</span>")
var/dam_amt = 2
if (istype(tool, /obj/item/stack/medical/advanced/bruise_pack))
@@ -185,8 +185,8 @@
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\blue [user] has separated [target]'s [target.op_stage.current_organ] with \the [tool]." , \
"\blue You have separated [target]'s [target.op_stage.current_organ] with \the [tool].")
user.visible_message("<span class='notice'>[user] has separated [target]'s [target.op_stage.current_organ] with \the [tool].</span>" , \
"<span class='notice'>You have separated [target]'s [target.op_stage.current_organ] with \the [tool].</span>")
var/obj/item/organ/I = target.internal_organs_by_name[target.op_stage.current_organ]
if(I && istype(I))
@@ -194,8 +194,8 @@
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s hand slips, slicing an artery inside [target]'s [affected.name] with \the [tool]!", \
"\red Your hand slips, slicing an artery inside [target]'s [affected.name] with \the [tool]!")
user.visible_message("<span class='warning'>[user]'s hand slips, slicing an artery inside [target]'s [affected.name] with \the [tool]!</span>", \
"<span class='warning'>Your hand slips, slicing an artery inside [target]'s [affected.name] with \the [tool]!</span>")
affected.createwound(CUT, rand(30,50), 1)
/datum/surgery_step/internal/remove_organ
@@ -236,8 +236,8 @@
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\blue [user] has removed [target]'s [target.op_stage.current_organ] with \the [tool].", \
"\blue You have removed [target]'s [target.op_stage.current_organ] with \the [tool].")
user.visible_message("<span class='notice'>[user] has removed [target]'s [target.op_stage.current_organ] with \the [tool].</span>", \
"<span class='notice'>You have removed [target]'s [target.op_stage.current_organ] with \the [tool].</span>")
// Extract the organ!
if(target.op_stage.current_organ)
@@ -248,8 +248,8 @@
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s hand slips, damaging [target]'s [affected.name] with \the [tool]!", \
"\red Your hand slips, damaging [target]'s [affected.name] with \the [tool]!")
user.visible_message("<span class='warning'>[user]'s hand slips, damaging [target]'s [affected.name] with \the [tool]!</span>", \
"<span class='warning'>Your hand slips, damaging [target]'s [affected.name] with \the [tool]!</span>")
affected.createwound(BRUISE, 20)
/datum/surgery_step/internal/replace_organ
@@ -276,7 +276,7 @@
return SURGERY_FAILURE
if(!target.species)
user << "\red You have no idea what species this person is. Report this on the bug tracker."
user << "<span class='danger'>You have no idea what species this person is. Report this on the bug tracker.</span>"
return SURGERY_FAILURE
var/o_is = (O.gender == PLURAL) ? "are" : "is"
@@ -288,22 +288,22 @@
else if(target.species.has_organ[O.organ_tag])
if(O.damage > (O.max_damage * 0.75))
user << "\red \The [O.organ_tag] [o_is] in no state to be transplanted."
user << "<span class='warning'>\The [O.organ_tag] [o_is] in no state to be transplanted.</span>"
return SURGERY_FAILURE
if(!target.internal_organs_by_name[O.organ_tag])
organ_missing = 1
else
user << "\red \The [target] already has [o_a][O.organ_tag]."
user << "<span class='warning'>\The [target] already has [o_a][O.organ_tag].</span>"
return SURGERY_FAILURE
if(O && affected.limb_name == O.parent_organ)
organ_compatible = 1
else
user << "\red \The [O.organ_tag] [o_do] normally go in \the [affected.name]."
user << "<span class='warning'>\The [O.organ_tag] [o_do] normally go in \the [affected.name].</span>"
return SURGERY_FAILURE
else
user << "\red You're pretty sure [target.species.name_plural] don't normally have [o_a][O.organ_tag]."
user << "<span class='warning'>You're pretty sure [target.species.name_plural] don't normally have [o_a][O.organ_tag].</span>"
return SURGERY_FAILURE
return ..() && organ_missing && organ_compatible
@@ -317,16 +317,16 @@
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] has transplanted \the [tool] into [target]'s [affected.name].", \
"\blue You have transplanted \the [tool] into [target]'s [affected.name].")
user.visible_message("<span class='notice'>[user] has transplanted \the [tool] into [target]'s [affected.name].</span>", \
"<span class='notice'>You have transplanted \the [tool] into [target]'s [affected.name].</span>")
var/obj/item/organ/O = tool
if(istype(O))
user.remove_from_mob(O)
O.replaced(target,affected)
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\red [user]'s hand slips, damaging \the [tool]!", \
"\red Your hand slips, damaging \the [tool]!")
user.visible_message("<span class='warning'>[user]'s hand slips, damaging \the [tool]!</span>", \
"<span class='warning'>Your hand slips, damaging \the [tool]!</span>")
var/obj/item/organ/I = tool
if(istype(I))
I.take_damage(rand(3,5),0)
@@ -367,8 +367,8 @@
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\blue [user] has reattached [target]'s [target.op_stage.current_organ] with \the [tool]." , \
"\blue You have reattached [target]'s [target.op_stage.current_organ] with \the [tool].")
user.visible_message("<span class='notice'>[user] has reattached [target]'s [target.op_stage.current_organ] with \the [tool].</span>" , \
"<span class='notice'>You have reattached [target]'s [target.op_stage.current_organ] with \the [tool].</span>")
var/obj/item/organ/I = target.internal_organs_by_name[target.op_stage.current_organ]
if(I && istype(I))
@@ -376,8 +376,8 @@
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s hand slips, damaging the flesh in [target]'s [affected.name] with \the [tool]!", \
"\red Your hand slips, damaging the flesh in [target]'s [affected.name] with \the [tool]!")
user.visible_message("<span class='warning'>[user]'s hand slips, damaging the flesh in [target]'s [affected.name] with \the [tool]!</span>", \
"<span class='warning'>Your hand slips, damaging the flesh in [target]'s [affected.name] with \the [tool]!</span>")
affected.createwound(BRUISE, 20)
//////////////////////////////////////////////////////////////////

View File

@@ -44,14 +44,14 @@
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] has opened the maintenance hatch on [target]'s [affected.name] with \the [tool].", \
"\blue You have opened the maintenance hatch on [target]'s [affected.name] with \the [tool].",)
user.visible_message("<span class='notice'>[user] has opened the maintenance hatch on [target]'s [affected.name] with \the [tool].</span>", \
"<span class='notice'>You have opened the maintenance hatch on [target]'s [affected.name] with \the [tool].</span>",)
affected.open = 1
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s [tool.name] slips, failing to unscrew [target]'s [affected.name].", \
"\red Your [tool] slips, failing to unscrew [target]'s [affected.name].")
user.visible_message("<span class='warning'>[user]'s [tool.name] slips, failing to unscrew [target]'s [affected.name].</span>", \
"<span class='warning'>Your [tool] slips, failing to unscrew [target]'s [affected.name].</span>")
/datum/surgery_step/robotics/open_hatch
allowed_tools = list(
@@ -76,14 +76,14 @@
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] opens the maintenance hatch on [target]'s [affected.name] with \the [tool].", \
"\blue You open the maintenance hatch on [target]'s [affected.name] with \the [tool]." )
user.visible_message("<span class='notice'>[user] opens the maintenance hatch on [target]'s [affected.name] with \the [tool].</span>", \
"<span class='notice'>You open the maintenance hatch on [target]'s [affected.name] with \the [tool].</span>")
affected.open = 2
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s [tool.name] slips, failing to open the hatch on [target]'s [affected.name].",
"\red Your [tool] slips, failing to open the hatch on [target]'s [affected.name].")
user.visible_message("<span class='warning'>[user]'s [tool.name] slips, failing to open the hatch on [target]'s [affected.name].</span>",
"<span class='warning'>Your [tool] slips, failing to open the hatch on [target]'s [affected.name].</span>")
/datum/surgery_step/robotics/close_hatch
allowed_tools = list(
@@ -108,15 +108,15 @@
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] closes and secures the hatch on [target]'s [affected.name] with \the [tool].", \
"\blue You close and secure the hatch on [target]'s [affected.name] with \the [tool].")
user.visible_message("<span class='notice'>[user] closes and secures the hatch on [target]'s [affected.name] with \the [tool].</span>", \
"<span class='notice'>You close and secure the hatch on [target]'s [affected.name] with \the [tool].</span>")
affected.open = 0
affected.germ_level = 0
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s [tool.name] slips, failing to close the hatch on [target]'s [affected.name].",
"\red Your [tool.name] slips, failing to close the hatch on [target]'s [affected.name].")
user.visible_message("<span class='warning'>[user]'s [tool.name] slips, failing to close the hatch on [target]'s [affected.name].</span>",
"<span class='warning'>Your [tool.name] slips, failing to close the hatch on [target]'s [affected.name].</span>")
/datum/surgery_step/robotics/repair_brute
allowed_tools = list(
@@ -144,14 +144,14 @@
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] finishes patching damage to [target]'s [affected.name] with \the [tool].", \
"\blue You finish patching damage to [target]'s [affected.name] with \the [tool].")
user.visible_message("<span class='notice'>[user] finishes patching damage to [target]'s [affected.name] with \the [tool].</span>", \
"<span class='notice'>You finish patching damage to [target]'s [affected.name] with \the [tool].</span>")
affected.heal_damage(rand(30,50),0,1,1)
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s [tool.name] slips, damaging the internal structure of [target]'s [affected.name].",
"\red Your [tool.name] slips, damaging the internal structure of [target]'s [affected.name].")
user.visible_message("<span class='warning'>[user]'s [tool.name] slips, damaging the internal structure of [target]'s [affected.name].</span>",
"<span class='warning'>Your [tool.name] slips, damaging the internal structure of [target]'s [affected.name].</span>")
target.apply_damage(rand(5,10), BURN, affected)
/datum/surgery_step/robotics/repair_burn
@@ -184,14 +184,14 @@
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] finishes splicing cable into [target]'s [affected.name].", \
"\blue You finishes splicing new cable into [target]'s [affected.name].")
user.visible_message("<span class='notice'>[user] finishes splicing cable into [target]'s [affected.name].</span>", \
"<span class='notice'>You finishes splicing new cable into [target]'s [affected.name].</span>")
affected.heal_damage(0,rand(30,50),1,1)
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user] causes a short circuit in [target]'s [affected.name]!",
"\red You cause a short circuit in [target]'s [affected.name]!")
user.visible_message("<span class='warning'>[user] causes a short circuit in [target]'s [affected.name]!</span>",
"<span class='warning'>You cause a short circuit in [target]'s [affected.name]!</span>")
target.apply_damage(rand(5,10), BURN, affected)
/datum/surgery_step/robotics/fix_organ_robotic //For artificial organs
@@ -242,8 +242,8 @@
if(I && I.damage > 0)
if(I.robotic >= 2)
user.visible_message("\blue [user] repairs [target]'s [I.name] with [tool].", \
"\blue You repair [target]'s [I.name] with [tool]." )
user.visible_message("<span class='notice'>[user] repairs [target]'s [I.name] with [tool].</span>", \
"<span class='notice'>You repair [target]'s [I.name] with [tool].</span>" )
I.damage = 0
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
@@ -252,8 +252,8 @@
return
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\red [user]'s hand slips, gumming up the mechanisms inside of [target]'s [affected.name] with \the [tool]!", \
"\red Your hand slips, gumming up the mechanisms inside of [target]'s [affected.name] with \the [tool]!")
user.visible_message("<span class='warning'>[user]'s hand slips, gumming up the mechanisms inside of [target]'s [affected.name] with \the [tool]!</span>", \
"<span class='warning'>Your hand slips, gumming up the mechanisms inside of [target]'s [affected.name] with \the [tool]!</span>")
target.adjustToxLoss(5)
affected.createwound(CUT, 5)
@@ -301,16 +301,16 @@
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\blue [user] has decoupled [target]'s [target.op_stage.current_organ] with \the [tool]." , \
"\blue You have decoupled [target]'s [target.op_stage.current_organ] with \the [tool].")
user.visible_message("<span class='notice'>[user] has decoupled [target]'s [target.op_stage.current_organ] with \the [tool].</span>" , \
"<span class='notice'>You have decoupled [target]'s [target.op_stage.current_organ] with \the [tool].</span>")
var/obj/item/organ/I = target.internal_organs_by_name[target.op_stage.current_organ]
if(I && istype(I))
I.status |= ORGAN_CUT_AWAY
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\red [user]'s hand slips, disconnecting \the [tool].", \
"\red Your hand slips, disconnecting \the [tool].")
user.visible_message("<span class='warning'>[user]'s hand slips, disconnecting \the [tool].</span>", \
"<span class='warning'>Your hand slips, disconnecting \the [tool].</span>")
/datum/surgery_step/robotics/attach_organ_robotic
allowed_tools = list(
@@ -349,16 +349,16 @@
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\blue [user] has reattached [target]'s [target.op_stage.current_organ] with \the [tool]." , \
"\blue You have reattached [target]'s [target.op_stage.current_organ] with \the [tool].")
user.visible_message("<span class='notice'>[user] has reattached [target]'s [target.op_stage.current_organ] with \the [tool].</span>" , \
"<span class='notice'>You have reattached [target]'s [target.op_stage.current_organ] with \the [tool].</span>")
var/obj/item/organ/I = target.internal_organs_by_name[target.op_stage.current_organ]
if(I && istype(I))
I.status &= ~ORGAN_CUT_AWAY
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\red [user]'s hand slips, disconnecting \the [tool].", \
"\red Your hand slips, disconnecting \the [tool].")
user.visible_message("<span class='warning'>[user]'s hand slips, disconnecting \the [tool].</span>", \
"<span class='warning'>Your hand slips, disconnecting \the [tool].</span>")
/datum/surgery_step/robotics/install_mmi
allowed_tools = list(
@@ -411,8 +411,8 @@
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] has installed \the [tool] into [target]'s [affected.name].", \
"\blue You have installed \the [tool] into [target]'s [affected.name].")
user.visible_message("<span class='notice'>[user] has installed \the [tool] into [target]'s [affected.name].</span>", \
"<span class='notice'>You have installed \the [tool] into [target]'s [affected.name].</span>")
var/obj/item/device/mmi/M = tool
var/obj/item/organ/mmi_holder/holder = new(target, 1)
@@ -426,5 +426,5 @@
M.brainmob.mind.transfer_to(target)
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\red [user]'s hand slips.", \
"\red Your hand slips.")
user.visible_message("<span class='warning'>[user]'s hand slips.</span>", \
"<span class='warning'>Your hand slips.</span>")

View File

@@ -84,7 +84,7 @@ proc/do_surgery(mob/living/carbon/M, mob/living/user, obj/item/tool)
return 0
var/zone = user.zone_sel.selecting
if(zone in M.op_stage.in_progress) //Can't operate on someone repeatedly.
user << "\red You can't operate on this area while surgery is already in progress."
user << "<span class='warning'>You can't operate on this area while surgery is already in progress.</span>"
return 1
for(var/datum/surgery_step/S in surgery_steps)
//check if tool is right or close enough and if this step is possible
@@ -101,7 +101,7 @@ proc/do_surgery(mob/living/carbon/M, mob/living/user, obj/item/tool)
else if ((tool in user.contents) && user.Adjacent(M)) //or
S.fail_step(user, M, zone, tool) //malpractice~
else // This failing silently was a pain.
user << "\red You must remain close to your patient to conduct surgery."
user << "<span class='warning'>You must remain close to your patient to conduct surgery.</span>"
M.op_stage.in_progress -= zone // Clear the in-progress flag.
if (ishuman(M))
var/mob/living/carbon/human/H = M
@@ -109,7 +109,7 @@ proc/do_surgery(mob/living/carbon/M, mob/living/user, obj/item/tool)
return 1 //don't want to do weapony things after surgery
if (user.a_intent == I_HELP)
user << "\red You can't see any useful way to use [tool] on [M]."
user << "<span class='warning'>You can't see any useful way to use [tool] on [M].</span>"
return 1
return 0