Skip to content

Commit

Permalink
makes you unable to to see inventory from another zlvl (#26793)
Browse files Browse the repository at this point in the history
  • Loading branch information
Qwertytoforty authored Sep 15, 2024
1 parent 04e65c7 commit 44694d8
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions code/game/objects/items/weapons/storage/storage_base.dm
Original file line number Diff line number Diff line change
Expand Up @@ -468,20 +468,18 @@

if(!prevent_warning)
// all mobs with clients attached, sans the item's user
var/viewer_list = GLOB.player_list - user

// the item's user will always get a notification
to_chat(user, "<span class='notice'>You put [I] into [src].</span>")

// if the item less than normal sized, only people within 1 tile get the message, otherwise, everybody in view gets it
if(I.w_class < WEIGHT_CLASS_NORMAL)
for(var/mob/M in viewer_list)
for(var/mob/M in range(1, user))
if(in_range(M, user))
M.show_message("<span class='notice'>[user] puts [I] into [src].</span>")
else
// restrict player list to include only those in view
viewer_list = viewer_list & viewers(world.view, user)
for(var/mob/M in viewer_list)
for(var/mob/M in oviewers(7, user))
M.show_message("<span class='notice'>[user] puts [I] into [src].</span>")

orient2hud(user)
Expand Down

0 comments on commit 44694d8

Please sign in to comment.