Skip to content

Commit 960ffba

Browse files
authored
Merge pull request #5292 from MistakeNot4892/port/cynosure_changes
Assorted changes from Cynosure branch.
2 parents 9e6ac92 + ba4f0da commit 960ffba

File tree

82 files changed

+448
-585
lines changed

Some content is hidden

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

82 files changed

+448
-585
lines changed
Lines changed: 43 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,46 @@
11
/**Define a poster's decl and its mapper type */
22
#define DEFINE_POSTER(TYPENAME, ICONSTATE, NAME, DESC)\
33
/decl/poster_design/##TYPENAME{name = NAME; desc = DESC; icon_state = ICONSTATE;};\
4-
/obj/structure/sign/poster/##TYPENAME{poster_design = /decl/poster_design/##TYPENAME; name = NAME; icon_state = ICONSTATE;};
4+
/obj/structure/sign/poster/##TYPENAME{poster_design = /decl/poster_design/##TYPENAME; name = NAME; icon_state = ICONSTATE;};
5+
6+
#define DEFINE_STACK_SUBTYPES(MAT_ID, MAT_NAME, MAT_TYPE, STACK_TYPE, REINF_TYPE) \
7+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID { \
8+
name = "1 " + MAT_NAME; \
9+
material = /decl/material/MAT_TYPE; \
10+
reinf_material = REINF_TYPE; \
11+
amount = 1; \
12+
is_spawnable_type = TRUE; \
13+
color = parent_type::paint_color || /decl/material/MAT_TYPE::color; \
14+
} \
15+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/five { \
16+
name = "5 " + MAT_NAME; \
17+
amount = 5; \
18+
} \
19+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/ten { \
20+
name = "10 " + MAT_NAME; \
21+
amount = 10; \
22+
} \
23+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/fifteen { \
24+
name = "15 " + MAT_NAME; \
25+
amount = 15; \
26+
} \
27+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/twenty { \
28+
name = "20 " + MAT_NAME; \
29+
amount = 20; \
30+
} \
31+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/twentyfive { \
32+
name = "25 " + MAT_NAME; \
33+
amount = 25; \
34+
} \
35+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/thirty { \
36+
name = "30 " + MAT_NAME; \
37+
amount = 30; \
38+
} \
39+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/forty { \
40+
name = "40 " + MAT_NAME; \
41+
amount = 40; \
42+
} \
43+
/obj/item/stack/material/##STACK_TYPE/mapped/##MAT_ID/fifty { \
44+
name = "50 " + MAT_NAME; \
45+
amount = 50; \
46+
}

code/__defines/misc.dm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@
100100
#define AREA_FLAG_SECURITY BITFLAG(11) // Area is security for the purposes of newscaster init.
101101
#define AREA_FLAG_HIDE_FROM_HOLOMAP BITFLAG(12) // if we shouldn't be drawn on station holomaps
102102
#define AREA_FLAG_ALLOW_LEVEL_PERSISTENCE BITFLAG(13) // Whether or not this area should pass changed turfs to SSpersistence.
103+
#define AREA_FLAG_CONSTRUCTED BITFLAG(13) // Set base flooring above this area to plating.
103104

104105
//Map template flags
105106
#define TEMPLATE_FLAG_ALLOW_DUPLICATES BITFLAG(0) // Lets multiple copies of the template to be spawned

code/_helpers/visual_filters.dm

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,16 +63,19 @@
6363
if (!filter_data || !filter_data[filter_name])
6464
return
6565

66-
var/list/monkeypatched_params = params.Copy()
67-
monkeypatched_params.Insert(1, null)
6866
var/index = filter_data.Find(filter_name)
67+
if(index <= 0)
68+
return
6969

7070
// First, animate ourselves.
71-
monkeypatched_params[1] = filters[index]
71+
var/list/monkeypatched_params = params.Copy()
72+
monkeypatched_params.Insert(1, filters[index])
7273
animate(arglist(monkeypatched_params))
7374

7475
// If we're being copied by Z-Mimic, update mimics too.
7576
if (bound_overlay)
7677
for (var/atom/movable/AM as anything in get_above_oo())
78+
if(index > length(AM.filters))
79+
continue // presumably there is a z-mimic flush pending - TODO check if this would fuck with the wrong filter on the shadower
7780
monkeypatched_params[1] = AM.filters[index]
7881
animate(arglist(monkeypatched_params))

code/controllers/evacuation/evacuation.dm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@
117117
if(istype(A) && (A.area_flags & AREA_FLAG_HALLWAY))
118118
A.readyreset()
119119
emergency_evacuation = 0
120-
else if(global.using_map.emergency_shuttle_recall_message)
120+
else if(global.using_map.shuttle_recall_message)
121121
priority_announcement.Announce(global.using_map.shuttle_recall_message)
122122

123123
return 1

code/controllers/evacuation/evacuation_lifepods.dm

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@
1717
if(waiting_to_leave())
1818
return
1919
state = EVAC_IN_TRANSIT
20-
priority_announcement.Announce(replacetext(replacetext(global.using_map.emergency_shuttle_leaving_dock, "%dock_name%", "[global.using_map.dock_name]"), "%ETA%", "[round(get_eta()/60,1)] minute\s"))
20+
var/msg = global.using_map.emergency_shuttle_leaving_dock
21+
if(msg)
22+
priority_announcement.Announce(replacetext(replacetext(msg, "%dock_name%", "[global.using_map.dock_name]"), "%ETA%", "[round(get_eta()/60,1)] minute\s"))
2123
return 1
2224

2325
/datum/evacuation_controller/lifepods/available_evac_options()

code/controllers/subsystems/mapping.dm

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,10 @@ SUBSYSTEM_DEF(mapping)
176176
// With levels set up and serde complete (and levels flagged) we can do any remaining level generation.
177177
global.using_map.finalize_map_generation()
178178

179+
// Do this dead last as all gen has to run before it makes sense.
180+
for(var/datum/level_data/level in levels_by_z)
181+
level.build_area_ceilings()
182+
179183
. = ..()
180184

181185
/datum/controller/subsystem/mapping/proc/setup_data_for_levels(min_z = 1, max_z = world.maxz)

code/controllers/subsystems/processing/nano.dm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ PROCESSING_SUBSYSTEM_DEF(nano)
5050
*/
5151
/datum/controller/subsystem/processing/nano/proc/update_uis(datum/src_object)
5252
. = 0
53-
if (!src_object.open_uis)
53+
if (!src_object?.open_uis)
5454
return
5555

5656
for (var/ui_key in src_object.open_uis)

code/controllers/subsystems/shuttle.dm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ SUBSYSTEM_DEF(shuttle)
4242
while (working_shuttles.len)
4343
var/datum/shuttle/shuttle = working_shuttles[working_shuttles.len]
4444
working_shuttles.len--
45-
if(shuttle.process_state && (shuttle.Process(wait, times_fired, src) == PROCESS_KILL))
45+
if((shuttle.always_process || shuttle.process_state) && (shuttle.Process(wait, times_fired, src) == PROCESS_KILL) && !shuttle.always_process)
4646
process_shuttles -= shuttle
4747

4848
if (MC_TICK_CHECK)

code/game/area/area_abstract.dm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/area/hallway
22
name = "hallway"
33
holomap_color = HOLOMAP_AREACOLOR_HALLWAYS
4+
area_start_lit = TRUE
45

56
/area/maintenance
67
area_flags = AREA_FLAG_RAD_SHIELDED

code/game/area/areas.dm

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ var/global/list/areas = list()
1313
luminosity = 0
1414
mouse_opacity = MOUSE_OPACITY_UNCLICKABLE
1515

16+
// If true, this area will force light switches on during init.
17+
var/area_start_lit = null
18+
1619
// If true, will allow natural walls in this area to have xenoarchaeology finds in them.
1720
var/allow_xenoarchaeology_finds = TRUE
1821

0 commit comments

Comments
 (0)