Skip to content

Commit

Permalink
exploit fix (#28319)
Browse files Browse the repository at this point in the history
  • Loading branch information
1080pCat authored Feb 9, 2025
1 parent 670a0ba commit 4ba6266
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion code/game/objects/items/weapons/rpd.dm
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@

// If we get here, then we're effectively acting on the turf, probably placing a pipe.
if(ranged) //woosh beam if bluespaced at a distance
if(get_dist(src, T) >= (user.client.maxview() + 2))
if(get_dist(src, T) >= (user.client.maxview() / 2))
message_admins("\[EXPLOIT] [key_name_admin(user)] attempted to place pipes with a BRPD via a camera console. (Attempted range exploit)")
playsound(src, 'sound/machines/synth_no.ogg', 15, TRUE)
to_chat(user, "<span class='notice'>ERROR: \The [T] is out of [src]'s range!</span>")
Expand Down
9 changes: 4 additions & 5 deletions code/game/objects/items/weapons/stock_parts.dm
Original file line number Diff line number Diff line change
Expand Up @@ -50,17 +50,16 @@
if(!proximity_flag)
if(!works_from_distance)
return
if(get_dist(src, M) > (user.client.maxview() + 2))
if(get_dist(user, M) > (user.client.maxview() / 2))
message_admins("\[EXPLOIT] [key_name_admin(user)] attempted to upgrade machinery with a BRPED via a camera console (attempted range exploit).")
playsound(src, 'sound/machines/synth_no.ogg', 15, TRUE)
to_chat(user, "<span class='notice'>ERROR: [M] is out of [src]'s range!</span>")
return

if(M.component_parts)
M.exchange_parts(user, src)
if(works_from_distance)
user.Beam(M, icon_state="rped_upgrade", icon='icons/effects/effects.dmi', time=5)
else
message_admins("\[EXPLOIT] [key_name_admin(user)] attempted to upgrade machinery with a BRPED via a camera console (attempted range exploit).")
playsound(src, 'sound/machines/synth_no.ogg', 15, TRUE)
to_chat(user, "<span class='notice'>ERROR: [M] is out of [src]'s range!</span>")

/obj/item/storage/part_replacer/tier4/populate_contents()
for(var/amount in 1 to 30)
Expand Down

0 comments on commit 4ba6266

Please sign in to comment.