[MIRROR] Posing buffs (#11596)

Co-authored-by: SatinIsle <98125273+SatinIsle@users.noreply.github.com>
Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2025-09-09 12:19:00 -07:00
committed by GitHub
parent c1495304fe
commit 2e243b1884
5 changed files with 80 additions and 2 deletions

View File

@@ -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

View File

@@ -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"

View File

@@ -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.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@@ -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"