Merge branch 'master' of https://github.com/tgstation/tgstation into upstream-sync

This commit is contained in:
xPokee
2025-09-24 10:13:01 -04:00
313 changed files with 6548 additions and 4624 deletions
+7 -5
View File
@@ -281,15 +281,16 @@
* * stamp_y - Y coordinate to render the stamp in tgui.
* * rotation - Degrees of rotation for the stamp to be rendered with in tgui.
* * stamp_icon_state - Icon state for the stamp as part of overlay rendering.
* * stamp_icon_state - An alternate Icon file can be passed for the stamp as part of overlay rendering if desired
*/
/obj/item/paper/proc/add_stamp(stamp_class, stamp_x, stamp_y, rotation, stamp_icon_state)
/obj/item/paper/proc/add_stamp(stamp_class, stamp_x, stamp_y, rotation, stamp_icon_state, stamp_icon = 'icons/obj/service/bureaucracy.dmi')
var/new_stamp_datum = new /datum/paper_stamp(stamp_class, stamp_x, stamp_y, rotation)
LAZYADD(raw_stamp_data, new_stamp_datum);
if(LAZYLEN(stamp_cache) > MAX_PAPER_STAMPS_OVERLAYS)
return
var/mutable_appearance/stamp_overlay = mutable_appearance('icons/obj/service/bureaucracy.dmi', "paper_[stamp_icon_state]", appearance_flags = KEEP_APART | RESET_COLOR)
var/mutable_appearance/stamp_overlay = mutable_appearance(stamp_icon, "paper_[stamp_icon_state]", appearance_flags = KEEP_APART | RESET_COLOR)
stamp_overlay.pixel_w = rand(-2, 2)
stamp_overlay.pixel_z = rand(-3, 2)
add_overlay(stamp_overlay)
@@ -441,7 +442,7 @@
if(writing_stats["interaction_mode"] == MODE_STAMPING)
if(!user.can_read(src) || user.is_blind())
//The paper's stampable window area is assumed approx 300x400
add_stamp(writing_stats["stamp_class"], rand(0, 300), rand(0, 400), rand(0, 360), writing_stats["stamp_icon_state"])
add_stamp(writing_stats["stamp_class"], rand(0, 300), rand(0, 400), rand(0, 360), writing_stats["stamp_icon_state"], stamp_icon = writing_stats["stamp_icon"])
user.visible_message(span_notice("[user] blindly stamps [src] with \the [attacking_item]!"))
to_chat(user, span_notice("You stamp [src] with \the [attacking_item] the best you can!"))
playsound(src, 'sound/items/handling/standard_stamp.ogg', 50, vary = TRUE)
@@ -464,7 +465,7 @@
if(!user.can_read(src) || user.is_blind()) // Just leftclick instead
return NONE
add_stamp(writing_stats["stamp_class"], rand(1, 300), rand(1, 400), stamp_icon_state = writing_stats["stamp_icon_state"])
add_stamp(writing_stats["stamp_class"], rand(1, 300), rand(1, 400), stamp_icon_state = writing_stats["stamp_icon_state"], stamp_icon = writing_stats["stamp_icon"])
user.visible_message(
span_notice("[user] quickly stamps [src] with [tool] without looking."),
span_notice("You quickly stamp [src] with [tool] without looking."),
@@ -617,12 +618,13 @@
var/stamp_y = text2num(params["y"])
var/stamp_rotation = text2num(params["rotation"])
var/stamp_icon_state = stamp_info["stamp_icon_state"]
var/stamp_icon = stamp_info["stamp_icon"]
if (LAZYLEN(raw_stamp_data) >= MAX_PAPER_STAMPS)
to_chat(usr, pick("You try to stamp but you miss!", "There is nowhere else you can stamp!"))
return TRUE
add_stamp(stamp_class, stamp_x, stamp_y, stamp_rotation, stamp_icon_state)
add_stamp(stamp_class, stamp_x, stamp_y, stamp_rotation, stamp_icon_state, stamp_icon)
user.visible_message(span_notice("[user] stamps [src] with \the [holding.name]!"), span_notice("You stamp [src] with \the [holding.name]!"))
playsound(src, 'sound/items/handling/standard_stamp.ogg', 50, vary = TRUE)
+1
View File
@@ -24,6 +24,7 @@
return list(
interaction_mode = MODE_STAMPING,
stamp_icon_state = icon_state,
stamp_icon = icon,
stamp_class = sheet.icon_class_name(icon_state)
)