mirror of
https://github.com/michaelrausch/Party-Parrots-At-Sea.git
synced 2026-05-09 06:18:44 +00:00
adjusted the way the server is receiving key presses to enable them be passed through to the game state #pair[ptg19, wmu16] #story[989]
This commit is contained in:
@@ -7,6 +7,7 @@ import seng302.models.Player;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import seng302.models.Yacht;
|
||||
import seng302.server.messages.BoatActionType;
|
||||
|
||||
/**
|
||||
* A Static class to hold information about the current state of the game (model)
|
||||
@@ -65,6 +66,22 @@ public class GameState {
|
||||
GameState.currentStage = currentStage;
|
||||
}
|
||||
|
||||
public static void updateBoat(Integer sourceId, BoatActionType actionType) {
|
||||
switch (actionType) {
|
||||
case VMG:
|
||||
break;
|
||||
case SAILS_IN:
|
||||
break;
|
||||
case SAILS_OUT:
|
||||
break;
|
||||
case TACK_GYBE:
|
||||
break;
|
||||
case UPWIND:
|
||||
break;
|
||||
case DOWNWIND:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
public static void update() {
|
||||
Long timeInterval = System.currentTimeMillis() - previousUpdateTime;
|
||||
|
||||
Reference in New Issue
Block a user