Skip to content

Commit 5d5dfac

Browse files
committed
Fixes part runtimes
1 parent 2c3fead commit 5d5dfac

File tree

16 files changed

+18
-18
lines changed

16 files changed

+18
-18
lines changed

code/__HELPERS/_lists.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -520,7 +520,7 @@
520520
return sortTim(record_list, order >= 0 ? GLOBAL_PROC_REF(cmp_records_asc) : GLOBAL_PROC_REF(cmp_records_dsc))
521521

522522
///sort any value in a list
523-
/proc/sort_list(list/list_to_sort, cmp=/proc/cmp_text_asc)
523+
/proc/sort_list(list/list_to_sort, cmp = GLOBAL_PROC_REF(cmp_text_asc))
524524
return sortTim(list_to_sort.Copy(), cmp)
525525

526526
///uses sort_list() but uses the var's name specifically. This should probably be using mergeAtom() instead

code/__HELPERS/sorts/InsertSort.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//simple insertion sort - generally faster than merge for runs of 7 or smaller
2-
/proc/sortInsert(list/L, cmp=/proc/cmp_numeric_asc, associative, fromIndex=1, toIndex=0)
2+
/proc/sortInsert(list/L, cmp = GLOBAL_PROC_REF(cmp_numeric_asc), associative, fromIndex=1, toIndex=0)
33
if(L && L.len >= 2)
44
fromIndex = fromIndex % L.len
55
toIndex = toIndex % (L.len+1)

code/__HELPERS/sorts/MergeSort.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//merge-sort - gernerally faster than insert sort, for runs of 7 or larger
2-
/proc/sortMerge(list/L, cmp=/proc/cmp_numeric_asc, associative, fromIndex=1, toIndex)
2+
/proc/sortMerge(list/L, cmp = GLOBAL_PROC_REF(cmp_numeric_asc), associative, fromIndex=1, toIndex)
33
if(L && L.len >= 2)
44
fromIndex = fromIndex % L.len
55
toIndex = toIndex % (L.len+1)

code/__HELPERS/sorts/TimSort.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//TimSort interface
2-
/proc/sortTim(list/L, cmp=/proc/cmp_numeric_asc, associative, fromIndex=1, toIndex=0)
2+
/proc/sortTim(list/L, cmp = GLOBAL_PROC_REF(cmp_numeric_asc), associative, fromIndex=1, toIndex=0)
33
if(L && L.len >= 2)
44
fromIndex = fromIndex % L.len
55
toIndex = toIndex % (L.len+1)

code/controllers/subsystem/garbage.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ SUBSYSTEM_DEF(garbage)
8484
var/list/dellog = list()
8585

8686
//sort by how long it's wasted hard deleting
87-
sortTim(items, cmp=/proc/cmp_qdel_item_time, associative = TRUE)
87+
sortTim(items, cmp = GLOBAL_PROC_REF(cmp_qdel_item_time), associative = TRUE)
8888
for(var/path in items)
8989
var/datum/qdel_item/I = items[path]
9090
dellog += "Path: [path]"

code/controllers/subsystem/timer.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ SUBSYSTEM_DEF(timer)
277277
return
278278

279279
// Sort all timers by time to run
280-
sortTim(alltimers, PROC_REF(cmp_timer))
280+
sortTim(alltimers, GLOBAL_PROC_REF(cmp_timer))
281281

282282
// Get the earliest timer, and if the TTR is earlier than the current world.time,
283283
// then set the head offset appropriately to be the earliest time tracked by the

code/game/gamemodes/objective.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -941,7 +941,7 @@ GLOBAL_LIST_EMPTY(possible_items_special)
941941
/datum/objective/capture,
942942
/datum/objective/absorb,
943943
/datum/objective/custom
944-
),/proc/cmp_typepaths_asc)
944+
), GLOBAL_PROC_REF(cmp_typepaths_asc))
945945

946946
for(var/T in allowed_types)
947947
var/datum/objective/X = T

code/game/objects/structures/votingbox.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@
173173
results[text] = 1
174174
else
175175
results[text] += 1
176-
sortTim(results, cmp=/proc/cmp_numeric_dsc, associative = TRUE)
176+
sortTim(results, cmp = GLOBAL_PROC_REF(cmp_numeric_dsc), associative = TRUE)
177177
if(!COOLDOWN_FINISHED(src, vote_print_cooldown))
178178
return
179179
COOLDOWN_START(src, vote_print_cooldown, 60 SECONDS)

code/modules/admin/antag_panel.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ GLOBAL_VAR(antag_prototypes)
108108
GLOB.antag_prototypes[cat_id] = list(A)
109109
else
110110
GLOB.antag_prototypes[cat_id] += A
111-
sortTim(GLOB.antag_prototypes,/proc/cmp_text_asc,associative=TRUE)
111+
sortTim(GLOB.antag_prototypes, GLOBAL_PROC_REF(cmp_text_asc), associative = TRUE)
112112

113113
var/list/sections = list()
114114
var/list/priority_sections = list()

code/modules/admin/verbs/debug.dm

+2-2
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
559559
set desc = "Display del's log of everything that's passed through it."
560560

561561
var/list/dellog = list("<B>List of things that have gone through qdel this round</B><BR><BR><ol>")
562-
sortTim(SSgarbage.items, cmp=/proc/cmp_qdel_item_time, associative = TRUE)
562+
sortTim(SSgarbage.items, cmp = GLOBAL_PROC_REF(cmp_qdel_item_time), associative = TRUE)
563563
for(var/path in SSgarbage.items)
564564
var/datum/qdel_item/I = SSgarbage.items[path]
565565
dellog += "<li><u>[path]</u><ul>"
@@ -848,7 +848,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
848848
var/list/sorted = list()
849849
for (var/source in per_source)
850850
sorted += list(list("source" = source, "count" = per_source[source]))
851-
sorted = sortTim(sorted, PROC_REF(cmp_timer_data))
851+
sorted = sortTim(sorted, GLOBAL_PROC_REF(cmp_timer_data))
852852

853853
// Now that everything is sorted, compile them into an HTML output
854854
var/output = "<table border='1'>"

code/modules/admin/verbs/ert.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@
160160
var/mob/dead/observer/potential_leader = i
161161
candidate_living_exps[potential_leader] = potential_leader.client?.get_exp_living(TRUE)
162162

163-
candidate_living_exps = sort_list(candidate_living_exps, cmp=/proc/cmp_numeric_dsc)
163+
candidate_living_exps = sort_list(candidate_living_exps, cmp = GLOBAL_PROC_REF(cmp_numeric_dsc))
164164
if(candidate_living_exps.len > ERT_EXPERIENCED_LEADER_CHOOSE_TOP)
165165
candidate_living_exps = candidate_living_exps.Cut(ERT_EXPERIENCED_LEADER_CHOOSE_TOP+1) // pick from the top ERT_EXPERIENCED_LEADER_CHOOSE_TOP contenders in playtime
166166
earmarked_leader = pick(candidate_living_exps)

code/modules/antagonists/pirate/pirate.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@
8484
//Lists notable loot.
8585
if(!cargo_hold || !cargo_hold.total_report)
8686
return "Nothing"
87-
cargo_hold.total_report.total_value = sortTim(cargo_hold.total_report.total_value, cmp = /proc/cmp_numeric_dsc, associative = TRUE)
87+
cargo_hold.total_report.total_value = sortTim(cargo_hold.total_report.total_value, cmp = GLOBAL_PROC_REF(cmp_numeric_dsc), associative = TRUE)
8888
var/count = 0
8989
var/list/loot_texts = list()
9090
for(var/datum/export/E in cargo_hold.total_report.total_value)

code/modules/asset_cache/assets/uplink.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
var/list/items = list()
99
for(var/datum/uplink_category/category as anything in subtypesof(/datum/uplink_category))
1010
categories += category
11-
categories = sortTim(categories, PROC_REF(cmp_uplink_category_desc))
11+
categories = sortTim(categories, GLOBAL_PROC_REF(cmp_uplink_category_desc))
1212

1313
var/list/new_categories = list()
1414
for(var/datum/uplink_category/category as anything in categories)

code/modules/mafia/controller.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@
531531
tally[votes[vote_type][votee]] = 1
532532
else
533533
tally[votes[vote_type][votee]] += 1
534-
sortTim(tally,/proc/cmp_numeric_dsc,associative=TRUE)
534+
sortTim(tally, GLOBAL_PROC_REF(cmp_numeric_dsc),associative=TRUE)
535535
return length(tally) ? tally[1] : null
536536

537537
/**

code/modules/ruins/lavalandruin_code/puzzle.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@
135135
return 0
136136

137137
/obj/effect/sliding_puzzle/proc/elements_in_order()
138-
return sortTim(elements,cmp=/proc/cmp_xy_desc)
138+
return sortTim(elements,cmp = GLOBAL_PROC_REF(cmp_xy_desc))
139139

140140
/obj/effect/sliding_puzzle/proc/get_base_icon()
141141
var/icon/I = new('icons/obj/puzzle.dmi')

dependencies.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
#Final authority on what's required to fully build the project
55

66
# byond version
7-
export BYOND_MAJOR=514
8-
export BYOND_MINOR=1569
7+
export BYOND_MAJOR=515
8+
export BYOND_MINOR=1633
99

1010
#rust_g git tag
1111
export RUST_G_VERSION=3.0.0

0 commit comments

Comments
 (0)