Skip to content
This repository was archived by the owner on May 22, 2025. It is now read-only.

Commit 8e93e47

Browse files
committed
TGS Test Merge (#19968)
2 parents 913c48a + ac8f05e commit 8e93e47

File tree

49 files changed

+7067
-18
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+7067
-18
lines changed

_maps/RandomRuins/StationRuins/BoxStation/engine_reactor.dmm

Lines changed: 2509 additions & 0 deletions
Large diffs are not rendered by default.

_maps/RandomRuins/StationRuins/MetaStation/meta_reactor.dmm

Lines changed: 2477 additions & 0 deletions
Large diffs are not rendered by default.

code/__DEFINES/flags.dm

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ GLOBAL_LIST_INIT(bitflags, list(1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 204
4747
#define RAD_PROTECT_CONTENTS_1 (1 << 15)
4848
/// should this object be allowed to be contaminated
4949
#define RAD_NO_CONTAMINATE_1 (1 << 16)
50+
/// Prevents most radiation on this turf from leaving it
51+
#define RAD_CONTAIN_CONTENTS (1<<17)
5052

5153
//turf-only flags
5254
#define NOJAUNT_1 (1<<0)
@@ -56,7 +58,7 @@ GLOBAL_LIST_INIT(bitflags, list(1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 204
5658
/// Blocks lava rivers being generated on the turf
5759
#define NO_LAVA_GEN_1 (1<<6)
5860
/// Blocks ruins spawning on the turf
59-
#define NO_RUINS_1 (1<<17)
61+
#define NO_RUINS_1 (1<<18)
6062

6163
//AREA FLAGS
6264
/// If blobs can spawn there and if it counts towards their score.

code/__DEFINES/logging.dm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
#define INVESTIGATE_PRESENTS "presents"
2222
#define INVESTIGATE_VIROLOGY "viro" // yogs - Adds Investigate Virology
2323
#define INVESTIGATE_HYPERTORUS "hypertorus"
24+
#define INVESTIGATE_REACTOR "reactor"
2425

2526
// Logging types for log_message()
2627
#define LOG_ATTACK (1 << 0)

code/__DEFINES/reactor.dm

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
// Index of each node in the list of nodes the reactor has
2+
#define COOLANT_INPUT_GATE 1
3+
#define MODERATOR_INPUT_GATE 2
4+
#define COOLANT_OUTPUT_GATE 3
5+
6+
#define REACTOR_TEMPERATURE_MINIMUM 400 // Minimum temperature needed to run normally
7+
#define REACTOR_TEMPERATURE_OPERATING 800 //Kelvin
8+
#define REACTOR_TEMPERATURE_CRITICAL 1000 //At this point the entire station is alerted to a meltdown. This may need altering
9+
#define REACTOR_TEMPERATURE_MELTDOWN 1200
10+
11+
#define REACTOR_HEAT_CAPACITY 6000 //How much thermal energy it takes to cool the reactor
12+
#define REACTOR_ROD_HEAT_CAPACITY 400 //How much thermal energy it takes to cool each reactor rod
13+
#define REACTOR_HEAT_EXPONENT 1.5 // The exponent used for the function for K heating
14+
#define REACTOR_HEAT_FACTOR (20 / (REACTOR_HEAT_EXPONENT**2)) //How much heat from K
15+
16+
#define REACTOR_NO_COOLANT_TOLERANCE 5 //How many process()ing ticks the reactor can sustain without coolant before slowly taking damage
17+
18+
#define REACTOR_MODERATOR_DECAY_RATE 0.1 //Don't use up ALL of the moderator, engineers need it to last a full round
19+
20+
#define REACTOR_PRESSURE_OPERATING 6000 //Kilopascals
21+
#define REACTOR_PRESSURE_CRITICAL 10000
22+
23+
#define REACTOR_MAX_CRITICALITY 5 //No more criticality than N for now.
24+
#define REACTOR_CRITICALITY_POWER_FACTOR 3000 // affects criticality from high power
25+
26+
#define REACTOR_MAX_FUEL_RODS 5 //Maximum number of fuel rods that can fit in the reactor
27+
28+
#define REACTOR_POWER_FLAVOURISER 1000 //To turn those KWs into something usable
29+
#define REACTOR_PERMEABILITY_FACTOR 500 // How effective permeability-type moderators are
30+
#define REACTOR_CONTROL_FACTOR 250 // How effective control-type moderators are
31+
32+
33+
/// Moderator effects, must be added to the moderator input for them to do anything
34+
35+
// Fuel types: increases power, at the cost of making K harder to control
36+
#define PLASMA_FUEL_POWER 1 // baseline fuel
37+
#define TRITIUM_FUEL_POWER 10 // woah there
38+
#define ANTINOBLIUM_FUEL_POWER 100 // oh god oh fuck
39+
40+
// Power types: makes the fuel have more of an effect
41+
#define OXYGEN_POWER_MOD 1 // baseline power modifier gas, optimal plasma/O2 ratio is 50/50 if you can handle the K increase from the plasma
42+
#define HYDROGEN_POWER_MOD 10 // far superior power moderator gas, if you can handle the rads
43+
44+
// Control types: increases the effectiveness of control rods, makes K easier to control
45+
#define NITROGEN_CONTROL_MOD 1 // good at controlling the reaction, but deadly rads
46+
#define CARBON_CONTROL_MOD 2 // even better control, but even worse rads
47+
#define PLUOXIUM_CONTROL_MOD 3 // best control gas, no rads!
48+
49+
// Cooling types: increases the effectiveness of coolant, exchanges more heat per process
50+
#define BZ_PERMEABILITY_MOD 1 // makes cooling more effective
51+
#define WATER_PERMEABILITY_MOD 2 // even better than BZ
52+
#define NOBLIUM_PERMEABILITY_MOD 10 // best gas for cooling
53+
54+
// Radiation types: increases radiation, lower is better
55+
#define NITROGEN_RAD_MOD 0.04 // mmm radiation
56+
#define CARBON_RAD_MOD 0.08 // even higher
57+
#define HYDROGEN_RAD_MOD 0.12 // getting a bit spicy there
58+
#define TRITIUM_RAD_MOD 0.2 // fuck that's a lot
59+
#define ANTINOBLIUM_RAD_MOD 10 // AAAAAAAAAAAAAAAAAAAA

code/__DEFINES/sound.dm

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,12 @@
1212
#define CHANNEL_VOICE_ANNOUNCE 1015
1313
#define CHANNEL_MEGAFAUNA 1014 // battle music
1414
#define CHANNEL_CHARGED_SPELL 1013
15+
#define CHANNEL_REACTOR_ALERT 1012
16+
17+
//THIS SHOULD ALWAYS BE THE LOWEST ONE!
18+
//KEEP IT UPDATED
19+
20+
#define CHANNEL_HIGHEST_AVAILABLE 1011
1521

1622
///Default range of a sound.
1723
#define SOUND_RANGE 17
@@ -24,11 +30,6 @@
2430
///The default exponent of sound falloff
2531
#define SOUND_FALLOFF_EXPONENT 6
2632

27-
//THIS SHOULD ALWAYS BE THE LOWEST ONE!
28-
//KEEP IT UPDATED
29-
30-
#define CHANNEL_HIGHEST_AVAILABLE 1013
31-
3233
#define MAX_INSTRUMENT_CHANNELS (128 * 6)
3334

3435
#define SOUND_MINIMUM_PRESSURE 10

code/__HELPERS/radiation.dm

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,13 @@
2828
/proc/radiation_pulse(atom/source, intensity, range_modifier, log=FALSE, can_contaminate=TRUE, collectable_radiation = TRUE)
2929
if(!SSradiation.can_fire)
3030
return
31-
for(var/dir in GLOB.cardinals)
32-
new /datum/radiation_wave(source, dir, intensity, range_modifier, can_contaminate, collectable_radiation)
31+
if(source && (source.flags_1 & RAD_CONTAIN_CONTENTS))
32+
return
33+
if(source?.loc && (source.loc.flags_1 & RAD_CONTAIN_CONTENTS))
34+
return
35+
if(intensity >= RAD_BACKGROUND_RADIATION)
36+
for(var/dir in GLOB.cardinals)
37+
new /datum/radiation_wave(source, dir, intensity, range_modifier, can_contaminate, collectable_radiation)
3338

3439
var/list/things = get_rad_contents(source) //copypasta because I don't want to put special code in waves to handle their origin
3540
for(var/k in 1 to things.len)

code/_globalvars/lists/objects.dm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ GLOBAL_LIST_EMPTY(airlocks) //list of all airlocks
44
GLOBAL_LIST_EMPTY(mechas_list) //list of all mechs. Used by hostile mobs target tracking.
55
GLOBAL_LIST_EMPTY(shuttle_caller_list) //list of all communication consoles and AIs, for automatic shuttle calls when there are none.
66
GLOBAL_LIST_EMPTY(machines) //NOTE: this is a list of ALL machines now. The processing machines list is SSmachine.processing !
7+
GLOBAL_LIST_EMPTY(lights) //list of all light bulbs
78
GLOBAL_LIST_EMPTY(navigation_computers) //list of all /obj/machinery/computer/camera_advanced/shuttle_docker
89
GLOBAL_LIST_EMPTY(syndicate_shuttle_boards) //important to keep track of for managing nukeops war declarations.
910
GLOBAL_LIST_EMPTY(navbeacons) //list of all bot nagivation beacons, used for patrolling.

code/datums/components/crafting/recipes.dm

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -850,3 +850,18 @@
850850
)
851851
result = /obj/item/reagent_containers/food/snacks/bait/wild
852852
category = CAT_BAIT
853+
854+
// It can't run without fuel rods (cargo only) so this shouldn't be a problem
855+
/datum/crafting_recipe/reactor_frame
856+
name = "Nuclear Reactor Frame"
857+
reqs = list(
858+
/obj/item/stack/sheet/plasteel = 20,
859+
/obj/item/stack/sheet/metal = 50,
860+
/obj/item/stack/cable_coil = 10,
861+
/obj/item/pipe = 3,
862+
/obj/item/electronics/advanced_airlock_controller = 1
863+
)
864+
tool_behaviors = list(TOOL_WELDER)
865+
result = /obj/structure/reactor_frame
866+
category = CAT_STRUCTURES
867+
time = 10 SECONDS

code/game/atoms.dm

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -814,6 +814,10 @@
814814
* Default behaviour is to send COMSIG_ATOM_RAD_ACT and return
815815
*/
816816
/atom/proc/rad_act(strength, collectable_radiation)
817+
if(flags_1 & RAD_CONTAIN_CONTENTS)
818+
return
819+
if(loc && (loc.flags_1 & RAD_CONTAIN_CONTENTS))
820+
return
817821
SEND_SIGNAL(src, COMSIG_ATOM_RAD_ACT, strength, collectable_radiation)
818822

819823
/**

0 commit comments

Comments
 (0)