[MIRROR] usr to user part two (#10015)

Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2025-01-31 14:27:34 -07:00
committed by GitHub
parent 538c8e7187
commit a245b8687f
203 changed files with 974 additions and 993 deletions

View File

@@ -193,7 +193,7 @@
/obj/item/gun/energy/staff/special_check(var/mob/user)
if((user.mind && !wizards.is_antagonist(user.mind)))
to_chat(usr, span_warning("You focus your mind on \the [src], but nothing happens!"))
to_chat(user, span_warning("You focus your mind on \the [src], but nothing happens!"))
return 0
return ..()

View File

@@ -19,27 +19,27 @@
if(get_dist(user, src) <= 2)
. += span_blue("It's loaded with [confetti_charge] ball\s of confetti.")
/obj/item/gun/launcher/confetti_cannon/attackby(obj/item/I as obj, mob/user as mob)
/obj/item/gun/launcher/confetti_cannon/attackby(obj/item/I, mob/user)
if(istype(I, /obj/item/paper) || istype(I, /obj/item/shreddedp))
if(confetti_charge < max_confetti)
user.drop_item()
++confetti_charge
to_chat(usr, span_blue("You put the paper in the [src]."))
to_chat(user, span_blue("You put the paper in the [src]."))
qdel(I)
else
to_chat(usr, span_red("[src] cannot hold more paper."))
to_chat(user, span_red("[src] cannot hold more paper."))
/obj/item/gun/launcher/confetti_cannon/proc/pump(mob/M as mob)
playsound(M, 'sound/weapons/shotgunpump.ogg', 60, 1)
/obj/item/gun/launcher/confetti_cannon/proc/pump(mob/user)
playsound(user, 'sound/weapons/shotgunpump.ogg', 60, 1)
if(!chambered)
if(confetti_charge)
chambered = new /obj/item/grenade/confetti/party_ball
--confetti_charge
to_chat(usr, span_blue("You compress a new confetti ball."))
to_chat(user, span_blue("You compress a new confetti ball."))
else
to_chat(usr, span_red("The [src] is out of confetti!"))
to_chat(user, span_red("The [src] is out of confetti!"))
else
to_chat(usr, span_red("The [src] is already loaded!"))
to_chat(user, span_red("The [src] is already loaded!"))
/obj/item/gun/launcher/confetti_cannon/attack_self(mob/user)
pump(user)
@@ -70,14 +70,14 @@
name = "Party Cannon"
desc = "Confetti, pies, banana peels, chaos!"
/obj/item/gun/launcher/confetti_cannon/robot/pump(mob/M as mob)
playsound(M, 'sound/weapons/shotgunpump.ogg', 60, 1)
/obj/item/gun/launcher/confetti_cannon/robot/pump(mob/user)
playsound(user, 'sound/weapons/shotgunpump.ogg', 60, 1)
if(!chambered)
var/choice = tgui_alert(usr, "Load the Party Canon with?", "Change What?", list("Confetti","Banana Peel","Cream Pie"))
var/choice = tgui_alert(user, "Load the Party Canon with?", "Change What?", list("Confetti","Banana Peel","Cream Pie"))
if(!choice)
return
if(istype(usr,/mob/living/silicon/robot))
var/mob/living/silicon/robot/R = usr
if(istype(user,/mob/living/silicon/robot))
var/mob/living/silicon/robot/R = user
if(!R.use_direct_power(200, 400))
to_chat(R, span_warning("Warning, low power detected. Aborting action."))
return
@@ -85,15 +85,15 @@
switch(choice)
if("Confetti")
chambered = new /obj/item/grenade/confetti/party_ball
to_chat(usr, span_blue("Confetti loaded."))
to_chat(user, span_blue("Confetti loaded."))
if("Banana Peel")
chambered = new /obj/item/bananapeel
to_chat(usr, span_blue("Banana peel loaded."))
to_chat(user, span_blue("Banana peel loaded."))
if("Cream Pie")
chambered = new /obj/item/reagent_containers/food/snacks/pie
to_chat(usr, span_blue("Banana cream pie loaded."))
to_chat(user, span_blue("Banana cream pie loaded."))
else
to_chat(usr, span_red("The [src] is already loaded!"))
to_chat(user, span_red("The [src] is already loaded!"))
/obj/item/gun/launcher/confetti_cannon/robot/consume_next_projectile()
if(istype(chambered,/obj/item/grenade/confetti/party_ball))

View File

@@ -113,7 +113,7 @@
while(bolt && tension && loc == current_user)
if(!do_after(user, 25)) //crossbow strings don't just magically pull back on their own.
user.visible_message("[usr] stops drawing and relaxes the string of [src].",span_warning("You stop drawing back and relax the string of [src]."))
user.visible_message("[user] stops drawing and relaxes the string of [src].",span_warning("You stop drawing back and relax the string of [src]."))
tension = 0
update_icon()
return
@@ -127,10 +127,10 @@
if(tension >= max_tension)
tension = max_tension
to_chat(usr, "[src] clunks as you draw the string to its maximum tension!")
to_chat(user, "[src] clunks as you draw the string to its maximum tension!")
return
user.visible_message("[usr] draws back the string of [src]!",span_notice("You continue drawing back the string of [src]!"))
user.visible_message("[user] draws back the string of [src]!",span_notice("You continue drawing back the string of [src]!"))
/obj/item/gun/launcher/crossbow/proc/increase_tension(var/mob/user as mob)

View File

@@ -18,8 +18,8 @@
matter = list(MAT_STEEL = 2000)
//revolves the magazine, allowing players to choose between multiple grenade types
/obj/item/gun/launcher/grenade/proc/pump(mob/M as mob)
playsound(M, 'sound/weapons/shotgunpump.ogg', 60, 1)
/obj/item/gun/launcher/grenade/proc/pump(mob/user)
playsound(user, 'sound/weapons/shotgunpump.ogg', 60, 1)
var/obj/item/grenade/next
if(grenades.len)
@@ -30,9 +30,9 @@
if(next)
grenades -= next //Remove grenade from loaded list.
chambered = next
to_chat(M, span_warning("You pump [src], loading \a [next] into the chamber."))
to_chat(user, span_warning("You pump [src], loading \a [next] into the chamber."))
else
to_chat(M, span_warning("You pump [src], but the magazine is empty."))
to_chat(user, span_warning("You pump [src], but the magazine is empty."))
update_icon()
/obj/item/gun/launcher/grenade/examine(mob/user)

View File

@@ -21,7 +21,7 @@
if(get_dist(user, src) <= 2)
. += span_blue("[rockets.len] / [max_rockets] rockets.")
/obj/item/gun/launcher/rocket/attackby(obj/item/I as obj, mob/user as mob)
/obj/item/gun/launcher/rocket/attackby(obj/item/I, mob/user)
if(istype(I, /obj/item/ammo_casing/rocket))
if(rockets.len < max_rockets)
user.drop_item()
@@ -30,7 +30,7 @@
to_chat(user, span_blue("You put the rocket in [src]."))
to_chat(user, span_blue("[rockets.len] / [max_rockets] rockets."))
else
to_chat(usr, span_red(">[src] cannot hold more rockets."))
to_chat(user, span_red(">[src] cannot hold more rockets."))
/obj/item/gun/launcher/rocket/consume_next_projectile()
if(rockets.len)

View File

@@ -45,7 +45,7 @@
to_chat(M, span_notice("You don't feel cool enough to name this gun, chump."))
return 0
var/input = sanitizeSafe(input(usr, "What do you want to name the gun?", ,""), MAX_NAME_LEN)
var/input = sanitizeSafe(input(M, "What do you want to name the gun?", ,""), MAX_NAME_LEN)
if(src && input && !M.stat && in_range(M,src))
name = input

View File

@@ -68,7 +68,7 @@
to_chat(M, span_notice("You don't feel cool enough to name this gun, chump."))
return 0
var/input = sanitizeSafe(input(usr, "What do you want to name the gun?", ,""), MAX_NAME_LEN)
var/input = sanitizeSafe(input(M, "What do you want to name the gun?", ,""), MAX_NAME_LEN)
if(src && input && !M.stat && in_range(M,src))
name = input
@@ -96,7 +96,7 @@
to_chat(M, span_notice("You don't feel cool enough to name this gun, chump."))
return 0
var/input = sanitizeSafe(input(usr, "What do you want to name the gun?", ,""), MAX_NAME_LEN)
var/input = sanitizeSafe(input(M, "What do you want to name the gun?", ,""), MAX_NAME_LEN)
if(src && input && !M.stat && in_range(M,src))
name = input

View File

@@ -71,7 +71,7 @@
playsound(src, 'sound/weapons/targeton.ogg', 50, 1)
user.update_mob_action_buttons()
/obj/item/gun/projectile/shotgun/compact/verb/verb_toggle_stock(mob/user as mob)
/obj/item/gun/projectile/shotgun/compact/verb/verb_toggle_stock()
set category = "Object"
set name = "Toggle stock"
set src in usr
@@ -85,14 +85,14 @@
to_chat(usr, span_notice("You cannot do this in your current state."))
/obj/item/gun/projectile/shotgun/compact/attack_self(mob/user as mob)
if(issilicon(usr))
/obj/item/gun/projectile/shotgun/compact/attack_self(mob/user)
if(issilicon(user))
return
if (isliving(usr))
if (isliving(user))
toggle_stock()
else
to_chat(usr, span_notice("You cannot do this in your current state."))
to_chat(user, span_notice("You cannot do this in your current state."))
/obj/item/gun/projectile/shotgun/compact/ui_action_click(mob/unused_user, actiontype)
var/mob/living/user = loc

View File

@@ -26,7 +26,7 @@
var/obj/item/sniper_rifle_part/stock/stock = new(assembly)
assembly.stock = stock
assembly.part_count = 2
assembly.update_build()
assembly.update_build(user)
user.put_in_any_hand_if_possible(assembly) || assembly.dropInto(user.loc)
user.put_in_any_hand_if_possible(barrel) || barrel.dropInto(user.loc)
@@ -69,7 +69,7 @@
..()
trigger_group = src
/obj/item/sniper_rifle_part/attack_self(mob/user as mob)
/obj/item/sniper_rifle_part/attack_self(mob/user)
if(part_count == 1)
to_chat(user, span_warning("You can't disassemble this further!"))
return
@@ -90,7 +90,7 @@
user.put_in_any_hand_if_possible(P) || P.dropInto(loc)
P.part_count = 1
update_build()
update_build(user)
/obj/item/sniper_rifle_part/attackby(var/obj/item/sniper_rifle_part/A as obj, mob/user as mob)
@@ -143,7 +143,7 @@
update_build(user)
/obj/item/sniper_rifle_part/proc/update_build()
/obj/item/sniper_rifle_part/proc/update_build(mob/user)
switch(part_count)
if(1)
name = initial(name)
@@ -163,10 +163,10 @@
if(3)
var/obj/item/gun/projectile/heavysniper/collapsible/gun = new (get_turf(src), 0)
if(usr && ishuman(usr))
var/mob/living/carbon/human/user = usr
user.unEquip(src, force=1)
user.put_in_any_hand_if_possible(gun) || gun.dropInto(loc)
if(user && ishuman(user))
var/mob/living/carbon/human/H = user
H.unEquip(src, force=1)
H.put_in_any_hand_if_possible(gun) || gun.dropInto(loc)
qdel(src)
/obj/item/gun/projectile/heavysniper/update_icon()