Commit Graph
100 Commits
Author SHA1 Message Date
Connor Taylor-Brown b8c99be201 Merge branch 'master' into storyD-3D
# Conflicts:
#	racevisionGame/src/main/java/visualiser/Controllers/RaceController.java
2017-09-05 00:17:22 +12:00
cbt24 971a061499 View3D within RaceController now tracks boat heading
- Race leaves lobby on Warning status for development
- Latest subject added is used as camera pivot

#story[1261]
2017-09-04 18:51:37 +12:00
Connor Taylor-Brown 0ee448e17d Created wrapper for controlling the position and heading of rendered 3D models.
- Updated View3D to use Subject3D wrappers instead of Shape3D
- Fixed HostController for the new architecture
- Made position and heading observable in VisualiserBoat
- Attached listeners to each VisualiserBoat in RaceController

#story[1261]
2017-09-04 01:27:29 +12:00
Connor Taylor-Brown 368bb8ddb3 Changed reporting plugin settings and specified central repository 2017-09-03 23:35:18 +12:00
Connor Taylor-Brown 3cc806dc45 Returned rotation to boat in lobby
#story[1196]
2017-08-31 01:06:33 +12:00
Connor Taylor-Brown fb7bf572d8 Changed View3D add-remove interface to an ObservableList
#story[1196]
2017-08-31 00:59:36 +12:00
Connor Taylor-Brown b6e56d815c ResizableRaceCanvas no longer depends on VisualiserRaceEvent
#story[1196]
2017-08-30 18:52:29 +12:00
Connor Taylor-Brown c2fd5c9bae Changed box to boat mesh
- Mesh needs to be rotated -90 degrees on X
- STL file has been added to assets

#story[1196]
2017-08-30 15:49:20 +12:00
Connor Taylor-Brown cc66d63096 Removed unused shapes list from View3D
#story[1196]
2017-08-30 15:18:08 +12:00
Connor Taylor-Brown bb7eb7cb44 Added adapter interface for PerspectiveCamera frustum and transformations in View3D.
- Tested interface while initialising HostController

#story[1196]
2017-08-30 15:05:08 +12:00
Connor Taylor-Brown e04f199fc7 Merge branch 'story86-3D' of https://eng-git.canterbury.ac.nz/seng302-2017/team-7 into story86-3D 2017-08-30 13:57:35 +12:00
Connor Taylor-Brown e7164d8a78 View3D perspective camera is now operational
#story[1196]
2017-08-30 13:57:15 +12:00
Connor Taylor-Brown cf838f2072 Added View3D control for rendering 3D shapes under a PerspectiveCamera, which is not currently working.
#story[1196]
2017-08-30 01:30:05 +12:00
Connor Taylor-Brown d630788a14 Merge remote-tracking branch 'remotes/origin/story77_lobby' into story86-3D 2017-08-29 22:55:07 +12:00
cbt24 1b1b0a4591 Added floating test cube in title screen initialiser
#story[1191]
2017-08-29 14:38:27 +12:00
Connor Taylor-Brown 4b3cc8e126 Created ack number generator for use by multiple services
#story[1100]
2017-08-17 11:47:54 +12:00
Connor Taylor-Brown f8150ef449 Added YachtEvent message with encoder and decoder
- Updated Encoder and Decoder factories for the new message type
- Added an enum for handling yacht event types

#story[1100]
2017-08-17 01:10:55 +12:00
cbt24 f7d0e9d466 Boats bounce during collision if pointing into collision
#story[1100]
2017-08-16 17:55:33 +12:00
cbt24 eaa0d2e82b Boats bounce away from marks.
- Changed onCollisionEnter signature to pass boat info

#story[1100]
2017-08-16 17:22:08 +12:00
cbt24 8113867576 Bubbles collision events to RaceLogic
- ColliderRegistry collects and forwards all Collision events
- RaceLogic observes the ColliderRegistry of its single Race instance

#story[1100]
2017-08-16 16:56:20 +12:00
cbt24 79f3c41d45 Moved generic ray casting to Collider abstract class
- Boat is now collider
- Collider subclasses specify their own collision ray and collision handler

#story[1100]
2017-08-16 16:21:55 +12:00
cbt24 8498701091 Removed commented-out file from master 2017-08-16 16:08:38 +12:00
cbt24 f44929f376 Spun off Locatable interface to make collision code more reusable
#story[1100]
2017-08-16 16:05:25 +12:00
cbt24 ce14e93404 Removed CI-breaking docstring 2017-08-16 15:17:15 +12:00
cbt24 f0d750cae1 Merge remote-tracking branch 'remotes/origin/master' into story66-collision
# Conflicts:
#	racevisionGame/src/main/java/mock/model/MockBoat.java
#	racevisionGame/src/main/java/mock/model/RaceLogic.java
#	racevisionGame/src/main/java/shared/model/CompoundMark.java
#	racevisionGame/src/main/java/shared/model/Race.java
#	racevisionGame/src/test/java/mock/model/MockBoatTest.java
2017-08-16 15:09:18 +12:00
cbt24 d63641c1e2 Cherry-picked multiple changes from master 2017-08-16 14:54:55 +12:00
cbt24 9ca50aa66c Ray casting now only supports distance specification.
#story[1100]
2017-08-15 14:26:43 +12:00
cbt24 7d64a43350 Allow collision checking to provide collision parameters to ray casting method
- Added tests for MockBoat collision direction and distance

#story[1100]
2017-08-15 13:47:59 +12:00
cbt24 2fbb96afd7 Created ray casting methods for MockBoat and CompoundMark
- Added ColliderRegistry to Race
- Added collision triggering to RaceLogic
- Created basic collision handlers for MockBoat and CompoundMark
2017-08-15 12:57:26 +12:00
Connor Taylor Brown ab9aeeb58f Merge branch 'CommandFactory' into 'master'
Tacking and gybing merge request

Note: this allows the player to perform a common maneuver, changing tack, quickly. The goal is to change the boat's heading from one tack to another with a single keypress.
If the boat is heading upwind, the keypress will cause the boat to tack through head-to-wind, so that the wind shifts from one side of the boat to the other. The TWA (true wind angle) after tacking should be 360-TWA(before_tacking).
Similarly for gybing if the boat is initially heading downwind, except that the boat's heading always remains away from the wind.

Acceptance criteria:

- The wind shifts from one side of the boat to the other on keypress
- When heading upwind the boat should tack on keypress
- When heading downwind the boat should gybe on keypress

[Manual test](https://eng-git.canterbury.ac.nz/seng302-2017/team-7/wikis/manual-test:-tacking-and-gybing)

See merge request !24
2017-08-15 12:06:20 +12:00
cbt24 da52082d70 Deleted duplicate method (again -.-) 2017-08-15 11:40:22 +12:00
Connor Taylor-Brown 847cd1251e Merge remote-tracking branch 'remotes/origin/master' into CommandFactory
# Conflicts:
#	racevisionGame/src/main/java/mock/model/commandFactory/TackGybeCommand.java
#	racevisionGame/src/main/java/mock/model/commandFactory/VMGCommand.java
2017-08-15 01:01:06 +12:00
Connor Taylor-Brown b97bfe62a6 Fixed documentation bugs not relevant to story. 2017-08-15 00:52:50 +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
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
Connor Taylor-Brown e021dd328d Changed CompositeCommand stack to queue
#story[1096]
2017-08-08 23:56:59 +12:00
cbt24 2920b6cf23 Removed build-breaking code from MockRace
#story[1096]
2017-08-07 16:47:25 +12:00
Connor Taylor-Brown 8ee4e84236 Merge remote-tracking branch 'remotes/origin/story63' into Development
# Conflicts:
#	racevisionGame/src/main/java/mock/model/MockBoat.java
#	racevisionGame/src/main/java/mock/model/MockRace.java
2017-08-07 15:02:13 +12:00
Connor Taylor-Brown dad4fa57c6 Fixed WindCommand not updating downwind command when moving upwind.
#story[1096]
2017-08-07 14:51:32 +12:00
Connor Taylor-Brown 55798447ab Cherry-picked CommandFactory connection between ControllerServer and RaceLogic.
#story[1096]
2017-08-07 14:25:30 +12:00
Connor Taylor-Brown e76de1cbf9 Added test for WindCommand
#story[1096]
2017-08-07 14:13:14 +12:00
Connor Taylor-Brown 554f8a2a0f Added WindCommand and multiple command execution to RaceLogic
- Dispatch commands with CompositeCommand
- Single WindCommand handles upwind and downwind logic
- Changed key bindings as Mac lacks PgUp PgDn
- ControllerServer is observable, RaceLogic updates CompositeCommand as observer
2017-08-04 23:08:07 +12:00
Connor Taylor-Brown 425cc7f91f Changed ControlKey to use BoatActionEnum instead of magic numbers. 2017-08-04 21:27:53 +12:00
Connor Taylor-Brown 851bbb4fde Merged branch "RaceFactory" with master 2017-08-03 23:03:15 +12:00
Connor Taylor-Brown c83442761c Implemented Factory for Command objects and fixed Command Pattern implementation.
- Commands now have standard 0-parameter execute method
- Commands are created by CommandFactory

#story[1094]
2017-08-03 17:54:03 +12:00
Connor Taylor-Brown c8621a7be5 Merge branch 'RaceFactory' of https://eng-git.canterbury.ac.nz/seng302-2017/team-7 into RaceFactory 2017-08-03 09:01:27 +12:00
Connor Taylor-Brown 2672c2b13b Separated RaceLogic from MockRace
- MockRace satisfies refactor requirement for RaceState
- VisualiserRace directly implements Runnable to remove method from MockRace

#story[1094]
2017-08-03 00:32:17 +12:00
Connor Taylor-Brown 0466292bd0 Partially removed VMG optimisation, separated server-specific functionality
from MockRace into RaceServer.

#story[1094]
2017-08-02 23:39:13 +12:00
cbt24 9249e74e3a Merge remote-tracking branch 'origin/RaceFactory' into RaceFactory
# Conflicts:
#	racevisionGame/src/main/java/mock/model/MockRace.java
#	racevisionGame/src/main/java/mock/model/RaceState.java
2017-08-02 13:58:26 +12:00
cbt24 a4592a10e6 Removed boundary checking logic to clean up MockRace before split
story[1094]
2017-08-02 13:51:07 +12:00
Connor Taylor-Brown 0352e3310d Set up Boat Action Message encoding
- Fixed command number for sails out

#story[1089]
2017-07-27 00:48:19 +12:00
Connor Taylor-Brown e670ded66d ControllerClient can retrieve valid protocol code from each key press
- ControlKey now includes protocolCode property
- RaceController now fires action with each key press
- Shift toggles sail state appropriately

#story[1089]
2017-07-26 23:40:39 +12:00
Connor Taylor-Brown 86e8cb7560 Refactored KeyFactory to ensure single instance of each key state handler.
#story[1089]
2017-07-26 23:22:05 +12:00
Connor Taylor-Brown cc264f318e Added ControllerClient and ControllerServer
- StartController sets up client-wide ControllerClient on socket to game server.
- RaceController now calls ControllerClient.sendKey with each keypress
- ConnectionAcceptor runs ControllerServer for each successfully connected client

#story[1089]
2017-07-26 22:57:01 +12:00
Connor Taylor-Brown 9a76fa592c Added keyboard handling to RaceController
- Capture each KeyEvent with EventFilter over SplitPane race container

#story[1010]
2017-07-26 17:22:54 +12:00
Connor Taylor-Brown 7e3e865563 Host starts with button in ConnectionController
- Converted Event to Singleton for configuring and hosting no more than one game instance.
- Retrieve address and port from ConnectionAcceptor
- Automatically add local host to host list

#story[1010]
2017-07-25 15:52:53 +12:00
Connor Taylor-Brown a27c16d413 Merge remote-tracking branch 'remotes/origin/Game_Controller' into cbt-multi-controller 2017-07-25 14:54:09 +12:00
Connor Taylor Brown ea02752dc0 Merge branch 'bindWind' into 'sprint4_master'
Bind wind



See merge request !14
2017-05-25 16:09:02 +12:00
Connor Taylor Brown dc8403ec00 Merge branch '33CherryPick' into 'sprint4_master'
33 cherry pick



See merge request !11
2017-05-25 13:47:02 +12:00
cbt24 495547161d Merge branch '33CherryPick' of https://eng-git.canterbury.ac.nz/seng302-2017/team-7 into 33CherryPick 2017-05-25 13:36:34 +12:00
cbt24 2126c44db9 Last minute changes to get ready for DoD
#story[875]
2017-05-25 13:35:40 +12:00
cbt24 b58c3b98ed Integrated changes from story33-estimateTime branch
- Used refactored bearing methods
- Sent accurate current time to visualiser

#story[875]
2017-05-25 12:53:40 +12:00
Connor Taylor Brown 37828ef0fe Merge branch 'Story877' into 'sprint4_master'
Added Important and Partial Annotations and other refactors and documentation.

- Important, Partial, Hidden, Visible are all radiobuttons
- Fixed bug where the Visualiser would end the race before the last boat had finished
- Refactored the visualiser and the mock to use the race finished status message
- Added and Changed many Javadocs
#story[877]

See merge request !5
2017-05-24 23:45:50 +12:00
cbt24 27d4040a54 Cleaned up updatePosition in Mock.Race to simplify time estimation.
#story[875]
2017-05-18 14:42:27 +12:00
cbt24 91b1773703 Commented out obsolete tests, may be useful if refactored.
#story[881]
2017-05-10 17:02:25 +12:00
cbt24 f31a987787 Reads BoatDataSource into StreamedCourseXMLReader so the latter can function as a single source of static information for the race.
- Mock.StreamedCourseXMLReader populates participant and mark list from BoatDataSource
- Added CompoundMarker class to accommodate Mark data from Boat XML
- Had to check for Yacht type in Visualiser.BoatXMLReader
- Added a missing coordinate value to raceTest.xml
- Marker class still exists due to large number of tests, which should be transitioned to CompoundMark
- IMPORTANT: race is no longer functional

#story[881]
2017-05-10 16:56:21 +12:00
cbt24 9902cec688 Added tests for BoatXMLReader
- Verifies correct operation on boat and mark reading from boatTest.xml

#story[782]
2017-05-10 14:23:33 +12:00
cbt24 9aa4183a7c Merge remote-tracking branch 'origin/49Mock' into 49Mock 2017-05-10 13:57:36 +12:00
cbt24 69cd44bda8 Reads data from boat XML file
- Creates marks for building CompoundMarks (formerly Markers)
- Rearranged Boat constructor and removed velocity

#story[782]
2017-05-10 13:57:20 +12:00
cbt24 6e9386f4fb Switched mock to send out official xmls.
- Not reading official xmls yet

#story[881], #pair[cbt24, esa46]
2017-05-10 13:08:34 +12:00
cbt24 c038010bd2 Draws track for racing boats only to reduce information clutter.
- Add track point only when boat status is "Racing"

#story[782]
2017-05-06 19:22:20 +12:00
cbt24 f27dbc29b0 Added self-documenting RaceStatus boolean getters
- Deprecated RaceStatus.getRaceStatus

#story[782]
2017-05-06 19:06:37 +12:00
cbt24 cc824aa89a Removed unnecessary countdownTimer from Race in visualiser module
- Run method now calls simulateRace directly

#story[782]
2017-05-06 18:20:41 +12:00
cbt24 a6adfb4960 Refactored RaceClock to act as central source of time and duration information throughout visualiser.
- StartController and RaceController use same RaceClock instance
- RaceClock updates automatically as Runnable for consistent operation
- Duration between starting and current time is now an observable property of RaceClock

#story[782]
2017-05-06 18:02:48 +12:00
cbt24 349bd50094 Everything works, don't ask questions
#story[782]
2017-05-04 16:52:33 +12:00
cbt24 89ba0f278d Fixed StartController countdown
- Removed obsolete timer related code
- Consistently use RaceClock throughout StartController

#story[782]
2017-05-04 14:16:14 +12:00
cbt24 17afd9f775 Merge remote-tracking branch 'origin/splitIntoTwoModules' into splitIntoTwoModules
# Conflicts:
#	visualiser/src/main/java/seng302/Controllers/StartController.java
2017-05-04 14:15:21 +12:00
cbt24 336a15d1a2 Fixed StartController countdown
- Removed obsolete timer related code
- Consistently use RaceClock throughout StartController

#story[782]
2017-05-04 14:11:00 +12:00
cbt24 e345f08ad8 Fixed AC35 stream crashing before status sent.
#story[782]
2017-05-04 13:19:39 +12:00
cbt24 099995c41b Fixed start controller visibility issues.
#story[782]
2017-05-04 13:13:44 +12:00
cbt24 cd55052654 Merge remote-tracking branch 'origin/splitIntoTwoModules' into splitIntoTwoModules 2017-05-04 12:38:26 +12:00
cbt24 c1fa760dde Streamlined clock handling.
- Set starting time from network
- Update RaceClock instance to current time from network

#story[782]
2017-05-04 12:38:21 +12:00
cbt24 09483fff2c Added blocking loop to wait
- waits for the InputStream to be populated for at least 15 bytes of size before reading in case of header size error potentially crashing the program.
#story[782]
2017-05-04 11:49:16 +12:00
Connor Taylor-Brown 8886b5db05 Fixed RegattaXMLTest.
#story[782]
2017-05-04 01:40:12 +12:00
Connor Taylor-Brown 7d81fc810c Display name of race in lobby.
- Moved Regatta properties and accessors to RegattaXMLReader
- StartController update now tolerates any permutation of types of XML messages

#story[782]
2017-05-04 01:32:28 +12:00
Connor Taylor-Brown 1723d0c27f Fixed scaling of wakes (note issues with velocity data)
- Official stream provides speeds of 0 kn
- Mock provides speeds that do not correlate with motion

#story[782]
2017-05-04 00:32:06 +12:00
Connor Taylor-Brown 0e1bf64177 Fixed boat track rendering (points were added before boat position set)
#story[782]
2017-05-03 22:31:34 +12:00
Connor Taylor-Brown 9bab3d3359 Merge remote-tracking branch 'origin/splitIntoTwoModules' into splitIntoTwoModules 2017-05-03 22:04:19 +12:00
Connor Taylor-Brown e7008ab6db Fixed race playback issue, removed obsolete detail from UI.
- Removed race scaling options
- Refactored start screen timer formatting for clarity
- Removed incomplete countdownTimer override in Streamed Race

#story[782]
2017-05-03 22:04:08 +12:00
Connor Taylor-Brown 5a92dd68f5 Fixed build and interface problems.
- Ignore online host test (fails on CI)
- Disable connect button on startup to prevent bad socket

#story[782]
2017-05-03 19:31:00 +12:00
Connor Taylor-Brown ac4fbda848 Added connection screen to allow users to select available hosts from a preconfigured list.
- Added ConnectionController for initial client setup
- Added RaceConnection class for socket data and checking
- Configures StartController with a socket drawn from a host table

#story[782]
2017-05-03 03:40:36 +12:00
cbt24 ad58407021 Began work on ConnectionController for selecting active hosts on startup via GUI.
#story[782]
2017-05-03 00:35:46 +12:00
cbt24 577dea2a56 Fixed time zone label on RaceController.
#story[782]
2017-05-02 22:41:51 +12:00
cbt24 e40bb6c4cb Merge remote-tracking branch 'origin/splitIntoTwoModules' into splitIntoTwoModules
# Conflicts:
#	visualiser/src/main/java/seng302/VisualiserInput.java
2017-05-01 18:55:08 +12:00
cbt24 2e7527b325 Update boat position according to boat location messages in StreamedRace
- Added StreamedRace constructor accepting VisualiserInput
- Modified VisualiserInput constructor to accept Socket
- Refactored controller setup of Race

#story[782]
2017-05-01 18:52:52 +12:00
cbt24 3f42d56502 Merge remote-tracking branch 'remotes/origin/splitIntoTwoModules' into NetworkedVisualiser
# Conflicts:
#	visualiser/src/main/java/seng302/VisualiserInput.java
2017-05-01 16:00:11 +12:00
cbt24 b1db9ee5be Merge remote-tracking branch 'remotes/origin/splitIntoTwoModules' into NetworkedVisualiser
# Conflicts:
#	visualiser/src/main/java/seng302/VisualiserInput.java
2017-05-01 15:55:19 +12:00
cbt24 ccbe467090 Synchronised GUI with VisualiserInput thread.
- Made StreamedCourse extend Observable
- Initialised StartController after data pulled from network
- Moved VisualiserInput to visualiser module
- Deleted Networking subpackage from visualiser module

#story[782]
2017-05-01 15:21:12 +12:00