Commit Graph
452 Commits
Author SHA1 Message Date
Fan-Wu Yang 70d5447e88 Moving stuff from school pc to home 2017-08-13 23:03:16 +12:00
Fan-Wu Yang 8999cddf8b Pre merge commit 2017-08-13 22:16:16 +12:00
hba56 dc9317fe2e remove system.out statments
#story[1101]
2017-08-13 19:33:46 +12:00
hba56 67bb7b81dc Merge remote-tracking branch 'origin/story68' into story68 2017-08-13 19:10:31 +12:00
hba56 0d786f381b fix for boats finishing the race
#story[1101]
2017-08-13 19:10:16 +12:00
hba56 2acc36225e Fix for placement of invis gates and checks that boats pass through these gates
-see wiki on rounding
#story[1101]
2017-08-13 18:11:53 +12:00
Jessica Syder 8b1561cdc7 Fixed nullpointer when boat passes finish line.
- Added a condition in calculateBearingToNextMethod to avoid nullpointer
2017-08-13 16:08:14 +12:00
Fan-Wu Yang 820898d92c pushed work from school computer to do at home 2017-08-13 16:02:33 +12:00
hba56 f90648e4ce Fixing a silly mistake where starboard side rounding checks for a port side rounding (Thank goodness for documenting manual tests)
#story[1101]
2017-08-12 23:40:28 +12:00
Fan-Wu Yang 7c6f0931ba Transferring files from my laptop to desktop to work on, may be broken. 2017-08-12 23:18:54 +12:00
hba56 a05ffd023d Fixing a silly mistake where starboard side rounding checks for a port side rounding (Thank goodness for documenting manual tests)
#story[1101]
2017-08-12 22:55:25 +12:00
hba56 f386a4b989 added checks for gates and moved second rounding check to be in line with the next mark to move towards
#story[1101]
2017-08-12 22:27:27 +12:00
hba56 fe91264aec fix for the tests
#story[1101]
2017-08-12 21:10:31 +12:00
fjc40 89b0aa8b77 Implemented MessageRouter.
Added ConnectionToServerCommandFactory, and JoinSuccessfulCommand, RaceParticipantsFullCOmmand, ServerFullCommand.
Added IncomingHeartBeatCommandFactory, and IncomingHeartBeatCommand.
Added ConnectionToServerState, which represents the client's connection state to server.
Renamed VisualiserInput to VisualiserRaceController.
Added ConnectionToServer, which tracks the client's connection to server.
Added ConnectionToServerController, which accepts JoinAcceptance messages, turns them into commands, and passes them to ConnectionToServer.
Added IncomingHeartBeatService, which tracks the heart beat status of the connection.
Added IncomingHeartBeatController, which accepts HeartBeat messages, turns them into commands, and passes them to IncomingHeartBeatService.
Refactored ServerConnection a bit.
#story[1095]
2017-08-12 19:58:47 +12:00
zwu18 a31eb078a6 Created a splash screen for application. 2017-08-12 16:27:12 +12:00
hba56 62e37489ee starboard rounding update
#story[1101]
2017-08-12 03:41:50 +12:00
hba56 d70a711a3d 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
2017-08-12 03:26:28 +12:00
hba56 499a409d4f 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
2017-08-12 03:24:20 +12:00
zwu18 848edfc6a4 Removed commented out code. Merged master in.
#story[1097]
2017-08-12 03:20:21 +12:00
zwu18 c3ea62dfee Merge branch 'master' into CommandFactory
# 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
#	racevisionGame/src/main/java/visualiser/gameController/ControllerServer.java
2017-08-12 03:18:24 +12:00
zwu18 9c902dab46 Added javadoc to classes.
#story[1097]
2017-08-12 02:11:23 +12:00
fjc40 6e5fb62880 Added REQUEST_RECEIVED and DECLINED to ConnnectionStateEnum.
#story[1095]
2017-08-12 01:05:45 +12:00
fjc40 41b0a5d7f7 Merge branch 'story_61' of eng-git.canterbury.ac.nz:seng302-2017/team-7 into story_61 2017-08-11 22:38:55 +12:00
fjc40 b625b6ab05 XMLReader.readXMLFileToString no longer throws a Transformer exception. 2017-08-11 22:38:39 +12:00
zwu18 e4b72fdfeb Update appearance on client arrow.
#story[1095]
2017-08-11 20:38:54 +12:00
Connor Taylor-Brown 7474de9816 Created foundation classes and interfaces for collision architecture.
- Added Collider interface
- Added Collision class
- Added ColliderRegistry class

#story[1100]
2017-08-11 14:05:36 +12:00
fjc40 61d18f85c5 javadoc fixes. 2017-08-10 23:57:54 +12:00
fjc40 19984772c0 Merge branch 'master' into story_61
Also got client-server handshake working. Multiple clients can connect and control their own boat.
The client's boat has a larger black triangle drawn around it. Probably needs tidying up.
Added isClientBoat boolean to VisualiserBoat.

WindGenerator is now an interface, implemented by ConstantWindGenerator (useful for testing) and RandomWindGenerator. Added ConstantWindGeneratorTest.
RandomWindGenerator was formerly WindGenerator.
The WindGenerator is passed in to MockRace.

CommandFactory throws a CommandConstructionException if it cannot create a command.

MessageSerialiser and MessageDeserialiser correctly terminate on error.

Readded VisualiserInput's switch statement in the main loop, pending a refactor.

Removed the sleep statement from LobbyController - it was blocking javaFX thread.

Lobby.fxml: moved buttons and text input into grid panes, so they don't break when you resize screen.

Added some test object creation functions in several test classes (MockRaceTest.createMockRace(), BoatXMLReaderTest.createBoatDataSource(), etc...).

#story[1095]
2017-08-10 23:49:21 +12:00
Joseph Gardner d8628b4289 Boats now start the race with sails out. #story[1098] 2017-08-10 13:25:57 +12:00
fjc40 130ffcbf07 Fixed some merge issues. 2017-08-10 13:16:53 +12:00
Joseph Gardner 20302496f0 Made SailsInCommand and SailsOutCommand one class. #story[1098] 2017-08-10 13:14:58 +12:00
fjc40 805c12bf41 Merge remote-tracking branch 'origin/master' into issue_28_36_decoders
# Conflicts:
#	racevisionGame/src/main/java/mock/app/ConnectionAcceptor.java
#	racevisionGame/src/main/java/mock/app/Event.java
#	racevisionGame/src/main/java/visualiser/gameController/ControllerServer.java
2017-08-10 13:12:26 +12:00
Fraser Cope 7b382e48ac Merge branch 'story63' into 'master'
63. [C, M] I'd like to be able to make small adjustments to the heading of my boat, as Gemma, either upwind or downwind.

Note: each keypress should change the boat's heading by a small amount (3 degrees?) Pressing the 'upwind' key will turn the boat's head towards the wind by that small amount, while the 'downwind' key will do the opposite. Continuing to press the downwind key when the boat is already heading straight downwind, or upwind when heading directly upwind, achieves nothing.

Acceptance criteria:

- The player boat turns towards wind a small amount for each press of the 'upwind' key.
- The player boat turns away from the wind by a small amount for each press of the 'downwind' key.
- If the boat heading is directly into wind after a series of 'upwind' keypresses, the heading will continue to change in the same direction for one more keypress.
- Substitute 'downwind' for 'upwind' for the downwind case.


See merge request !21
2017-08-10 12:57:21 +12:00
Jessica Syder 321dcde72f Implemented luffing sail without image (yet).
- Added sailsLuff image property
- Displayed luffing sail in correct position and angle

#story[1098]
2017-08-10 12:49:00 +12:00
fjc40 39b5cc2edc MockBoat has autoVMG disabled by default.
Wind/Tack commands disable autoVMG. VMG command enables it.
Upwind command was turning until boat was at 0 degrees, instead of being aligned with wind direction, but that's fixed.
#story[1096]
2017-08-10 12:44:42 +12:00
Joseph Gardner 1a7152f54e Boats stop when the sails are out. Merged dev. #story[1098] 2017-08-10 12:32:05 +12:00
hba56 4da3734804 added the ability to toggle the race guide line on and off
#story[1087]
2017-08-10 12:17:19 +12:00
fjc40 7cc39abe57 WIP. Probably need to cherry pick stuff out of here.
Added ClientConnection and server-side handshake.
Added MessageSerialiser and Deserialiser.
#story[1095]
2017-08-10 12:13:40 +12:00
Joseph Gardner 1302769a50 Merge branch 'Development' into story_64_sails
# Conflicts:
#	racevisionGame/src/main/java/mock/model/commandFactory/CommandFactory.java
#	racevisionGame/src/main/java/visualiser/model/ResizableRaceCanvas.java
#	racevisionGame/src/test/java/mock/model/MockBoatTest.java
2017-08-10 11:56:09 +12:00
Joseph e23f20753d Merged master. Added commands for sails in and out. Added logic to stop boat from moving when sails are out. Testing if the boat stops with sails out is blocked until command factory is merged. #story[1098] 2017-08-10 09:42:59 +12:00
Joseph 41d09f587e Merge branch 'master' into story_64_sails
# Conflicts:
#	racevisionGame/src/main/java/visualiser/gameController/Keys/ControlKey.java
#	racevisionGame/src/main/java/visualiser/gameController/Keys/SailsToggleKey.java
#	racevisionGame/src/main/java/visualiser/gameController/Keys/VMGKey.java
#	racevisionGame/src/main/java/visualiser/model/ResizableRaceCanvas.java
2017-08-10 08:58:43 +12:00
hba56 74f04a13f8 Merge remote-tracking branch 'origin/Development' into Development 2017-08-09 23:27:04 +12:00
hba56 e53d72f24b compound marks now can give the mark they have that needs to be rounded this is used to draw the line around the correct mark
#story[1101]
2017-08-09 23:25:42 +12:00
Connor Taylor-Brown da9915174c Merge branch 'master' into Development 2017-08-09 23:05:07 +12:00
Connor Taylor-Brown 3cf0cf2ee0 Merge branch 'master' into story63 2017-08-09 22:56:55 +12:00
Connor Taylor-Brown 638413da1a Merge remote-tracking branch 'remotes/origin/story63' into Development 2017-08-09 22:46:26 +12:00
Jessica Syder ce973fecfe Sails are displayed correctly for all wind and active boat directions.
- Figured out the different situations that can occur using accurate points of sail
- Mathed out the rotation angle for each situation
- Manual testing carried out by running simulations
- Manual testing carried out using pen and paper

#story[1098]
2017-08-09 21:48:17 +12:00
zwu18 03713d3699 Added checkPosition into MockRace which was removed. Boat now updates legs again.
#Story[1097]
2017-08-09 16:37:29 +12:00
Connor Taylor-Brown e021dd328d Changed CompositeCommand stack to queue
#story[1096]
2017-08-08 23:56:59 +12:00
hba56 e2605c3c7c Merge remote-tracking branch 'remotes/origin/story68' into Development 2017-08-08 23:29:57 +12:00