From c0a02db78339d3ceb6f38be8e89a7c413da8a7a5 Mon Sep 17 00:00:00 2001 From: blzimme000 Date: Fri, 18 Feb 2022 11:27:41 -0600 Subject: [PATCH] Sort and Scramble done, Game.java done (I think) --- src/com/company/GameWheel.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/com/company/GameWheel.java b/src/com/company/GameWheel.java index 089b0ca..623d675 100644 --- a/src/com/company/GameWheel.java +++ b/src/com/company/GameWheel.java @@ -62,9 +62,9 @@ public class GameWheel individual lists, then combine into big list similar to scramble method. */ ArrayList newSlices = new ArrayList<>(); - ArrayList redStuff = new ArrayList<>(sort(colorSplit(slices, "red"))); - ArrayList blueStuff = new ArrayList<>(sort(colorSplit(slices, "blue"))); - ArrayList blackStuff = new ArrayList<>(sort(colorSplit(slices, "black"))); + ArrayList redStuff = new ArrayList<>(privateSort(colorSplit(slices, "red"))); + ArrayList blueStuff = new ArrayList<>(privateSort(colorSplit(slices, "blue"))); + ArrayList blackStuff = new ArrayList<>(privateSort(colorSplit(slices, "black"))); int blackCount = 0; int blueCount = 0; int redCount = 0; @@ -159,7 +159,7 @@ public class GameWheel Collections.shuffle(list); return list; } - private ArrayList sort(ArrayList list){ + private ArrayList privateSort(ArrayList list){ for (int i = 1; i < list.size(); i++){ Slice toInsert = new Slice("toInsert", list.get(i).getPrizeAmount()); int j;