Merge branch 'master' of https://github.com/Citadel-Station-13/Citadel-Station-13 into sabre-noise
This commit is contained in:
@@ -517,16 +517,17 @@ update_label("John Doe", "Clowny")
|
||||
return
|
||||
if(user.incapacitated() || !istype(user))
|
||||
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
return TRUE
|
||||
if(alert("Are you sure you want to recolor your id?", "Confirm Repaint", "Yes", "No") == "Yes")
|
||||
var/energy_color_input = input(usr,"","Choose Energy Color",id_color) as color|null
|
||||
if(!in_range(src, user) || !energy_color_input)
|
||||
return
|
||||
return TRUE
|
||||
if(user.incapacitated() || !istype(user))
|
||||
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
return TRUE
|
||||
id_color = sanitize_hexcolor(energy_color_input, desired_format=6, include_crunch=1)
|
||||
update_icon()
|
||||
return TRUE
|
||||
|
||||
/obj/item/card/id/knight/Initialize()
|
||||
. = ..()
|
||||
|
||||
@@ -945,10 +945,12 @@
|
||||
to_chat(user, "<span class='notice'>You [suction ? "enable" : "disable"] the board's suction function.</span>")
|
||||
|
||||
/obj/item/circuitboard/machine/dish_drive/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!user.Adjacent(src))
|
||||
return
|
||||
transmit = !transmit
|
||||
to_chat(user, "<span class='notice'>You [transmit ? "enable" : "disable"] the board's automatic disposal transmission.</span>")
|
||||
return TRUE
|
||||
|
||||
/obj/item/circuitboard/machine/stacking_unit_console
|
||||
name = "Stacking Machine Console (Machine Board)"
|
||||
|
||||
@@ -150,11 +150,13 @@
|
||||
ui.open()
|
||||
|
||||
/obj/item/toy/crayon/spraycan/AltClick(mob/user)
|
||||
. = ..()
|
||||
if(user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
if(has_cap)
|
||||
is_capped = !is_capped
|
||||
to_chat(user, "<span class='notice'>The cap on [src] is now [is_capped ? "on" : "off"].</span>")
|
||||
update_icon()
|
||||
return TRUE
|
||||
|
||||
/obj/item/toy/crayon/proc/staticDrawables()
|
||||
|
||||
|
||||
@@ -828,14 +828,14 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
send_message(U,list(P))
|
||||
|
||||
/obj/item/pda/AltClick()
|
||||
..()
|
||||
|
||||
. = ..()
|
||||
if(id)
|
||||
remove_id()
|
||||
playsound(src, 'sound/machines/terminal_eject_disc.ogg', 50, 1)
|
||||
else
|
||||
remove_pen()
|
||||
playsound(src, 'sound/machines/button4.ogg', 50, 1)
|
||||
return TRUE
|
||||
|
||||
/obj/item/pda/CtrlClick()
|
||||
..()
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
. += "<span class='notice'>Can be used again to interrupt the effect early. The recharge time is the same as the time spent in desync.</span>"
|
||||
|
||||
/obj/item/desynchronizer/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
return
|
||||
var/new_duration = input(user, "Set the duration (5-300):", "Desynchronizer", duration / 10) as null|num
|
||||
@@ -40,6 +41,7 @@
|
||||
new_duration = CLAMP(new_duration, 50, max_duration)
|
||||
duration = new_duration
|
||||
to_chat(user, "<span class='notice'>You set the duration to [DisplayTimeText(duration)].</span>")
|
||||
return TRUE
|
||||
|
||||
/obj/item/desynchronizer/proc/desync(mob/living/user)
|
||||
if(sync_holder)
|
||||
|
||||
@@ -182,14 +182,16 @@
|
||||
return ..()
|
||||
|
||||
/obj/item/geiger_counter/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE))
|
||||
return ..()
|
||||
return
|
||||
if(!scanning)
|
||||
to_chat(usr, "<span class='warning'>[src] must be on to reset its radiation level!</span>")
|
||||
return 0
|
||||
return TRUE
|
||||
radiation_count = 0
|
||||
to_chat(usr, "<span class='notice'>You flush [src]'s radiation counts, resetting it to normal.</span>")
|
||||
update_icon()
|
||||
return TRUE
|
||||
|
||||
/obj/item/geiger_counter/emag_act(mob/user)
|
||||
. = ..()
|
||||
|
||||
@@ -45,9 +45,11 @@ GLOBAL_LIST_EMPTY(GPS_list)
|
||||
add_overlay("working")
|
||||
|
||||
/obj/item/gps/AltClick(mob/user)
|
||||
. = ..()
|
||||
if(!user.canUseTopic(src, BE_CLOSE))
|
||||
return
|
||||
toggletracking(user)
|
||||
return TRUE
|
||||
|
||||
/obj/item/gps/proc/toggletracking(mob/user)
|
||||
if(!user.canUseTopic(src, BE_CLOSE))
|
||||
|
||||
@@ -18,12 +18,14 @@
|
||||
. += "<span class='notice'>Insert [src] into an active quantum pad to link it.</span>"
|
||||
|
||||
/obj/item/quantum_keycard/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You start pressing [src]'s unlink button...</span>")
|
||||
if(do_after(user, 40, target = src))
|
||||
to_chat(user, "<span class='notice'>The keycard beeps twice and disconnects the quantum link.</span>")
|
||||
qpad = null
|
||||
return TRUE
|
||||
|
||||
/obj/item/quantum_keycard/update_icon()
|
||||
if(qpad)
|
||||
|
||||
@@ -326,8 +326,10 @@ GLOBAL_LIST_INIT(channel_tokens, list(
|
||||
secure_radio_connections[ch_name] = add_radio(src, GLOB.radiochannels[ch_name])
|
||||
|
||||
/obj/item/radio/headset/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!istype(user) || !Adjacent(user) || user.incapacitated())
|
||||
return
|
||||
if (command)
|
||||
use_command = !use_command
|
||||
to_chat(user, "<span class='notice'>You toggle high-volume mode [use_command ? "on" : "off"].</span>")
|
||||
return TRUE
|
||||
|
||||
@@ -590,10 +590,10 @@ SLIME SCANNER
|
||||
to_chat(user, "<span class='info'>Temperature: [round(environment.temperature-T0C, 0.01)] °C ([round(environment.temperature, 0.01)] K)</span>")
|
||||
|
||||
/obj/item/analyzer/AltClick(mob/user) //Barometer output for measuring when the next storm happens
|
||||
..()
|
||||
. = ..()
|
||||
|
||||
if(user.canUseTopic(src))
|
||||
|
||||
. = TRUE
|
||||
if(cooldown)
|
||||
to_chat(user, "<span class='warning'>[src]'s barometer function is preparing itself.</span>")
|
||||
return
|
||||
|
||||
@@ -138,11 +138,13 @@
|
||||
toggle_igniter(user)
|
||||
|
||||
/obj/item/flamethrower/AltClick(mob/user)
|
||||
. = ..()
|
||||
if(ptank && isliving(user) && user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
user.put_in_hands(ptank)
|
||||
ptank = null
|
||||
to_chat(user, "<span class='notice'>You remove the plasma tank from [src]!</span>")
|
||||
update_icon()
|
||||
return TRUE
|
||||
|
||||
/obj/item/flamethrower/examine(mob/user)
|
||||
. = ..()
|
||||
|
||||
@@ -320,11 +320,12 @@
|
||||
M.update_inv_hands()
|
||||
|
||||
/obj/item/melee/transforming/energy/sword/cx/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!in_range(src, user)) //Basic checks to prevent abuse
|
||||
return
|
||||
if(user.incapacitated() || !istype(user))
|
||||
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
return TRUE
|
||||
|
||||
if(alert("Are you sure you want to recolor your blade?", "Confirm Repaint", "Yes", "No") == "Yes")
|
||||
var/energy_color_input = input(usr,"","Choose Energy Color",light_color) as color|null
|
||||
@@ -332,6 +333,7 @@
|
||||
light_color = sanitize_hexcolor(energy_color_input, desired_format=6, include_crunch=1)
|
||||
update_icon()
|
||||
update_light()
|
||||
return TRUE
|
||||
|
||||
/obj/item/melee/transforming/energy/sword/cx/examine(mob/user)
|
||||
. = ..()
|
||||
|
||||
@@ -70,6 +70,7 @@
|
||||
update_icon()
|
||||
|
||||
/obj/item/pet_carrier/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(open || !user.canUseTopic(src, BE_CLOSE))
|
||||
return
|
||||
locked = !locked
|
||||
@@ -79,6 +80,7 @@
|
||||
else
|
||||
playsound(user, 'sound/machines/boltsup.ogg', 30, TRUE)
|
||||
update_icon()
|
||||
return TRUE
|
||||
|
||||
/obj/item/pet_carrier/attack(mob/living/target, mob/living/user)
|
||||
if(user.a_intent == INTENT_HARM)
|
||||
|
||||
@@ -350,6 +350,7 @@
|
||||
. = ..()
|
||||
|
||||
/obj/item/stack/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
return
|
||||
if(is_cyborg)
|
||||
@@ -363,10 +364,11 @@
|
||||
max = get_amount()
|
||||
stackmaterial = min(max, stackmaterial)
|
||||
if(stackmaterial == null || stackmaterial <= 0 || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
return
|
||||
return TRUE
|
||||
else
|
||||
change_stack(user, stackmaterial)
|
||||
to_chat(user, "<span class='notice'>You take [stackmaterial] sheets out of the stack</span>")
|
||||
return TRUE
|
||||
|
||||
/obj/item/stack/proc/change_stack(mob/user, amount)
|
||||
if(!use(amount, TRUE, FALSE))
|
||||
|
||||
@@ -757,23 +757,13 @@
|
||||
STR.rustle_sound = FALSE
|
||||
STR.max_w_class = WEIGHT_CLASS_BULKY
|
||||
STR.can_hold = typecacheof(fitting_swords)
|
||||
STR.quickdraw = TRUE
|
||||
|
||||
/obj/item/storage/belt/sabre/examine(mob/user)
|
||||
. = ..()
|
||||
if(length(contents))
|
||||
. += "<span class='notice'>Alt-click it to quickly draw the blade.</span>"
|
||||
|
||||
/obj/item/storage/belt/sabre/AltClick(mob/user)
|
||||
if(!iscarbon(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
return
|
||||
if(length(contents))
|
||||
var/obj/item/I = contents[1]
|
||||
user.visible_message("[user] takes [I] out of [src].", "<span class='notice'>You take [I] out of [src].</span>")
|
||||
user.put_in_hands(I)
|
||||
update_icon()
|
||||
else
|
||||
to_chat(user, "[src] is empty.")
|
||||
|
||||
/obj/item/storage/belt/sabre/update_icon()
|
||||
. = ..()
|
||||
if(isliving(loc))
|
||||
|
||||
@@ -157,6 +157,7 @@
|
||||
to_chat(user, "<span class='notice'>You take \a [W] out of the pack.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>There are no [icon_type]s left in the pack.</span>")
|
||||
return TRUE
|
||||
|
||||
/obj/item/storage/fancy/cigarettes/update_icon()
|
||||
if(fancy_open || !contents.len)
|
||||
|
||||
@@ -114,11 +114,12 @@
|
||||
. += "<span class='notice'>Alt-click to [open ? "close":"open"] it.</span>"
|
||||
|
||||
/obj/item/storage/lockbox/medal/AltClick(mob/user)
|
||||
. = ..()
|
||||
if(user.canUseTopic(src, BE_CLOSE))
|
||||
if(!SEND_SIGNAL(src, COMSIG_IS_STORAGE_LOCKED))
|
||||
open = (open ? FALSE : TRUE)
|
||||
update_icon()
|
||||
..()
|
||||
return TRUE
|
||||
|
||||
/obj/item/storage/lockbox/medal/PopulateContents()
|
||||
new /obj/item/clothing/accessory/medal/gold/captain(src)
|
||||
|
||||
@@ -338,11 +338,12 @@
|
||||
M.update_inv_hands()
|
||||
|
||||
/obj/item/toy/sword/cx/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!in_range(src, user)) //Basic checks to prevent abuse
|
||||
return
|
||||
if(user.incapacitated() || !istype(user))
|
||||
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
return TRUE
|
||||
|
||||
if(alert("Are you sure you want to recolor your blade?", "Confirm Repaint", "Yes", "No") == "Yes")
|
||||
var/energy_color_input = input(usr,"","Choose Energy Color",light_color) as color|null
|
||||
@@ -350,6 +351,7 @@
|
||||
light_color = sanitize_hexcolor(energy_color_input, desired_format=6, include_crunch=1)
|
||||
update_icon()
|
||||
update_light()
|
||||
return TRUE
|
||||
|
||||
/obj/item/toy/sword/cx/worn_overlays(isinhands, icon_file)
|
||||
. = ..()
|
||||
|
||||
@@ -541,6 +541,7 @@
|
||||
clean_blood()
|
||||
|
||||
/obj/item/twohanded/dualsaber/hypereutactic/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!user.canUseTopic(src, BE_CLOSE, FALSE) || hacked)
|
||||
return
|
||||
if(user.incapacitated() || !istype(user))
|
||||
@@ -553,6 +554,7 @@
|
||||
light_color = sanitize_hexcolor(energy_color_input, desired_format=6, include_crunch=1)
|
||||
update_icon()
|
||||
update_light()
|
||||
return TRUE
|
||||
|
||||
/obj/item/twohanded/dualsaber/hypereutactic/worn_overlays(isinhands, icon_file)
|
||||
. = ..()
|
||||
@@ -659,6 +661,7 @@
|
||||
qdel(src)
|
||||
|
||||
/obj/item/twohanded/spear/AltClick(mob/user)
|
||||
. = ..()
|
||||
if(user.canUseTopic(src, BE_CLOSE))
|
||||
..()
|
||||
if(!explosive)
|
||||
@@ -667,6 +670,7 @@
|
||||
var/input = stripped_input(user,"What do you want your war cry to be? You will shout it when you hit someone in melee.", ,"", 50)
|
||||
if(input)
|
||||
src.war_cry = input
|
||||
return TRUE
|
||||
|
||||
/obj/item/twohanded/spear/CheckParts(list/parts_list)
|
||||
var/obj/item/shard/tip = locate() in parts_list
|
||||
|
||||
Reference in New Issue
Block a user