diff --git a/modular_skyrat/modules/loadouts/loadout_items/loadout_datum_heads.dm b/modular_skyrat/modules/loadouts/loadout_items/loadout_datum_heads.dm index d34582b6d9d..abccc398308 100644 --- a/modular_skyrat/modules/loadouts/loadout_items/loadout_datum_heads.dm +++ b/modular_skyrat/modules/loadouts/loadout_items/loadout_datum_heads.dm @@ -177,6 +177,18 @@ GLOBAL_LIST_INIT(loadout_helmets, generate_loadout_items(/datum/loadout_item/hea * MISC */ +/datum/loadout_item/head/hair_tie + name = "Hair Tie" + item_path = /obj/item/clothing/head/hair_tie + +/datum/loadout_item/head/hair_tie_scrunchie + name = "Scrunchie" + item_path = /obj/item/clothing/head/hair_tie/scrunchie + +/datum/loadout_item/head/hair_tie_plastic_beads + name = "Colorful Hair tie" + item_path = /obj/item/clothing/head/hair_tie/plastic_beads + /datum/loadout_item/head/standalone_hood name = "Recolorable Standalone Hood" item_path = /obj/item/clothing/head/standalone_hood diff --git a/modular_skyrat/modules/modular_vending/code/games.dm b/modular_skyrat/modules/modular_vending/code/games.dm index 431425433a9..4df4e3e7ba2 100644 --- a/modular_skyrat/modules/modular_vending/code/games.dm +++ b/modular_skyrat/modules/modular_vending/code/games.dm @@ -12,6 +12,7 @@ "icon" = "star", "products" = list( /obj/item/hairbrush = 3, + /obj/item/clothing/head/hair_tie/scrunchie = 3, /obj/item/clothing/mask/holocigarette = 5, /obj/item/attachable_soulcatcher = 5, ), diff --git a/modular_skyrat/modules/opposing_force/code/equipment/gadgets.dm b/modular_skyrat/modules/opposing_force/code/equipment/gadgets.dm index 87ce925d024..472351c63d3 100644 --- a/modular_skyrat/modules/opposing_force/code/equipment/gadgets.dm +++ b/modular_skyrat/modules/opposing_force/code/equipment/gadgets.dm @@ -74,6 +74,11 @@ description = "Based on a Nanotrasen model, this powerful tool can be used as both a crowbar and a pair of wirecutters. \ In its crowbar configuration, it can be used to force open airlocks. Very useful for entering the station or its departments." +/datum/opposing_force_equipment/gadget_stealth/hair_tie + name = "Syndicate Hair Tie" + description = "An inconspicuous hair tie, able to be slung accurately. Useful to get yourself out of a sticky situation." + item_type = /obj/item/clothing/head/hair_tie/syndicate + /datum/opposing_force_equipment/gadget_stealth/jammer name = "Radio Jammer" item_type = /obj/item/jammer diff --git a/modular_skyrat/modules/salon/code/barbervend.dm b/modular_skyrat/modules/salon/code/barbervend.dm index 4d4458cbf1c..bc6d5fb1bb4 100644 --- a/modular_skyrat/modules/salon/code/barbervend.dm +++ b/modular_skyrat/modules/salon/code/barbervend.dm @@ -12,6 +12,7 @@ /obj/item/reagent_containers/spray/quantum_hair_dye = 3, /obj/item/reagent_containers/spray/baldium = 3, /obj/item/reagent_containers/spray/barbers_aid = 3, + /obj/item/clothing/head/hair_tie = 3, /obj/item/dyespray = 5, /obj/item/hairbrush = 3, /obj/item/hairbrush/comb = 3, diff --git a/modular_skyrat/modules/salon/code/hair_tie.dm b/modular_skyrat/modules/salon/code/hair_tie.dm new file mode 100644 index 00000000000..7276071e4eb --- /dev/null +++ b/modular_skyrat/modules/salon/code/hair_tie.dm @@ -0,0 +1,147 @@ +/obj/item/clothing/head/hair_tie + name = "hair tie" + desc = "An elastic hair tie, made to hold your hair up!" + icon = 'modular_skyrat/modules/salon/icons/items.dmi' + icon_state = "hairtie" + worn_icon = 'modular_skyrat/modules/salon/icons/items.dmi' + worn_icon_state = "hair_tie_worn_no_icon" + lefthand_file = 'modular_skyrat/modules/salon/icons/items.dmi' + righthand_file = 'modular_skyrat/modules/salon/icons/items.dmi' + inhand_icon_state = "hair_tie_worn_no_icon" + w_class = WEIGHT_CLASS_TINY + custom_price = PAYCHECK_CREW * 0.2 + ///string which set_hairstyle() will read + var/picked_hairstyle + ///storage for the original hairstyle string + var/actual_hairstyle + ///which projectile object to use as flicked hair tie + var/projectile_to_fire = /obj/projectile/bullet/hair_tie + ///how long the do_after takes to flick the hair tie + var/fire_speed = 3 SECONDS + ///how big is the randomized aim radius when flicked + var/projectile_aim_radius = 30 + +/obj/item/clothing/head/hair_tie/scrunchie + name = "scrunchie" + desc = "An elastic hair tie, its fabric is velvet soft." + icon_state = "hairtie_scrunchie" + +/obj/item/clothing/head/hair_tie/plastic_beads + name = "colorful hair tie" + desc = "An elastic hair tie, adornished with colorful plastic beads." + icon_state = "hairtie_beads" + custom_materials = (list(/datum/material/plastic = SMALL_MATERIAL_AMOUNT * 5)) + +/obj/item/clothing/head/hair_tie/syndicate + name = "\improper Syndicate hair tie" + desc = "An elastic hair tie with a metal clip, brandishing the logo of the Syndicate." + icon_state = "hairtie_syndie" + fire_speed = 1.5 SECONDS + projectile_to_fire = /obj/projectile/bullet/hair_tie/syndicate + projectile_aim_radius = 0 //accurate aim + +/obj/item/clothing/head/hair_tie/examine(mob/user) + . = ..() + if(picked_hairstyle) + . += span_notice("Wearing it will change your hairstyle to '[picked_hairstyle]'.") + . += span_notice("Use in hand to pick a new hairstyle.") + . += span_notice("Alt-click [src] to fling it.") + +/obj/item/clothing/head/hair_tie/mob_can_equip(mob/living/carbon/human/user, slot, disable_warning, bypass_equip_delay_self, ignore_equipped, indirect_action) + if(user.hairstyle == "Bald") //could create a list of the bald hairstyles to check + return FALSE + return ..() + +/obj/item/clothing/head/hair_tie/attack_self(mob/user) + var/hair_id = tgui_input_list(user, "How does your hair look when its up?", "Pick!", GLOB.hairstyles_list) + if(!hair_id || hair_id == "Bald") + balloon_alert(user, "error!") + return + balloon_alert(user, "[hair_id]") + picked_hairstyle = hair_id + +/obj/item/clothing/head/hair_tie/equipped(mob/living/carbon/human/user, slot) + . = ..() + if(!ishuman(user) || !(slot_flags & slot)) + return + if(!picked_hairstyle) + return + user.visible_message( + span_notice("[user.name] ties up [user.p_their()] hair."), + span_notice("You tie up your hair!"), + ) + actual_hairstyle = user.hairstyle + user.set_hairstyle(picked_hairstyle, update = TRUE) + +/obj/item/clothing/head/hair_tie/dropped(mob/living/carbon/human/user) + . = ..() + if(!ishuman(user)) + return + if(!picked_hairstyle || !actual_hairstyle) + return + user.visible_message( + span_notice("[user.name] takes [src] out of [user.p_their()] hair."), + span_notice("You let down your hair!"), + ) + user.set_hairstyle(actual_hairstyle, update = TRUE) + actual_hairstyle = null + +/obj/item/clothing/head/hair_tie/AltClick(mob/living/user) + . = ..() + if(!(user.get_slot_by_item(src) == ITEM_SLOT_HANDS)) + balloon_alert(user, "hold in-hand!") + return + user.visible_message( + span_danger("[user.name] puts [src] around [user.p_their()] fingers, beginning to flick it!"), + span_notice("You try to flick [src]!"), + ) + flick_hair_tie(user) + +///This proc flicks the hair tie out of the player's hand, tripping the target hit for 1 second +/obj/item/clothing/head/hair_tie/proc/flick_hair_tie(mob/living/user) + if(!do_after(user, fire_speed, src)) + return + //build the projectile + var/obj/projectile/bullet/hair_tie/proj = new projectile_to_fire (drop_location()) + //clone some vars + proj.name = name + proj.icon_state = icon_state + //add projectile_drop + proj.AddElement(/datum/element/projectile_drop, type) + //aim and fire + proj.firer = user + proj.fired_from = user + proj.fire((dir2angle(user.dir) + rand(-projectile_aim_radius, projectile_aim_radius))) + playsound(src, 'sound/weapons/effects/batreflect.ogg', 25, TRUE) + //get rid of what we just launched to let projectile_drop spawn a new one + qdel(src) + +/obj/projectile/bullet/hair_tie + icon = 'modular_skyrat/modules/salon/icons/items.dmi' + icon_state = "hairtie" + hitsound = 'sound/weapons/genhit.ogg' + damage = 0 //its just about the knockdown + sharpness = NONE + shrapnel_type = NONE //no embedding pls + impact_effect_type = null + ricochet_chance = 0 + range = 7 + knockdown = 1 SECONDS + +/obj/projectile/bullet/hair_tie/syndicate + damage = 10 //getting hit with this one fucking sucks + stamina = 30 + eyeblur = 2 SECONDS + jitter = 8 SECONDS + +/datum/design/plastic_hair_tie + name = "Plastic Hair Tie" + id = "plastic_hair_tie" + build_type = PROTOLATHE | AWAY_LATHE | AUTOLATHE | COLONY_FABRICATOR + materials = list(/datum/material/plastic = SMALL_MATERIAL_AMOUNT * 5) + build_path = /obj/item/clothing/head/hair_tie/plastic_beads + category = list( + RND_CATEGORY_INITIAL, + RND_CATEGORY_EQUIPMENT + RND_SUBCATEGORY_EQUIPMENT_SERVICE, + ) + departmental_flags = DEPARTMENT_BITFLAG_SERVICE diff --git a/modular_skyrat/modules/salon/icons/items.dmi b/modular_skyrat/modules/salon/icons/items.dmi index 7edbc40bc3f..908f28fdc6f 100644 Binary files a/modular_skyrat/modules/salon/icons/items.dmi and b/modular_skyrat/modules/salon/icons/items.dmi differ diff --git a/tgstation.dme b/tgstation.dme index e6e0476c82a..3cdf9928df7 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -7841,6 +7841,7 @@ #include "modular_skyrat\modules\salon\code\barbervend.dm" #include "modular_skyrat\modules\salon\code\clothing.dm" #include "modular_skyrat\modules\salon\code\fur_dyer.dm" +#include "modular_skyrat\modules\salon\code\hair_tie.dm" #include "modular_skyrat\modules\salon\code\hand_dryer.dm" #include "modular_skyrat\modules\salon\code\misc_items.dm" #include "modular_skyrat\modules\salon\code\pipette.dm"