Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
 into revi
  • Loading branch information
Absolucy committed Apr 3, 2024
2 parents 2b82fcc + 494c5b0 commit cd0ac40
Show file tree
Hide file tree
Showing 29 changed files with 524 additions and 371 deletions.
2 changes: 1 addition & 1 deletion _maps/RandomRuins/SpaceRuins/shuttlerelic.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
/turf/open/floor/oldshuttle,
/area/ruin/space/has_grav/powered)
"t" = (
/obj/machinery/power/generator,
/obj/machinery/power/thermoelectric_generator,
/turf/open/floor/oldshuttle,
/area/ruin/space/has_grav/powered)
"u" = (
Expand Down
2 changes: 1 addition & 1 deletion _maps/templates/medium_shuttle4.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
/turf/open/floor/oldshuttle,
/area/ruin/powered/shuttle/medium_4)
"r" = (
/obj/machinery/power/generator,
/obj/machinery/power/thermoelectric_generator,
/turf/open/floor/oldshuttle,
/area/ruin/powered/shuttle/medium_4)
"s" = (
Expand Down
11 changes: 3 additions & 8 deletions _maps/~monkestation/RandomBars/Tram/tram_bar_beachside.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -426,8 +426,7 @@
"nN" = (
/obj/structure/ladder,
/obj/machinery/door/window/left/directional/north{
name = "Bar Backroom Access";
req_one_access = list("bar")
name = "Bar Backroom Access"
},
/obj/structure/window/reinforced/spawner/directional/west,
/obj/structure/window/reinforced/spawner/directional/east,
Expand Down Expand Up @@ -605,8 +604,7 @@
name = "Kitchen Counter Shutters"
},
/obj/machinery/door/window/left/directional/west{
name = "Kitchen";
req_one_access = list("kitchen")
name = "Kitchen"
},
/obj/effect/mapping_helpers/airlock/access/all/service/kitchen,
/turf/open/floor/wood,
Expand Down Expand Up @@ -820,7 +818,6 @@
/area/station/commons/lounge)
"zo" = (
/obj/machinery/door/window/left/directional/south{
req_one_access = list("kitchen");
name = "Kitchen"
},
/obj/effect/turf_decal/siding/wood,
Expand Down Expand Up @@ -877,8 +874,7 @@
/area/station/commons/lounge)
"AC" = (
/obj/machinery/door/window/left/directional/east{
name = "Bar";
req_one_access = list("bar")
name = "Bar"
},
/obj/effect/turf_decal/siding/wood{
dir = 4
Expand Down Expand Up @@ -1558,7 +1554,6 @@
/area/station/commons/lounge)
"TG" = (
/obj/machinery/door/window/left/directional/south{
req_one_access = list("kitchen");
name = "Kitchen Coldroom Access"
},
/obj/effect/turf_decal/siding/wood{
Expand Down
10 changes: 8 additions & 2 deletions code/__DEFINES/atmospherics/atmos_piping.dm
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,14 @@

// Ventcrawling bitflags, handled in var/vent_movement
///Allows for ventcrawling to occur. All atmospheric machines have this flag on by default. Cryo is the exception
#define VENTCRAWL_ALLOWED (1<<0)
#define VENTCRAWL_ALLOWED (1<<0)
///Allows mobs to enter or leave from atmospheric machines. On for passive, unary, and scrubber vents.
#define VENTCRAWL_ENTRANCE_ALLOWED (1<<1)
///Used to check if a machinery is visible. Called by update_pipe_vision(). On by default for all except cryo.
#define VENTCRAWL_CAN_SEE (1<<2)
#define VENTCRAWL_CAN_SEE (1<<2)

DEFINE_BITFIELD(vent_movement, list(
"Ventcrawl Allowed" = VENTCRAWL_ALLOWED,
"Ventcrawl Entrance Allowed" = VENTCRAWL_ENTRANCE_ALLOWED,
"Ventcrawl Can See" = VENTCRAWL_CAN_SEE,
))
Original file line number Diff line number Diff line change
Expand Up @@ -222,10 +222,10 @@
/datum/stock_part/manipulator = 1)
needs_anchored = FALSE

/obj/item/circuitboard/machine/generator
/obj/item/circuitboard/machine/thermoelectric_generator
name = "Thermo-Electric Generator"
greyscale_colors = CIRCUIT_COLOR_ENGINEERING
build_path = /obj/machinery/power/generator
build_path = /obj/machinery/power/thermoelectric_generator
req_components = list()

/obj/item/circuitboard/machine/ntnet_relay
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@
new /obj/item/roulette_wheel_beacon(src)
new /obj/item/storage/fancy/candle_box(src)
new /obj/item/storage/fancy/candle_box(src)
new /obj/item/choice_beacon/jukebox(src) //this line is a monkestation edit!
new /obj/item/jukebox_beacon(src) //monkestation edit
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,23 @@
name = "circulator/heat exchanger"
desc = "A gas circulator pump and heat exchanger."
icon_state = "circ-off-0"

var/active = FALSE

var/last_pressure_delta = 0
pipe_flags = PIPING_ONE_PER_TURF | PIPING_DEFAULT_LAYER_ONLY

vent_movement = VENTCRAWL_CAN_SEE
density = TRUE

circuit = /obj/item/circuitboard/machine/circulator

var/active = FALSE
var/last_pressure_delta = 0
var/flipped = 0
///Which circulator mode we are on, the generator requires one of each to work.
var/mode = CIRCULATOR_HOT
var/obj/machinery/power/generator/generator
///The generator we are connected to.
var/obj/machinery/power/thermoelectric_generator/generator

/obj/machinery/atmospherics/components/binary/circulator/Initialize(mapload)
. = ..()
AddComponent(/datum/component/simple_rotation)

/obj/machinery/atmospherics/components/binary/circulator/AltClick(mob/user)
return ..() // This hotkey is BLACKLISTED since it's used by /datum/component/simple_rotation

//default cold circ for mappers
/obj/machinery/atmospherics/components/binary/circulator/cold
mode = CIRCULATOR_COLD
Expand All @@ -49,25 +45,18 @@
return null

//Calculate necessary moles to transfer using PV = nRT
if(air2.temperature>0)
var/pressure_delta = (input_starting_pressure - output_starting_pressure)/2

var/transfer_moles = (pressure_delta*air1.volume)/(air2.temperature * R_IDEAL_GAS_EQUATION)

last_pressure_delta = pressure_delta

//Actually transfer the gas
var/datum/gas_mixture/removed = air2.remove(transfer_moles)

update_parents()

return removed

else
if(air2.temperature <= 0)
last_pressure_delta = 0
return
var/pressure_delta = (input_starting_pressure - output_starting_pressure)/2
var/transfer_moles = (pressure_delta*air1.volume)/(air2.temperature * R_IDEAL_GAS_EQUATION)
last_pressure_delta = pressure_delta
//Actually transfer the gas
var/datum/gas_mixture/removed = air2.remove(transfer_moles)
update_parents()
return removed

/obj/machinery/atmospherics/components/binary/circulator/process_atmos()
..()
update_appearance()

/obj/machinery/atmospherics/components/binary/circulator/update_icon_state()
Expand All @@ -86,13 +75,13 @@

/obj/machinery/atmospherics/components/binary/circulator/wrench_act(mob/living/user, obj/item/I)
if(!panel_open)
balloon_alert(user, "open the panel!")
return
set_anchored(!anchored)
I.play_tool_sound(src)
if(generator)
disconnectFromGenerator()
to_chat(user, span_notice("You [anchored?"secure":"unsecure"] [src]."))

balloon_alert(user, "[anchored ? "secure" : "unsecure"]")

var/obj/machinery/atmospherics/node1 = nodes[1]
var/obj/machinery/atmospherics/node2 = nodes[2]
Expand Down Expand Up @@ -145,20 +134,22 @@
if(generator)
disconnectFromGenerator()
mode = !mode
to_chat(user, span_notice("You set [src] to [mode ? "cold" : "hot"] mode."))
balloon_alert(user, "set to [mode ? "cold" : "hot"]")
return TRUE

/obj/machinery/atmospherics/components/binary/circulator/screwdriver_act(mob/user, obj/item/I)
if(..())
return TRUE
if(!anchored)
balloon_alert(user, "anchor it down!")
return
toggle_panel_open()
I.play_tool_sound(src)
to_chat(user, span_notice("You [panel_open ? "open" : "close"] the panel on [src]."))
balloon_alert(user, "panel [panel_open ? "open" : "closed"]")
return TRUE

/obj/machinery/atmospherics/components/binary/circulator/crowbar_act(mob/user, obj/item/I)
default_deconstruction_crowbar(I)
return TRUE
if(default_deconstruction_crowbar(I))
return TRUE
return ..()

/obj/machinery/atmospherics/components/binary/circulator/on_deconstruction()
if(generator)
Expand All @@ -176,19 +167,3 @@
..()
pixel_x = 0
pixel_y = 0

/obj/machinery/atmospherics/components/binary/circulator/verb/circulator_flip()
set name = "Flip"
set category = "Object"
set src in oview(1)

if(!ishuman(usr))
return

if(anchored)
to_chat(usr, span_danger("[src] is anchored!"))
return

flipped = !flipped
to_chat(usr, span_notice("You flip [src]."))
update_appearance()
2 changes: 1 addition & 1 deletion code/modules/atmospherics/machinery/pipes/layermanifold.dm
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@
normalize_cardinal_directions()
find_all_connections()

/obj/machinery/atmospherics/pipe/layer_manifold/set_piping_layer()
/obj/machinery/atmospherics/pipe/layer_manifold/set_piping_layer(new_layer)
piping_layer = PIPING_LAYER_DEFAULT

/obj/machinery/atmospherics/pipe/layer_manifold/pipeline_expansion()
Expand Down
2 changes: 2 additions & 0 deletions code/modules/mapping/mapping_helpers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@
layer = DOOR_HELPER_LAYER
late = TRUE

/* replaced in monkestation\code\modules\mapping\mapping_helpers.dm
/obj/effect/mapping_helpers/airlock/Initialize(mapload)
. = ..()
if(!mapload)
Expand All @@ -121,6 +122,7 @@
log_mapping("[src] failed to find an airlock at [AREACOORD(src)]")
else
payload(airlock)
*/

/obj/effect/mapping_helpers/airlock/LateInitialize()
. = ..()
Expand Down
Loading

0 comments on commit cd0ac40

Please sign in to comment.