Tutorial states implemented and working. Game currently prints to terminal the "tutorial text". Next step is to create display on application for these text. Game ends when tutorial ends. Fixed game not loading xml issue. #story[1189]
parent
28ec4b9246
commit
d2d5ae62eb
@ -0,0 +1,66 @@
|
||||
package visualiser.enums;
|
||||
|
||||
import javafx.scene.input.KeyCode;
|
||||
import network.Messages.BoatAction;
|
||||
import network.Messages.Enums.BoatActionEnum;
|
||||
import visualiser.gameController.Keys.ControlKey;
|
||||
import static visualiser.app.App.keyFactory;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
/**
|
||||
* Created by zwu18 on 10/09/17.
|
||||
*/
|
||||
public enum TutorialState {
|
||||
|
||||
|
||||
|
||||
// keyState.put("Z", new ZoomInKey());
|
||||
// keyState.put("X", new ZoomOutKey());
|
||||
// keyState.put("SPACE", new VMGKey());
|
||||
// keyState.put("SHIFT", new SailsToggleKey());
|
||||
// keyState.put("ENTER", new TackGybeKey());
|
||||
// keyState.put("UP", new UpWindKey());
|
||||
// keyState.put("DOWN", new DownWindKey());
|
||||
|
||||
/**
|
||||
* State for upwind in tutorial
|
||||
*/
|
||||
UPWIND(BoatActionEnum.UPWIND),
|
||||
|
||||
/**
|
||||
* State for downwind in tutorial
|
||||
*/
|
||||
DOWNWIND(BoatActionEnum.DOWNWIND),
|
||||
|
||||
/**
|
||||
* State for tacking/gybing in tutorial
|
||||
*/
|
||||
TACKGYBE(BoatActionEnum.TACK_GYBE),
|
||||
|
||||
/**
|
||||
* State for vmg in tutorial
|
||||
*/
|
||||
VMG(BoatActionEnum.AUTO_PILOT),
|
||||
|
||||
/**
|
||||
* State for sails-in in tutorial
|
||||
*/
|
||||
SAILSIN(BoatActionEnum.SAILS_IN),
|
||||
|
||||
/**
|
||||
* State for sails-out in tutorial
|
||||
*/
|
||||
SAILSOUT(BoatActionEnum.SAILS_OUT);
|
||||
|
||||
private BoatActionEnum action;
|
||||
|
||||
TutorialState(BoatActionEnum action){
|
||||
this.action = action;
|
||||
}
|
||||
|
||||
public BoatActionEnum getAction(){
|
||||
return action;
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Reference in new issue