mirror of
https://github.com/michaelrausch/Party-Parrots-At-Sea.git
synced 2026-05-09 14:28:43 +00:00
Icons now display, blink when they are about to run off, and turn off after their time out
TokenType Enum now also has a timeout construction field #story[1245]
This commit is contained in:
@@ -40,7 +40,6 @@ public class ClientYacht extends Observable {
|
||||
|
||||
@FunctionalInterface
|
||||
public interface PowerUpListener {
|
||||
|
||||
void notifyPowerUp(ClientYacht yacht, TokenType tokenType);
|
||||
}
|
||||
|
||||
|
||||
@@ -5,18 +5,21 @@ package seng302.model.token;
|
||||
* Created by wmu16 on 28/08/17.
|
||||
*/
|
||||
public enum TokenType {
|
||||
BOOST(0, "Boost"),
|
||||
HANDLING(1, "Handling"),
|
||||
BUMPER(2, "Bumper"),
|
||||
WIND_WALKER(3, "Wind Walker"),
|
||||
RANDOM(4, "Random");
|
||||
|
||||
BOOST(0, "Boost", 10_000),
|
||||
HANDLING(1, "Handling", 10_000),
|
||||
BUMPER(2, "Bumper", 10_000),
|
||||
WIND_WALKER(3, "Wind Walker", 10_000),
|
||||
RANDOM(4, "Random", 10_000);
|
||||
|
||||
private int value;
|
||||
private String name;
|
||||
private int timeout;
|
||||
|
||||
TokenType(int value, String name) {
|
||||
TokenType(int value, String name, int timeout) {
|
||||
this.value = value;
|
||||
this.name = name;
|
||||
this.timeout = timeout;
|
||||
}
|
||||
|
||||
public int getValue() {
|
||||
@@ -26,4 +29,8 @@ public enum TokenType {
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public int getTimeout() {
|
||||
return timeout;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user