mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-01-02 05:23:31 +00:00
Conflict fix
This commit is contained in:
@@ -191,7 +191,8 @@
|
||||
/obj/structure/closet/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(src.opened)
|
||||
if(istype(W, /obj/item/weapon/grab))
|
||||
src.MouseDrop_T(W:affecting, user) //act like they were dragged onto the closet
|
||||
var/obj/item/weapon/grab/G = W
|
||||
src.MouseDrop_T(G.affecting, user) //act like they were dragged onto the closet
|
||||
if(istype(W,/obj/item/tk_grab))
|
||||
return 0
|
||||
if(istype(W, /obj/item/weapon/weldingtool))
|
||||
@@ -206,6 +207,8 @@
|
||||
return
|
||||
if(isrobot(user))
|
||||
return
|
||||
if(W.loc != user) // This should stop mounted modules ending up outside the module.
|
||||
return
|
||||
usr.drop_item()
|
||||
if(W)
|
||||
W.loc = src.loc
|
||||
|
||||
@@ -66,12 +66,15 @@
|
||||
/obj/structure/closet/secure_closet/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(src.opened)
|
||||
if(istype(W, /obj/item/weapon/grab))
|
||||
var/obj/item/weapon/grab/G = W
|
||||
if(src.large)
|
||||
src.MouseDrop_T(W:affecting, user) //act like they were dragged onto the closet
|
||||
src.MouseDrop_T(G.affecting, user) //act like they were dragged onto the closet
|
||||
else
|
||||
user << "<span class='notice'>The locker is too small to stuff [W:affecting] into!</span>"
|
||||
user << "<span class='notice'>The locker is too small to stuff [G.affecting] into!</span>"
|
||||
if(isrobot(user))
|
||||
return
|
||||
if(W.loc != user) // This should stop mounted modules ending up outside the module.
|
||||
return
|
||||
user.drop_item()
|
||||
if(W)
|
||||
W.loc = src.loc
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
//added by cael from old bs12
|
||||
//not sure if there's an immediate place for secure wall lockers, but i'm sure the players will think of something
|
||||
|
||||
/obj/structure/closet/walllocker
|
||||
desc = "A wall mounted storage locker."
|
||||
name = "Wall Locker"
|
||||
icon = 'icons/obj/walllocker.dmi'
|
||||
icon_state = "wall-locker"
|
||||
density = 0
|
||||
anchored = 1
|
||||
icon_closed = "wall-locker"
|
||||
icon_opened = "wall-lockeropen"
|
||||
|
||||
//spawns endless (3 sets) amounts of breathmask, emergency oxy tank and crowbar
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker
|
||||
name = "emergency locker"
|
||||
desc = "A wall mounted locker with emergency supplies."
|
||||
var/list/spawnitems = list(/obj/item/weapon/tank/emergency_oxygen,/obj/item/clothing/mask/breath)
|
||||
var/amount = 2 // spawns each items X times.
|
||||
icon_state = "emerg"
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker/toggle(mob/user as mob)
|
||||
src.attack_hand(user)
|
||||
return
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
return
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker/attack_hand(mob/user as mob)
|
||||
if (istype(user, /mob/living/silicon/ai)) //Added by Strumpetplaya - AI shouldn't be able to
|
||||
return //activate emergency lockers. This fixes that. (Does this make sense, the AI can't call attack_hand, can it? --Mloc)
|
||||
if(!amount)
|
||||
usr << "<spawn class='notice'>It's empty.."
|
||||
return
|
||||
if(amount)
|
||||
usr << "<spawn class='notice'>You take out some items from \the [src]."
|
||||
for(var/path in spawnitems)
|
||||
new path(src.loc)
|
||||
amount--
|
||||
return
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker/north
|
||||
pixel_y = 32
|
||||
dir = SOUTH
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker/south
|
||||
pixel_y = -32
|
||||
dir = NORTH
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker/west
|
||||
pixel_x = -32
|
||||
dir = WEST
|
||||
|
||||
/obj/structure/closet/walllocker/emerglocker/east
|
||||
pixel_x = 32
|
||||
dir = EAST
|
||||
@@ -70,6 +70,8 @@
|
||||
if(opened)
|
||||
if(isrobot(user))
|
||||
return
|
||||
if(W.loc != user) // This should stop mounted modules ending up outside the module.
|
||||
return
|
||||
user.drop_item()
|
||||
if(W)
|
||||
W.loc = src.loc
|
||||
|
||||
Reference in New Issue
Block a user