Files
Aliceee2chandGitHub c7408ce841 Mapping previews tool for mapper's mapping needs (#96872)
## About The Pull Request

Makes more machinery using MAP_SWITCHes so their fancy preview icons
could be displayed in SDMM. MAP_SWITCH takes original icon+icon_state of
machinery as first argument and icon+icon_state (basically a machinery
part because the naming system, like `MAP_SWITCH("computer",
"/obj/machinery/computer/slot_machine")` ) from
icons/obj/fluff/map_previews.dmi

Adds a tool (subsystem) for that need that generates preview icons for
stuff that has overlays. To include them in preview generating you have
to set specific variable to TRUE.


## Why It's Good For The Game

Lets us do this instead of black boring consoles: 
(before)
<img width="641" height="575" alt="image"
src="https://github.com/user-attachments/assets/35fc5a19-bc24-4c02-957a-43ddef86e684"
/>
(after)
<img width="641" height="575" alt="image"
src="https://github.com/user-attachments/assets/99310823-747f-4e0a-acf8-60abcc8f2ed1"
/>


## Changelog

🆑
qol: Made machinery with overlays actually be properly displayed in SDMM
editor.
/🆑
2026-07-15 12:48:22 +00:00

46 lines
2.4 KiB
Plaintext

/obj/machinery/computer/arcade/amputation
name = "Mediborg's Amputation Adventure"
desc = "A picture of a blood-soaked medical cyborg flashes on the screen. \
The mediborg has a speech bubble that says, \"Put your hand in the machine if you aren't a <b>coward!</b>\""
icon_state = MAP_SWITCH("arcade", "/obj/machinery/computer/arcade")
circuit = /obj/item/circuitboard/computer/arcade/amputation
interaction_flags_machine = NONE //borgs can't play, but the illiterate can.
/obj/machinery/computer/arcade/amputation/attack_tk(mob/user)
return //that's a pretty damn big guillotine
/obj/machinery/computer/arcade/amputation/attack_hand(mob/living/user, list/modifiers)
. = ..()
if(!iscarbon(user))
return
to_chat(user, span_warning("You move your hand towards the machine, and begin to hesitate as a bloodied guillotine emerges from inside of it..."))
user.played_game()
var/obj/item/bodypart/chopchop = user.get_active_hand()
if(do_after(user, 5 SECONDS, target = src, extra_checks = CALLBACK(src, PROC_REF(do_they_still_have_that_hand), user, chopchop)))
playsound(src, 'sound/items/weapons/slice.ogg', 25, TRUE, -1)
to_chat(user, span_userdanger("The guillotine drops on your arm, and the machine sucks it in!"))
chopchop.dismember()
qdel(chopchop)
user.mind?.adjust_experience(/datum/skill/gaming, 100)
user.won_game()
victory_tickets(rand(6,10))
return
if(!do_they_still_have_that_hand(user, chopchop))
to_chat(user, span_warning("The guillotine drops, but your hand seems to be gone already!"))
playsound(src, 'sound/items/weapons/slice.ogg', 25, TRUE, -1)
else
to_chat(user, span_notice("You (wisely) decide against putting your hand in the machine."))
user.lost_game()
///Makes sure the user still has their starting hand, preventing the user from pulling the arm out and still getting prizes.
/obj/machinery/computer/arcade/amputation/proc/do_they_still_have_that_hand(mob/user, obj/item/bodypart/chopchop)
if(QDELETED(chopchop) || chopchop.owner != user)
return FALSE
return TRUE
///Dispenses wrapped gifts instead of arcade prizes, also known as the ancap christmas tree
/obj/machinery/computer/arcade/amputation/festive
name = "Mediborg's Festive Amputation Adventure"
desc = "A picture of a blood-soaked medical cyborg wearing a Santa hat flashes on the screen. The mediborg has a speech bubble that says, \"Put your hand in the machine if you aren't a <b>coward!</b>\""
prize_override = list(/obj/item/gift/anything = 1)