mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 12:41:09 +01:00
I am crying.
Merge branch 'master' of https://github.com/tgstation/-tg-station into toostat4tue Conflicts: code/game/objects/structures/crates_lockers/closets/statue.dm code/modules/mob/living/simple_animal/hostile/statue.dm code/modules/projectiles/projectile/magic.dm tgstation.dme
This commit is contained in:
@@ -1,95 +1,95 @@
|
||||
/obj/structure/closet/crate/bin
|
||||
desc = "A trash bin, place your trash here for the janitor to collect."
|
||||
name = "trash bin"
|
||||
icon = 'icons/obj/storage.dmi'
|
||||
icon_state = "largebins"
|
||||
density = 1
|
||||
anchored = 1
|
||||
icon_opened = "largebinsopen"
|
||||
icon_closed = "largebins"
|
||||
sound_effect_open = 'sound/effects/bin_open.ogg'
|
||||
sound_effect_close = 'sound/effects/bin_close.ogg'
|
||||
var/animation = "animate_largebins"
|
||||
var/redlight = "largebinr"
|
||||
var/greenlight = "largebing"
|
||||
var/orangelight = "largebino"
|
||||
|
||||
|
||||
/obj/structure/closet/crate/bin/New()
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/update_icon()
|
||||
..()
|
||||
overlays.Cut()
|
||||
if(contents.len == 0)
|
||||
overlays += greenlight
|
||||
else if(contents.len >= storage_capacity)
|
||||
overlays += redlight
|
||||
else
|
||||
overlays += orangelight
|
||||
|
||||
/obj/structure/closet/crate/bin/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(istype(W, /obj/item/weapon/storage/bag/trash))
|
||||
var/obj/item/weapon/storage/bag/trash/T = W
|
||||
user << "\blue You fill the bag."
|
||||
for(var/obj/item/O in src)
|
||||
if(T.can_be_inserted(O, 1))
|
||||
O.loc = T
|
||||
T.update_icon()
|
||||
do_animate()
|
||||
else if(istype(W, /obj/item/weapon/wrench))
|
||||
anchored = !anchored
|
||||
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
|
||||
else if(istype(W, /obj/item/weapon/grab))
|
||||
var/obj/item/weapon/grab/G = W
|
||||
src.MouseDrop_T(G.affecting, user) //act like they were dragged onto the closet
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/structure/closet/crate/bin/MouseDrop_T(atom/movable/O as mob|obj, mob/user as mob)
|
||||
. = ..(O, user, 0, 0, 0)
|
||||
if(.)
|
||||
if(O != user)
|
||||
user.visible_message("<span class='danger'>[user] tries to stuff [O] into the [src].</span>", \
|
||||
"<span class='danger'>You try to stuff [O] into the [src].</span>", \
|
||||
"<span class='danger'>You hear clanging.</span>")
|
||||
if (!do_after(user, 40))
|
||||
return
|
||||
if(!..(O, user, 0, 0))
|
||||
return
|
||||
user.visible_message("<span class='notice'>[user] stuffs [O] into the [src].</span>", \
|
||||
"<span class='notice'>You stuff [O] into the [src].</span>", \
|
||||
"<span class='notice'>You hear a loud metal bang.</span>")
|
||||
insert(O, 1, !opened)
|
||||
if(opened)
|
||||
close()
|
||||
|
||||
/obj/structure/closet/crate/bin/open()
|
||||
. = ..()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/close()
|
||||
. = ..()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/proc/do_animate()
|
||||
playsound(src.loc, sound_effect_open, 15, 1, -3)
|
||||
flick(animation, src)
|
||||
spawn(13)
|
||||
playsound(src.loc, sound_effect_close, 15, 1, -3)
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/insert(var/obj/item/I, var/include_mobs = 0, var/animate = 0)
|
||||
. = ..(I, include_mobs)
|
||||
if(animate && .)
|
||||
do_animate()
|
||||
|
||||
/obj/structure/closet/crate/bin/place(var/mob/user, var/obj/item/I)
|
||||
if(contents.len >= storage_capacity)
|
||||
return 1
|
||||
if(!opened)
|
||||
user.drop_item()
|
||||
insert(I, 0, 1)
|
||||
return 1
|
||||
/obj/structure/closet/crate/bin
|
||||
desc = "A trash bin, place your trash here for the janitor to collect."
|
||||
name = "trash bin"
|
||||
icon = 'icons/obj/storage.dmi'
|
||||
icon_state = "largebins"
|
||||
density = 1
|
||||
anchored = 1
|
||||
icon_opened = "largebinsopen"
|
||||
icon_closed = "largebins"
|
||||
sound_effect_open = 'sound/effects/bin_open.ogg'
|
||||
sound_effect_close = 'sound/effects/bin_close.ogg'
|
||||
var/animation = "animate_largebins"
|
||||
var/redlight = "largebinr"
|
||||
var/greenlight = "largebing"
|
||||
var/orangelight = "largebino"
|
||||
|
||||
|
||||
/obj/structure/closet/crate/bin/New()
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/update_icon()
|
||||
..()
|
||||
overlays.Cut()
|
||||
if(contents.len == 0)
|
||||
overlays += greenlight
|
||||
else if(contents.len >= storage_capacity)
|
||||
overlays += redlight
|
||||
else
|
||||
overlays += orangelight
|
||||
|
||||
/obj/structure/closet/crate/bin/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(istype(W, /obj/item/weapon/storage/bag/trash))
|
||||
var/obj/item/weapon/storage/bag/trash/T = W
|
||||
user << "\blue You fill the bag."
|
||||
for(var/obj/item/O in src)
|
||||
if(T.can_be_inserted(O, 1))
|
||||
O.loc = T
|
||||
T.update_icon()
|
||||
do_animate()
|
||||
else if(istype(W, /obj/item/weapon/wrench))
|
||||
anchored = !anchored
|
||||
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
|
||||
else if(istype(W, /obj/item/weapon/grab))
|
||||
var/obj/item/weapon/grab/G = W
|
||||
src.MouseDrop_T(G.affecting, user) //act like they were dragged onto the closet
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/structure/closet/crate/bin/MouseDrop_T(atom/movable/O as mob|obj, mob/user as mob)
|
||||
. = ..(O, user, 0, 0, 0)
|
||||
if(.)
|
||||
if(O != user)
|
||||
user.visible_message("<span class='danger'>[user] tries to stuff [O] into the [src].</span>", \
|
||||
"<span class='danger'>You try to stuff [O] into the [src].</span>", \
|
||||
"<span class='danger'>You hear clanging.</span>")
|
||||
if (!do_after(user, 40))
|
||||
return
|
||||
if(!..(O, user, 0, 0))
|
||||
return
|
||||
user.visible_message("<span class='notice'>[user] stuffs [O] into the [src].</span>", \
|
||||
"<span class='notice'>You stuff [O] into the [src].</span>", \
|
||||
"<span class='notice'>You hear a loud metal bang.</span>")
|
||||
insert(O, 1, !opened)
|
||||
if(opened)
|
||||
close()
|
||||
|
||||
/obj/structure/closet/crate/bin/open()
|
||||
. = ..()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/close()
|
||||
. = ..()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/proc/do_animate()
|
||||
playsound(src.loc, sound_effect_open, 15, 1, -3)
|
||||
flick(animation, src)
|
||||
spawn(13)
|
||||
playsound(src.loc, sound_effect_close, 15, 1, -3)
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/bin/insert(var/obj/item/I, var/include_mobs = 0, var/animate = 0)
|
||||
. = ..(I, include_mobs)
|
||||
if(animate && .)
|
||||
do_animate()
|
||||
|
||||
/obj/structure/closet/crate/bin/place(var/mob/user, var/obj/item/I)
|
||||
if(contents.len >= storage_capacity)
|
||||
return 1
|
||||
if(!opened)
|
||||
user.drop_item()
|
||||
insert(I, 0, 1)
|
||||
return 1
|
||||
return 0
|
||||
@@ -1,22 +1,22 @@
|
||||
/obj/structure/dresser
|
||||
name = "dresser"
|
||||
desc = "A nicely-crafted wooden dresser. It's filled with lots of undies."
|
||||
icon = 'icons/obj/stationobjs.dmi'
|
||||
icon_state = "dresser"
|
||||
density = 1
|
||||
anchored = 1
|
||||
|
||||
/obj/structure/dresser/attack_hand(mob/user as mob)
|
||||
if(!Adjacent(user))//no tele-grooming
|
||||
return
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
|
||||
var/new_undies = input(user, "Select your underwear", "Changing") as null|anything in underwear_all
|
||||
if(!Adjacent(user))//no tele-grooming
|
||||
return
|
||||
if(new_undies)
|
||||
H.underwear = new_undies
|
||||
|
||||
add_fingerprint(H)
|
||||
/obj/structure/dresser
|
||||
name = "dresser"
|
||||
desc = "A nicely-crafted wooden dresser. It's filled with lots of undies."
|
||||
icon = 'icons/obj/stationobjs.dmi'
|
||||
icon_state = "dresser"
|
||||
density = 1
|
||||
anchored = 1
|
||||
|
||||
/obj/structure/dresser/attack_hand(mob/user as mob)
|
||||
if(!Adjacent(user))//no tele-grooming
|
||||
return
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
|
||||
var/new_undies = input(user, "Select your underwear", "Changing") as null|anything in underwear_all
|
||||
if(!Adjacent(user))//no tele-grooming
|
||||
return
|
||||
if(new_undies)
|
||||
H.underwear = new_undies
|
||||
|
||||
add_fingerprint(H)
|
||||
H.update_body()
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user