diff --git a/code/game/objects/items/cosmetics.dm b/code/game/objects/items/cosmetics.dm index 686bd40c698..9e49a99d73b 100644 --- a/code/game/objects/items/cosmetics.dm +++ b/code/game/objects/items/cosmetics.dm @@ -1,3 +1,7 @@ +#define UPPER_LIP "Upper" +#define MIDDLE_LIP "Middle" +#define LOWER_LIP "Lower" + /obj/item/lipstick gender = PLURAL name = "red lipstick" @@ -9,6 +13,8 @@ var/open = FALSE /// Actual color of the lipstick, also gets applied to the human var/lipstick_color = COLOR_RED + /// The style of lipstick. Upper, middle, or lower lip. Default is middle. + var/style = "lipstick" /// A trait that's applied while someone has this lipstick applied, and is removed when the lipstick is removed var/lipstick_trait @@ -22,6 +28,10 @@ if(vname == NAMEOF(src, open)) update_appearance(UPDATE_ICON) +/obj/item/lipstick/examine(mob/user) + . = ..() + . += "Alt-click to change the style." + /obj/item/lipstick/update_icon_state() icon_state = "lipstick[open ? "_uncap" : null]" inhand_icon_state = "lipstick[open ? "open" : null]" @@ -35,6 +45,42 @@ colored_overlay.color = lipstick_color . += colored_overlay +/obj/item/lipstick/AltClick(mob/user) + . = ..() + if(.) + return TRUE + + if(!user.can_perform_action(src, NEED_DEXTERITY|NEED_HANDS|ALLOW_RESTING)) + return FALSE + + return display_radial_menu(user) + +/obj/item/lipstick/proc/display_radial_menu(mob/living/carbon/human/user) + var/style_options = list( + UPPER_LIP = icon('icons/hud/radial.dmi', UPPER_LIP), + MIDDLE_LIP = icon('icons/hud/radial.dmi', MIDDLE_LIP), + LOWER_LIP = icon('icons/hud/radial.dmi', LOWER_LIP), + ) + var/pick = show_radial_menu(user, src, style_options, custom_check = CALLBACK(src, PROC_REF(check_menu), user), radius = 36, require_near = TRUE) + if(!pick) + return TRUE + + switch(pick) + if(MIDDLE_LIP) + style = "lipstick" + if(LOWER_LIP) + style = "lipstick_lower" + if(UPPER_LIP) + style = "lipstick_upper" + return TRUE + +/obj/item/lipstick/proc/check_menu(mob/living/user) + if(!istype(user)) + return FALSE + if(user.incapacitated() || !user.is_holding(src)) + return FALSE + return TRUE + /obj/item/lipstick/purple name = "purple lipstick" lipstick_color = COLOR_PURPLE @@ -106,7 +152,7 @@ if(target == user) user.visible_message(span_notice("[user] does [user.p_their()] lips with \the [src]."), \ span_notice("You take a moment to apply \the [src]. Perfect!")) - target.update_lips("lipstick", lipstick_color, lipstick_trait) + target.update_lips(style, lipstick_color, lipstick_trait) return user.visible_message(span_warning("[user] begins to do [target]'s lips with \the [src]."), \ @@ -115,7 +161,7 @@ return user.visible_message(span_notice("[user] does [target]'s lips with \the [src]."), \ span_notice("You apply \the [src] on [target]'s lips.")) - target.update_lips("lipstick", lipstick_color, lipstick_trait) + target.update_lips(style, lipstick_color, lipstick_trait) //you can wipe off lipstick with paper! /obj/item/paper/attack(mob/M, mob/user) @@ -285,3 +331,7 @@ /obj/item/razor/surgery/get_surgery_tool_overlay(tray_extended) return "razor" + +#undef UPPER_LIP +#undef MIDDLE_LIP +#undef LOWER_LIP diff --git a/icons/hud/radial.dmi b/icons/hud/radial.dmi index f4c4ab7693e..447003a3584 100644 Binary files a/icons/hud/radial.dmi and b/icons/hud/radial.dmi differ diff --git a/icons/mob/human/human_face.dmi b/icons/mob/human/human_face.dmi index 6985cf07eee..6530b300aa6 100644 Binary files a/icons/mob/human/human_face.dmi and b/icons/mob/human/human_face.dmi differ