diff --git a/code/__DEFINES/sound.dm b/code/__DEFINES/sound.dm index ce21da39..77964258 100644 --- a/code/__DEFINES/sound.dm +++ b/code/__DEFINES/sound.dm @@ -123,4 +123,7 @@ #define SOUND_AREA_SPACE SOUND_ENVIRONMENT_UNDERWATER #define SOUND_AREA_LAVALAND SOUND_ENVIRONMENT_MOUNTAINS #define SOUND_AREA_ICEMOON SOUND_ENVIRONMENT_CAVE -#define SOUND_AREA_WOODFLOOR SOUND_ENVIRONMENT_CITY \ No newline at end of file +#define SOUND_AREA_WOODFLOOR SOUND_ENVIRONMENT_CITY + +#define INTERACTION_SOUND_RANGE_MODIFIER -3 +#define EQUIP_SOUND_VOLUME 30 \ No newline at end of file diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm index a0090bde..8cb1f333 100644 --- a/code/game/objects/items.dm +++ b/code/game/objects/items.dm @@ -29,9 +29,13 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE) obj_flags = NONE var/item_flags = NONE - var/hitsound = null - var/usesound = null - var/throwhitsound = null + + var/hitsound + var/usesound + var/throwhitsound + ///Sound used when equipping the item into a valid slot + var/equip_sound + var/w_class = WEIGHT_CLASS_NORMAL var/total_mass //Total mass in arbitrary pound-like values. If there's no balance reasons for an item to have otherwise, this var should be the item's weight in pounds. var/slot_flags = 0 //This is used to determine on which slots an item can fit. @@ -423,6 +427,9 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE) A.Grant(user) item_flags |= IN_INVENTORY + if(equip_sound && (slot_flags & slotdefine2slotbit(slot))) + playsound(src, equip_sound, EQUIP_SOUND_VOLUME, TRUE, ignore_walls = FALSE) + //sometimes we only want to grant the item's action if it's equipped in a specific slot. /obj/item/proc/item_action_slot_check(slot, mob/user) if(slot == SLOT_IN_BACKPACK || slot == SLOT_LEGCUFFED) //these aren't true slots, so avoid granting actions there diff --git a/code/game/objects/items/storage/belt.dm b/code/game/objects/items/storage/belt.dm index a91b592c..78d3d057 100644 --- a/code/game/objects/items/storage/belt.dm +++ b/code/game/objects/items/storage/belt.dm @@ -11,6 +11,7 @@ max_integrity = 300 var/content_overlays = FALSE //If this is true, the belt will gain overlays based on what it's holding var/worn_overlays = FALSE //worn counterpart of the above. + equip_sound = 'sound/items/equip/toolbelt_equip.ogg' /obj/item/storage/belt/suicide_act(mob/living/carbon/user) user.visible_message("[user] begins belting [user.p_them()]self with \the [src]! It looks like [user.p_theyre()] trying to commit suicide!") diff --git a/code/game/objects/structures/crates_lockers/closets.dm b/code/game/objects/structures/crates_lockers/closets.dm index e14646e2..1d960b21 100644 --- a/code/game/objects/structures/crates_lockers/closets.dm +++ b/code/game/objects/structures/crates_lockers/closets.dm @@ -27,8 +27,8 @@ var/mob_storage_capacity = 3 // how many human sized mob/living can fit together inside a closet. var/storage_capacity = 30 //This is so that someone can't pack hundreds of items in a locker/crate then open it in a populated area to crash clients. var/cutting_tool = /obj/item/weldingtool - var/open_sound = 'sound/machines/click.ogg' - var/close_sound = 'sound/machines/click.ogg' + var/open_sound = 'sound/effects/locker_open.ogg' + var/close_sound = 'sound/effects/locker_close.ogg' var/material_drop = /obj/item/stack/sheet/metal var/material_drop_amount = 2 var/delivery_icon = "deliverycloset" //which icon to use when packagewrapped. null to be unwrappable. diff --git a/code/modules/clothing/under/_under.dm b/code/modules/clothing/under/_under.dm index 2889242c..d581f8b2 100644 --- a/code/modules/clothing/under/_under.dm +++ b/code/modules/clothing/under/_under.dm @@ -16,6 +16,7 @@ var/obj/item/clothing/accessory/attached_accessory var/mutable_appearance/accessory_overlay mutantrace_variation = MUTANTRACE_VARIATION //Are there special sprites for specific situations? Don't use this unless you need to. + equip_sound = 'sound/items/equip/jumpsuit_equip.ogg' /obj/item/clothing/under/worn_overlays(isinhands = FALSE) . = list() @@ -156,4 +157,4 @@ if(SENSOR_COORDS) . += "Its vital tracker and tracking beacon appear to be enabled." if(attached_accessory) - . += "\A [attached_accessory] is attached to it." + . += "\A [attached_accessory] is attached to it." diff --git a/sound/effects/locker_close.ogg b/sound/effects/locker_close.ogg new file mode 100644 index 00000000..124f5d85 Binary files /dev/null and b/sound/effects/locker_close.ogg differ diff --git a/sound/effects/locker_open.ogg b/sound/effects/locker_open.ogg new file mode 100644 index 00000000..86cbcea0 Binary files /dev/null and b/sound/effects/locker_open.ogg differ diff --git a/sound/items/equip/jumpsuit_equip.ogg b/sound/items/equip/jumpsuit_equip.ogg new file mode 100644 index 00000000..bdcc2bb3 Binary files /dev/null and b/sound/items/equip/jumpsuit_equip.ogg differ diff --git a/sound/items/equip/toolbelt_equip.ogg b/sound/items/equip/toolbelt_equip.ogg new file mode 100644 index 00000000..0ef67a3f Binary files /dev/null and b/sound/items/equip/toolbelt_equip.ogg differ