[MIRROR] usr to user up to player effects (#9552)

Co-authored-by: Heroman3003 <31296024+Heroman3003@users.noreply.github.com>
Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2024-12-01 10:31:19 -07:00
committed by GitHub
parent a7e4ef7dad
commit 0180cc74c5
297 changed files with 1866 additions and 1893 deletions

View File

@@ -662,7 +662,7 @@ About the new airlock wires panel:
/obj/machinery/door/airlock/bumpopen(mob/living/user as mob) //Airlocks now zap you when you 'bump' them open when they're electrified. --NeoFite
if(!issilicon(usr))
if(!issilicon(user))
if(src.isElectrified())
if(!src.justzap)
if(src.shock(user, 100))
@@ -986,7 +986,7 @@ About the new airlock wires panel:
return ..()
/obj/machinery/door/airlock/attack_hand(mob/user as mob)
if(!istype(usr, /mob/living/silicon))
if(!istype(user, /mob/living/silicon))
if(src.isElectrified())
if(src.shock(user, 100))
return
@@ -1048,10 +1048,10 @@ About the new airlock wires panel:
src.hold_open = user
src.attack_hand(user)
/obj/machinery/door/airlock/tgui_act(action, params)
/obj/machinery/door/airlock/tgui_act(action, params, datum/tgui/ui)
if(..())
return TRUE
if(!user_allowed(usr))
if(!user_allowed(ui.user))
return TRUE
switch(action)
@@ -1060,14 +1060,14 @@ About the new airlock wires panel:
loseMainPower()
update_icon()
else
to_chat(usr, span_warning("Main power is already offline."))
to_chat(ui.user, span_warning("Main power is already offline."))
. = TRUE
if("disrupt-backup")
if(!backup_power_lost_until)
loseBackupPower()
update_icon()
else
to_chat(usr, span_warning("Backup power is already offline."))
to_chat(ui.user, span_warning("Backup power is already offline."))
. = TRUE
if("shock-restore")
electrify(0, 1)
@@ -1082,14 +1082,14 @@ About the new airlock wires panel:
set_idscan(aiDisabledIdScanner, 1)
. = TRUE
// if("emergency-toggle")
// toggle_emergency(usr)
// toggle_emergency(ui.user)
// . = TRUE
if("bolt-toggle")
toggle_bolt(usr)
toggle_bolt(ui.user)
. = TRUE
if("light-toggle")
if(wires.is_cut(WIRE_BOLT_LIGHT))
to_chat(usr, "The bolt lights wire is cut - The door bolt lights are permanently disabled.")
to_chat(ui.user, "The bolt lights wire is cut - The door bolt lights are permanently disabled.")
return
lights = !lights
update_icon()
@@ -1099,12 +1099,12 @@ About the new airlock wires panel:
. = TRUE
if("speed-toggle")
if(wires.is_cut(WIRE_SPEED))
to_chat(usr, "The timing wire is cut - Cannot alter timing.")
to_chat(ui.user, "The timing wire is cut - Cannot alter timing.")
return
normalspeed = !normalspeed
. = TRUE
if("open-close")
user_toggle_open(usr)
user_toggle_open(ui.user)
. = TRUE
update_icon()
@@ -1160,7 +1160,7 @@ About the new airlock wires panel:
/obj/machinery/door/airlock/attackby(obj/item/C, mob/user as mob)
//to_world("airlock attackby src [src] obj [C] mob [user]")
if(!istype(usr, /mob/living/silicon))
if(!istype(user, /mob/living/silicon))
if(src.isElectrified())
if(src.shock(user, 75))
return
@@ -1191,7 +1191,7 @@ About the new airlock wires panel:
else if(C.has_tool_quality(TOOL_SCREWDRIVER))
if (src.p_open)
if (stat & BROKEN)
to_chat(usr, span_warning("The panel is broken and cannot be closed."))
to_chat(user, span_warning("The panel is broken and cannot be closed."))
else
src.p_open = FALSE
playsound(src, C.usesound, 50, 1)

View File

@@ -261,7 +261,7 @@
..()
/obj/machinery/access_button/attack_hand(mob/user)
add_fingerprint(usr)
add_fingerprint(user)
if(!allowed(user))
to_chat(user, span_warning("Access Denied"))

View File

@@ -193,7 +193,7 @@
to_chat(user, span_warning("You don't have enough sheets to repair this! You need at least [amt] sheets."))
return
to_chat(user, span_notice("You begin repairing [src]..."))
if(do_after(usr, 30))
if(do_after(user, 30))
if(P.use(amt))
to_chat(user, span_notice("You have repaired \The [src]"))
src.repair()

View File

@@ -173,13 +173,13 @@
break
return data
/obj/machinery/door_timer/tgui_act(action, params)
/obj/machinery/door_timer/tgui_act(action, params, datum/tgui/ui)
if(..())
return
. = TRUE
if(!allowed(usr))
to_chat(usr, span_warning("Access denied."))
if(!allowed(ui.user))
to_chat(ui.user, span_warning("Access denied."))
return FALSE
switch(action)