From cfa84d9ec5d32fd7392289288256387f3467dac8 Mon Sep 17 00:00:00 2001 From: MLGTASTICa Date: Tue, 13 Aug 2024 10:16:33 +0300 Subject: [PATCH] add --- .../structures/stool_bed_chair_nest/chairs.dm | 2 + .../structures/stool_bed_chair_nest/stools.dm | 1 + code/modules/projectiles/hitbox_datums.dm | 50 +++++++++++++++++++ code/modules/tables/rack.dm | 2 + 4 files changed, 55 insertions(+) diff --git a/code/game/objects/structures/stool_bed_chair_nest/chairs.dm b/code/game/objects/structures/stool_bed_chair_nest/chairs.dm index 8823108153..35fbda608a 100644 --- a/code/game/objects/structures/stool_bed_chair_nest/chairs.dm +++ b/code/game/objects/structures/stool_bed_chair_nest/chairs.dm @@ -3,6 +3,7 @@ desc = "You sit in this. Either by will or force." description_info = "Can be used as a support to climb up by looking up and clicking on a free tile that is not blocked by a railing" icon_state = "chair_preview" + hitbox = /datum/hitboxDatum/atom/chair color = "#666666" base_icon = "chair" var/propelled = 0 // Check for fire-extinguisher-driven chairs @@ -109,6 +110,7 @@ /obj/structure/bed/chair/comfy desc = "A chair. It looks comfy." icon_state = "comfychair_preview" + hitbox = /datum/hitboxDatum/atom/armChair /obj/structure/bed/chair/comfy/brown/New(var/newloc,var/newmaterial) ..(newloc,MATERIAL_STEEL, MATERIAL_LEATHER) diff --git a/code/game/objects/structures/stool_bed_chair_nest/stools.dm b/code/game/objects/structures/stool_bed_chair_nest/stools.dm index e750ba2e07..0225ef2143 100644 --- a/code/game/objects/structures/stool_bed_chair_nest/stools.dm +++ b/code/game/objects/structures/stool_bed_chair_nest/stools.dm @@ -5,6 +5,7 @@ var/global/list/stool_cache = list() //haha stool name = "stool" desc = "Apply butt." icon = 'icons/obj/furniture.dmi' + hitbox = /datum/hitboxDatum/atom/stool icon_state = "stool_preview" //set for the map melleDamages = list(ARMOR_BLUNT = list(DELEM(BRUTE,15))) throwforce = 10 diff --git a/code/modules/projectiles/hitbox_datums.dm b/code/modules/projectiles/hitbox_datums.dm index d85381f618..35a7a0fc7a 100644 --- a/code/modules/projectiles/hitbox_datums.dm +++ b/code/modules/projectiles/hitbox_datums.dm @@ -349,6 +349,56 @@ boolean lineLine(float x1, float y1, float x2, float y2, float x3, float y3, flo LISTWEST = list(BBOX(5,4,31,28, LEVEL_TURF, LEVEL_TABLE, null)) ) +/datum/hitboxDatum/atom/storageRack + boundingBoxes = list( + LISTNORTH = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_TABLE, null)), + LISTSOUTH = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_TABLE, null)), + LISTEAST = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_TABLE, null)), + LISTWEST = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_TABLE, null)) + ) + +/datum/hitboxDatum/atom/storageShelf + boundingBoxes = list( + LISTNORTH = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_CHEST, null)), + LISTSOUTH = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_CHEST, null)), + LISTEAST = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_CHEST, null)), + LISTWEST = list(BBOX(5,5,28,27, LEVEL_TURF, LEVEL_CHEST, null)) + ) + +/datum/hitboxDatum/atom/bed + boundingBoxes = list( + LISTNORTH = list(BBOX(2,4,31,19, LEVEL_TURF+2, LEVEL_LYING-5, null)), + LISTSOUTH = list(BBOX(2,4,31,19, LEVEL_TURF+2, LEVEL_LYING-5, null)), + LISTEAST = list(BBOX(2,4,31,19, LEVEL_TURF+2, LEVEL_LYING-5, null)), + LISTWEST = list(BBOX(2,4,31,19, LEVEL_TURF+2, LEVEL_LYING-5, null)) + ) + +/datum/hitboxDatum/atom/stool + boundingBoxes = list( + LISTNORTH = list(BBOX(10,1,23,17, LEVEL_TURF, LEVEL_LYING+5, null)), + LISTSOUTH = list(BBOX(10,1,23,17, LEVEL_TURF, LEVEL_LYING+5, null)), + LISTEAST = list(BBOX(10,1,23,17, LEVEL_TURF, LEVEL_LYING+5, null)), + LISTWEST = list(BBOX(10,1,23,17, LEVEL_TURF, LEVEL_LYING+5, null)) + ) + +/datum/hitboxDatum/atom/chair + boundingBoxes = list( + LISTSOUTH = list(BBOX(9,6,23,15, LEVEL_LYING, LEVEL_LYING+3, null), BBOX(10,15,22,25, LEVEL_LYING+3, LEVEL_TABLE, null)), + LISTNORTH = list(BBOX(9,4,23,10, LEVEL_LYING, LEVEL_LYING+3, null), BBOX(9,11,23,22, LEVEL_LYING+3, LEVEL_TABLE, null)), + LISTEAST = list(BBOX(10,7,22,19, LEVEL_LYING, LEVEL_LYING+3, null), BBOX(8,9,12,26, LEVEL_LYING+3, LEVEL_TABLE, null)), + LISTWEST = list(BBOX(11,7,23,19, LEVEL_LYING, LEVEL_LYING+3, null), BBOX(21,8,25,26, LEVEL_LYING+3, LEVEL_TABLE, null)) + ) + +/datum/hitboxDatum/atom/armChair + boundingBoxes = list( + LISTSOUTH = list(BBOX(8,1,25,15, LEVEL_TURF, LEVEL_LYING+3, null), BBOX(10,14,23,25, LEVEL_LYING+3, LEVEL_TABLE+5, null)), + LISTNORTH = list(BBOX(8,2,25,15, LEVEL_TURF, LEVEL_LYING+3, null), BBOX(10,11,23,28, LEVEL_LYING+3, LEVEL_TABLE+5, null)), + LISTEAST = list(BBOX(9,2,25,18, LEVEL_TURF, LEVEL_LYING+3, null), BBOX(8,10,13,29, LEVEL_LYING+3, LEVEL_TABLE+5, null)), + LISTWEST = list(BBOX(8,2,24,18, LEVEL_TURF, LEVEL_LYING+3, null), BBOX(20,11,25,29, LEVEL_LYING+3, LEVEL_TABLE+5, null)), + ) + + + /datum/hitboxDatum/turf boundingBoxes = BBOX(0,0,32,32,LEVEL_BELOW ,LEVEL_ABOVE,null) diff --git a/code/modules/tables/rack.dm b/code/modules/tables/rack.dm index 7ce674c167..1aa14576a8 100644 --- a/code/modules/tables/rack.dm +++ b/code/modules/tables/rack.dm @@ -2,6 +2,7 @@ name = "rack" desc = "Different from the medieval version." icon = 'icons/obj/objects.dmi' + hitbox = /datum/hitboxDatum/atom/storageRack icon_state = "rack" can_plate = 0 can_reinforce = 0 @@ -25,6 +26,7 @@ name = "shelf" desc = "For showing off your collections of dust, electronics, the heads of your enemies and tools." icon_state = "shelf" + hitbox = /datum/hitboxDatum/atom/storageShelf