From fa39d8bfe1bae994ced4fb56df4058adaf8bd607 Mon Sep 17 00:00:00 2001 From: Cyberboss Date: Tue, 11 Apr 2017 09:32:13 -0400 Subject: [PATCH] Corrects incorrect shuffles --- code/game/gamemodes/blob/theblob.dm | 2 +- code/game/gamemodes/cult/runes.dm | 2 +- code/game/gamemodes/traitor/double_agents.dm | 2 +- code/game/gamemodes/wizard/raginmages.dm | 2 +- code/modules/admin/verbs/one_click_antag.dm | 2 +- code/modules/events/ghost_role.dm | 2 +- code/modules/events/wizard/shuffle.dm | 10 +++++----- code/modules/games/cas.dm | 2 +- .../simple_animal/hostile/megafauna/bubblegum.dm | 2 +- 9 files changed, 13 insertions(+), 13 deletions(-) diff --git a/code/game/gamemodes/blob/theblob.dm b/code/game/gamemodes/blob/theblob.dm index 1931629e62a..e8bfbb23bb5 100644 --- a/code/game/gamemodes/blob/theblob.dm +++ b/code/game/gamemodes/blob/theblob.dm @@ -99,7 +99,7 @@ var/list/blobs_to_affect = list() for(var/obj/structure/blob/B in urange(claim_range, src, 1)) blobs_to_affect += B - shuffle(blobs_to_affect) + shuffle_inplace(blobs_to_affect) for(var/L in blobs_to_affect) var/obj/structure/blob/B = L if(!B.overmind && !istype(B, /obj/structure/blob/core) && prob(30)) diff --git a/code/game/gamemodes/cult/runes.dm b/code/game/gamemodes/cult/runes.dm index e58a7912b2a..f471dc3477c 100644 --- a/code/game/gamemodes/cult/runes.dm +++ b/code/game/gamemodes/cult/runes.dm @@ -124,7 +124,7 @@ structure_check() searches for nearby cultist structures required for the invoca if(allow_excess_invokers) chanters += invokers else - shuffle(invokers) + shuffle_inplace(invokers) for(var/i in 1 to req_cultists) var/L = pick_n_take(invokers) if(L) diff --git a/code/game/gamemodes/traitor/double_agents.dm b/code/game/gamemodes/traitor/double_agents.dm index 75aaa873d69..a273b946b6d 100644 --- a/code/game/gamemodes/traitor/double_agents.dm +++ b/code/game/gamemodes/traitor/double_agents.dm @@ -65,7 +65,7 @@ // As soon as we get 3 or 4 extra latejoin traitors, make them traitors and kill each other. if(late_joining_list.len >= rand(3, 4)) // True randomness - shuffle(late_joining_list) + shuffle_inplace(late_joining_list) // Reset the target_list, it'll be used again in force_traitor_objectives target_list = list() diff --git a/code/game/gamemodes/wizard/raginmages.dm b/code/game/gamemodes/wizard/raginmages.dm index c9831d83471..01eb8a52c49 100644 --- a/code/game/gamemodes/wizard/raginmages.dm +++ b/code/game/gamemodes/wizard/raginmages.dm @@ -117,7 +117,7 @@ mages_made-- return else - shuffle(candidates) + shuffle_inplace(candidates) for(var/mob/i in candidates) if(!i || !i.client) continue //Dont bother removing them from the list since we only grab one wizard diff --git a/code/modules/admin/verbs/one_click_antag.dm b/code/modules/admin/verbs/one_click_antag.dm index 0f2ce94d31d..d7b06ee9c87 100644 --- a/code/modules/admin/verbs/one_click_antag.dm +++ b/code/modules/admin/verbs/one_click_antag.dm @@ -224,7 +224,7 @@ var/agentcount = 0 for(var/i = 0, i 1) diff --git a/code/modules/games/cas.dm b/code/modules/games/cas.dm index 4cc32d9d6ad..c34325c9041 100644 --- a/code/modules/games/cas.dm +++ b/code/modules/games/cas.dm @@ -51,7 +51,7 @@ P.name = "Blank Card" P.card_icon = "cas_white" cards += P - shuffle(cards) // distribute blank cards throughout deck + shuffle_inplace(cards) // distribute blank cards throughout deck ..() /obj/item/toy/cards/deck/cas/attack_hand(mob/user) diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm index 24b8b9b1ee6..2e64ee526e7 100644 --- a/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm +++ b/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm @@ -326,7 +326,7 @@ Difficulty: Hard pools_to_remove = get_pools(get_turf(target), 1) pools -= pools_to_remove if(pools.len) - shuffle(pools) + shuffle_inplace(pools) found_bloodpool = pick(pools) if(found_bloodpool) visible_message("[src] sinks into the blood...")