Skip to content

Commit

Permalink
Crafting urinals, noticeboards, and pod controllers (#72861)
Browse files Browse the repository at this point in the history
## About The Pull Request
Breaking down #72371 because it's... unreasonably large.
So this PR adds recipes for urinals and noticeboards, and a circuit for
pod computers.

The pod computers don't work, but you can certainly remove them without
smacking them like an animal until they fall to pieces.

## Why It's Good For The Game
Wallening compliance.

## Changelog
:cl: Tattle
qol: urinals and noticeboards can be handcrafted
qol: pod computers can be deconstructed
/:cl:

Co-authored-by: tattle <article.disaster@gmail.com>
  • Loading branch information
dragomagol and tattle committed Jan 23, 2023
1 parent 4ae3295 commit fd48108
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,11 @@
name = "Lavaland Shuttle"
build_path = /obj/machinery/computer/shuttle/mining/common

/obj/item/circuitboard/computer/emergency_pod
name = "Emergency Pod Controls"
greyscale_colors = CIRCUIT_COLOR_GENERIC
build_path = /obj/machinery/computer/shuttle/pod

/obj/item/circuitboard/computer/exoscanner_console
name = "Scanner Array Control Console"
build_path = /obj/machinery/computer/exoscanner_control
Expand Down
4 changes: 3 additions & 1 deletion code/game/objects/items/stacks/sheets/sheet_types.dm
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,8 @@ GLOBAL_LIST_INIT(metal_recipes, list ( \
new/datum/stack_recipe("voting box", /obj/structure/votebox, 15, time = 5 SECONDS, category = CAT_ENTERTAINMENT), \
new/datum/stack_recipe("pestle", /obj/item/pestle, 1, time = 5 SECONDS, category = CAT_CHEMISTRY), \
new/datum/stack_recipe("hygienebot assembly", /obj/item/bot_assembly/hygienebot, 2, time = 5 SECONDS, category = CAT_ROBOT), \
new/datum/stack_recipe("shower frame", /obj/structure/showerframe, 2, time= 2 SECONDS, category = CAT_FURNITURE)
new/datum/stack_recipe("shower frame", /obj/structure/showerframe, 2, time = 2 SECONDS, category = CAT_FURNITURE), \
new/datum/stack_recipe("urinal", /obj/item/wallframe/urinal, 2, time = 1 SECONDS, category = CAT_FURNITURE)
))

/obj/item/stack/sheet/iron
Expand Down Expand Up @@ -327,6 +328,7 @@ GLOBAL_LIST_INIT(wood_recipes, list ( \
new/datum/stack_recipe("firebrand", /obj/item/match/firebrand, 2, time = 10 SECONDS, category = CAT_TOOLS), \
new/datum/stack_recipe("bonfire", /obj/structure/bonfire, 10, time = 6 SECONDS, one_per_turf = TRUE, on_solid_ground = TRUE, category = CAT_TOOLS), \
new/datum/stack_recipe("easel", /obj/structure/easel, 5, time = 1 SECONDS, one_per_turf = TRUE, on_solid_ground = TRUE, category = CAT_ENTERTAINMENT), \
new/datum/stack_recipe("noticeboard", /obj/item/wallframe/noticeboard, 1, time = 1 SECONDS, one_per_turf = FALSE, on_solid_ground = FALSE, category = CAT_FURNITURE), \
null, \
new/datum/stack_recipe_list("pews", list(
new /datum/stack_recipe("pew (middle)", /obj/structure/chair/pew, 3, one_per_turf = TRUE, on_solid_ground = TRUE, category = CAT_FURNITURE),
Expand Down
16 changes: 15 additions & 1 deletion code/game/objects/structures/noticeboard.dm
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,25 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/noticeboard, 32)

/obj/structure/noticeboard/deconstruct(disassembled = TRUE)
if(!(flags_1 & NODECONSTRUCT_1))
new /obj/item/stack/sheet/iron (loc, 1)
if(!disassembled)
new /obj/item/stack/sheet/mineral/wood(loc)
else
new /obj/item/wallframe/noticeboard(loc)
for(var/obj/item/content in contents)
remove_item(content)
qdel(src)

/obj/item/wallframe/noticeboard
name = "notice board"
desc = "Right now it's more of a clipboard. Attach to a wall to use."
icon = 'icons/obj/stationobjs.dmi'
icon_state = "nboard00"
custom_materials = list(
/datum/material/wood = MINERAL_MATERIAL_AMOUNT,
)
result_path = /obj/structure/noticeboard
pixel_shift = 32

// Notice boards for the heads of staff (plus the qm)

/obj/structure/noticeboard/captain
Expand Down
39 changes: 28 additions & 11 deletions code/game/objects/structures/watercloset.dm
Original file line number Diff line number Diff line change
Expand Up @@ -156,14 +156,16 @@
icon_state = "urinal"
density = FALSE
anchored = TRUE
var/exposed = 0 // can you currently put an item inside
var/obj/item/hiddenitem = null // what's in the urinal
/// Can you currently put an item inside
var/exposed = FALSE
/// What's in the urinal
var/obj/item/hidden_item

MAPPING_DIRECTIONAL_HELPERS(/obj/structure/urinal, 32)

/obj/structure/urinal/Initialize(mapload)
. = ..()
hiddenitem = new /obj/item/food/urinalcake
hidden_item = new /obj/item/food/urinalcake

/obj/structure/urinal/attack_hand(mob/living/user, list/modifiers)
. = ..()
Expand All @@ -182,21 +184,21 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/urinal, 32)
to_chat(user, span_warning("You need a tighter grip!"))

else if(exposed)
if(!hiddenitem)
if(!hidden_item)
to_chat(user, span_warning("There is nothing in the drain holder!"))
else
if(ishuman(user))
user.put_in_hands(hiddenitem)
user.put_in_hands(hidden_item)
else
hiddenitem.forceMove(get_turf(src))
to_chat(user, span_notice("You fish [hiddenitem] out of the drain enclosure."))
hiddenitem = null
hidden_item.forceMove(get_turf(src))
to_chat(user, span_notice("You fish [hidden_item] out of the drain enclosure."))
hidden_item = null
else
..()

/obj/structure/urinal/attackby(obj/item/I, mob/living/user, params)
if(exposed)
if (hiddenitem)
if (hidden_item)
to_chat(user, span_warning("There is already something in the drain enclosure!"))
return
if(I.w_class > 1)
Expand All @@ -205,7 +207,7 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/urinal, 32)
if(!user.transferItemToLoc(I, src))
to_chat(user, span_warning("[I] is stuck to your hand, you cannot put it in the drain enclosure!"))
return
hiddenitem = I
hidden_item = I
to_chat(user, span_notice("You place [I] into the drain enclosure."))
else
return ..()
Expand All @@ -222,14 +224,29 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/urinal, 32)
exposed = !exposed
return TRUE

/obj/structure/urinal/deconstruct(disassembled = TRUE)
if(!(flags_1 & NODECONSTRUCT_1))
new /obj/item/wallframe/urinal(loc)
qdel(src)

/obj/item/wallframe/urinal
name = "urinal frame"
desc = "An unmounted urinal. Attach it to a wall to use."
icon = 'icons/obj/watercloset.dmi'
icon_state = "urinal"
result_path = /obj/structure/urinal
pixel_shift = 32

/obj/item/food/urinalcake
name = "urinal cake"
desc = "The noble urinal cake, protecting the station's pipes from the station's pee. Do not eat."
icon = 'icons/obj/weapons/items_and_weapons.dmi'
icon_state = "urinalcake"
w_class = WEIGHT_CLASS_TINY
food_reagents = list(/datum/reagent/chlorine = 3, /datum/reagent/ammonia = 1)
food_reagents = list(
/datum/reagent/chlorine = 3,
/datum/reagent/ammonia = 1,
)
foodtypes = TOXIC | GROSS

/obj/item/food/urinalcake/attack_self(mob/living/user)
Expand Down
1 change: 1 addition & 0 deletions code/modules/shuttle/emergency.dm
Original file line number Diff line number Diff line change
Expand Up @@ -594,6 +594,7 @@
possible_destinations = "pod_asteroid"
icon = 'icons/obj/terminals.dmi'
icon_state = "dorm_available"
circuit = /obj/item/circuitboard/computer/emergency_pod
light_color = LIGHT_COLOR_BLUE
density = FALSE

Expand Down

0 comments on commit fd48108

Please sign in to comment.