Merge branch 'master' into story68
-updated port and starboard boat checks -added gps method to check if on correct side of a line -updated pos check method to make boats round marks with the new tech # Conflicts: # racevisionGame/src/main/java/mock/app/ConnectionAcceptor.java # racevisionGame/src/main/java/mock/app/Event.java # racevisionGame/src/main/java/mock/model/commandFactory/TackGybeCommand.java # racevisionGame/src/main/java/mock/model/commandFactory/VMGCommand.java
This commit is contained in:
@@ -11,8 +11,6 @@ import visualiser.gameController.Keys.ControlKey;
|
||||
import java.io.DataOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.net.Socket;
|
||||
import java.net.SocketException;
|
||||
import java.nio.ByteBuffer;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
@@ -62,7 +60,7 @@ public class ControllerClient {
|
||||
BinaryMessageEncoder binaryMessage = new BinaryMessageEncoder(MessageType.BOATACTION, System.currentTimeMillis(), 0,
|
||||
(short) encodedBoatAction.length, encodedBoatAction);
|
||||
|
||||
System.out.println("Sending out key: " + protocolCode);
|
||||
// System.out.println("Sending out key: " + protocolCode);
|
||||
outputStream.write(binaryMessage.getFullMessage());
|
||||
|
||||
} catch (InvalidMessageException e) {
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
package visualiser.gameController;
|
||||
|
||||
import mock.model.RaceLogic;
|
||||
import mock.model.commandFactory.Command;
|
||||
import mock.model.commandFactory.CommandFactory;
|
||||
import network.BinaryMessageDecoder;
|
||||
import network.Exceptions.InvalidMessageException;
|
||||
import network.MessageDecoders.BoatActionDecoder;
|
||||
@@ -12,8 +10,8 @@ import network.Messages.Enums.BoatActionEnum;
|
||||
import java.io.DataInputStream;
|
||||
import java.io.IOException;
|
||||
import java.net.Socket;
|
||||
import java.util.logging.Level;
|
||||
import java.util.Observable;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
/**
|
||||
|
||||
@@ -7,8 +7,6 @@ import visualiser.gameController.Keys.KeyFactory;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import static javafx.application.Application.launch;
|
||||
|
||||
/**
|
||||
* Class for checking what keys are currently being used
|
||||
*/
|
||||
@@ -28,7 +26,7 @@ public class InputChecker {
|
||||
ControlKey controlKey = keyFactory.getKey(codeString);
|
||||
if (controlKey != null) {
|
||||
controlKey.onAction();
|
||||
System.out.println(controlKey.toString() + " is Pressed.");
|
||||
// System.out.println(controlKey.toString() + " is Pressed.");
|
||||
}
|
||||
currentlyActiveKeys.put(codeString, true);
|
||||
}
|
||||
@@ -39,7 +37,7 @@ public class InputChecker {
|
||||
ControlKey controlKey = keyFactory.getKey(codeString);
|
||||
if (controlKey != null) {
|
||||
controlKey.onRelease();
|
||||
System.out.println(controlKey.toString() + " is Released.");
|
||||
// System.out.println(controlKey.toString() + " is Released.");
|
||||
}
|
||||
currentlyActiveKeys.remove(event.getCode().toString());
|
||||
});
|
||||
@@ -51,7 +49,7 @@ public class InputChecker {
|
||||
ControlKey controlKey = keyFactory.getKey(key);
|
||||
if (controlKey != null){
|
||||
controlKey.onHold();
|
||||
System.out.println(controlKey.toString() + " is Held.");
|
||||
// System.out.println(controlKey.toString() + " is Held.");
|
||||
}
|
||||
}
|
||||
// for (String key : InputKeys.stringKeysMap.keySet()){
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package visualiser.model;
|
||||
|
||||
|
||||
import javafx.scene.image.Image;
|
||||
import javafx.scene.paint.Color;
|
||||
import javafx.scene.paint.Paint;
|
||||
import javafx.scene.transform.Rotate;
|
||||
|
||||
Reference in New Issue
Block a user