mirror of
https://github.com/michaelrausch/Party-Parrots-At-Sea.git
synced 2026-05-09 14:28:43 +00:00
Implemented boats spawning in parallel at the start line with spacing.
Added two more colours to support up to eight boats. #story[1117]
This commit is contained in:
@@ -6,12 +6,12 @@ import javafx.scene.paint.Color;
|
||||
* Enum for generating colours.
|
||||
*/
|
||||
public enum Colors {
|
||||
RED, PERU, SEAGREEN, GREEN, BLUE, PURPLE;
|
||||
RED, PERU, GOLD, GREEN, BLUE, PURPLE, DEEPPINK, GRAY;
|
||||
|
||||
static Integer index = 0;
|
||||
|
||||
public static Color getColor() {
|
||||
if (index == 6) {
|
||||
if (index == 8) {
|
||||
index = 0;
|
||||
}
|
||||
return Color.valueOf(values()[index++].toString());
|
||||
|
||||
@@ -406,4 +406,8 @@ public class Yacht {
|
||||
public void addLocationListener (YachtLocationListener listener) {
|
||||
locationListeners.add(listener);
|
||||
}
|
||||
|
||||
public void setLocation(GeoPoint geoPoint) {
|
||||
location = geoPoint;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user