diff --git a/code/modules/mob/living/carbon/carbon_defines.dm b/code/modules/mob/living/carbon/carbon_defines.dm index 0cbbfaa151..f19fa02ab0 100644 --- a/code/modules/mob/living/carbon/carbon_defines.dm +++ b/code/modules/mob/living/carbon/carbon_defines.dm @@ -14,6 +14,8 @@ var/datum/surgery_status/op_stage = new/datum/surgery_status //Active emote/pose var/pose = null + var/pose_move = FALSE + var/image/pose_indicator var/list/chem_effects = list() var/datum/reagents/metabolism/bloodstream/bloodstr = null var/datum/reagents/metabolism/ingested/ingested = null diff --git a/code/modules/mob/living/carbon/human/emote.dm b/code/modules/mob/living/carbon/human/emote.dm index 36e82f79af..99bf1a5531 100644 --- a/code/modules/mob/living/carbon/human/emote.dm +++ b/code/modules/mob/living/carbon/human/emote.dm @@ -369,7 +369,78 @@ var/list/_simple_mob_default_emotes = list( var/datum/gender/T = GLOB.gender_datums[get_visible_gender()] - pose = strip_html_simple(tgui_input_text(src, "This is [src]. [T.he]...", "Pose", null)) + var/new_pose + var/quiet_pose = FALSE + var/include_icon = TRUE + var/list/pose_options = list() + + new_pose = strip_html_simple(tgui_input_text(src, "This is [src]. [T.he]...", "Pose", null)) + if(!new_pose) + pose = null + remove_pose_indicator() + return + + if(!read_preference(/datum/preference/toggle/tgui_input_mode)) + var/movement_test = tgui_alert(src, "Cancel Pose On Movement?", "Options", list("No", "Cancel Pose on Movement")) + if(!movement_test) + return + var/icon_test = tgui_alert(src, "Disable Posing Icon?", "Options", list("No", "Disable Pose Icon")) + if(!icon_test) + return + var/quiet_test = tgui_alert(src, "Allow Pose To Be Announced In Chat?", "Options", list("Yes", "Quiet Pose")) + if(!quiet_test) + return + pose_options |= movement_test + pose_options |= icon_test + pose_options |= quiet_test + else + pose_options = tgui_input_checkboxes(src, "Which options would you like to enable for your poses?", "Pose Options", list("Cancel Pose on Movement", "Disable Pose Icon", "Quiet Pose"), 0) + + pose_move = FALSE + for(var/o in pose_options) + if(o == "Cancel Pose on Movement") + pose_move = TRUE + if(o == "Disable Pose Icon") + include_icon = FALSE + if(o == "Quiet Pose") + quiet_pose = TRUE + + if(include_icon) + add_pose_indicator() + else + remove_pose_indicator() + + pose = new_pose + if(!quiet_pose) + visible_message("[src] [pose]") + +/mob/living/carbon/human/proc/add_pose_indicator() + if(pose_indicator) + return //No duplicating + + var/image/pose_icon = image(icon = 'icons/mob/status_indicators.dmi', icon_state = "posing") + + var/our_sprite_x = icon_expected_width * get_icon_scale_x() + + var/x_offset = our_sprite_x - 11 + var/y_offset = 2 + + pose_icon.plane = PLANE_STATUS + pose_icon.layer = HUD_LAYER + pose_icon.appearance_flags = PIXEL_SCALE|TILE_BOUND|RESET_ALPHA|RESET_TRANSFORM + pose_icon.color = chat_color + pose_icon.pixel_y = y_offset + pose_icon.pixel_x = x_offset + + pose_indicator = pose_icon + add_overlay(pose_indicator) + +/mob/living/carbon/human/proc/remove_pose_indicator() + if(!pose_indicator) + return + + cut_overlay(pose_indicator) + pose_indicator = null /mob/living/carbon/human/verb/set_flavor() set name = "Set Flavour Text" diff --git a/code/modules/mob/living/carbon/human/human_movement.dm b/code/modules/mob/living/carbon/human/human_movement.dm index 8ece68a364..96aecb3394 100644 --- a/code/modules/mob/living/carbon/human/human_movement.dm +++ b/code/modules/mob/living/carbon/human/human_movement.dm @@ -131,6 +131,11 @@ if(embedded_flag) handle_embedded_objects() //Moving with objects stuck in you can cause bad times. + if(pose && pose_move) //clear pose on movement if choosing to + pose = null + pose_move = FALSE + remove_pose_indicator() + // This calculates the amount of slowdown to receive from items worn. This does NOT include species modifiers. // It is in a seperate place to avoid an infinite loop situation with dragging mobs dragging each other. // Also its nice to have these things seperated. diff --git a/icons/mob/status_indicators.dmi b/icons/mob/status_indicators.dmi index 4456425112..c5e9a6b5bb 100644 Binary files a/icons/mob/status_indicators.dmi and b/icons/mob/status_indicators.dmi differ diff --git a/vorestation.dme b/vorestation.dme index a280bfadb8..c18bed1ad7 100644 --- a/vorestation.dme +++ b/vorestation.dme @@ -3010,12 +3010,12 @@ #include "code\modules\instruments\songs\play_synthesized.dm" #include "code\modules\integrated_electronics\_defines.dm" #include "code\modules\integrated_electronics\core\assemblies.dm" +#include "code\modules\integrated_electronics\core\circuit_serialization.dm" #include "code\modules\integrated_electronics\core\detailer.dm" #include "code\modules\integrated_electronics\core\helpers.dm" #include "code\modules\integrated_electronics\core\integrated_circuit.dm" #include "code\modules\integrated_electronics\core\pins.dm" #include "code\modules\integrated_electronics\core\printer.dm" -#include "code\modules\integrated_electronics\core\circuit_serialization.dm" #include "code\modules\integrated_electronics\core\tools.dm" #include "code\modules\integrated_electronics\core\assemblies\circuit_bug.dm" #include "code\modules\integrated_electronics\core\assemblies\clothing.dm"