mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-07-20 11:35:19 +01:00
refactors most spans
This commit is contained in:
@@ -54,20 +54,20 @@
|
||||
if(!glass)
|
||||
playsound(src, I.usesound, 50, 1)
|
||||
if(do_after(user, 20 * I.toolspeed))
|
||||
to_chat(user, "<span class='notice'>You unfasten the frame.</span>")
|
||||
to_chat(user, span_notice("You unfasten the frame."))
|
||||
new /obj/item/frame/mirror( src.loc )
|
||||
qdel(src)
|
||||
return
|
||||
if(I.has_tool_quality(TOOL_WRENCH))
|
||||
if(shattered && glass)
|
||||
to_chat(user, "<span class='notice'>The broken glass falls out.</span>")
|
||||
to_chat(user, span_notice("The broken glass falls out."))
|
||||
icon_state = "mirror_frame"
|
||||
glass = !glass
|
||||
new /obj/item/material/shard( src.loc )
|
||||
return
|
||||
if(!shattered && glass)
|
||||
playsound(src, I.usesound, 50, 1)
|
||||
to_chat(user, "<span class='notice'>You remove the glass.</span>")
|
||||
to_chat(user, span_notice("You remove the glass."))
|
||||
glass = !glass
|
||||
icon_state = "mirror_frame"
|
||||
new /obj/item/stack/material/glass( src.loc, 2 )
|
||||
@@ -77,15 +77,15 @@
|
||||
if(!glass)
|
||||
var/obj/item/stack/material/glass/G = I
|
||||
if (G.get_amount() < 2)
|
||||
to_chat(user, "<span class='warning'>You need two sheets of glass to add them to the frame.</span>")
|
||||
to_chat(user, span_warning("You need two sheets of glass to add them to the frame."))
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You start to add the glass to the frame.</span>")
|
||||
to_chat(user, span_notice("You start to add the glass to the frame."))
|
||||
if(do_after(user, 20))
|
||||
if (G.use(2))
|
||||
shattered = 0
|
||||
glass = 1
|
||||
icon_state = "mirror"
|
||||
to_chat(user, "<span class='notice'>You add the glass to the frame.</span>")
|
||||
to_chat(user, span_notice("You add the glass to the frame."))
|
||||
return
|
||||
|
||||
if(shattered && glass)
|
||||
@@ -93,11 +93,11 @@
|
||||
return
|
||||
|
||||
if(prob(I.force * 2))
|
||||
visible_message("<span class='warning'>[user] smashes [src] with [I]!</span>")
|
||||
visible_message(span_warning("[user] smashes [src] with [I]!"))
|
||||
if(glass)
|
||||
shatter()
|
||||
else
|
||||
visible_message("<span class='warning'>[user] hits [src] with [I]!</span>")
|
||||
visible_message(span_warning("[user] hits [src] with [I]!"))
|
||||
playsound(src, 'sound/effects/Glasshit.ogg', 70, 1)
|
||||
|
||||
/obj/structure/mirror/attack_generic(var/mob/user, var/damage)
|
||||
@@ -108,11 +108,11 @@
|
||||
return 0
|
||||
|
||||
if(damage)
|
||||
user.visible_message("<span class='danger'>[user] smashes [src]!</span>")
|
||||
user.visible_message(span_danger("[user] smashes [src]!"))
|
||||
if(glass)
|
||||
shatter()
|
||||
else
|
||||
user.visible_message("<span class='danger'>[user] hits [src] and bounces off!</span>")
|
||||
user.visible_message(span_danger("[user] hits [src] and bounces off!"))
|
||||
return 1
|
||||
|
||||
// The following mirror is ~special~.
|
||||
@@ -141,4 +141,4 @@
|
||||
vox.name = vox.real_name
|
||||
raiders.update_access(vox)
|
||||
qdel(user)
|
||||
..()
|
||||
..()
|
||||
|
||||
Reference in New Issue
Block a user