66. [M] As Gemma, I'd like boats and marks to act as barriers to movement so that another player cannot beat me by just ignoring marks and other boats on the course.
Note: as boats and marks don't start in overlapped positions, we are only concerned with collisions.
Acceptance criteria:
- No boat can pass within an agreed distance of the centre of another boat or mark
- Boats that hit other objects are repelled twice the agreed distance in the opposite direction to their current heading
See merge request !27
Slightly refactored ResizableRaceCanvas - removed a redundant drawPoint() function, functions which alter the gc stroke call save/restore.
Text is drawn black, at 20pts.
The drawBoats() function: instead of drawing everything for each boat, one boat at a time, it draws the track points for all boats, then wake for all boats, etc..., to have better layering.
issue #18
Story 61
[Agilefant link](http://agilefant.cosc.canterbury.ac.nz:8080/agilefant302/qrq.action?q=story:1095)
```
Note: the boat should be permanently circled with a highlight (or something similar)
See: (http://learn.canterbury.ac.nz/mod/forum/discuss.php?d=213948). Contains boat request to join, and server response messages.
Acceptance criteria:
- The boat that responds to control keypresses is permanently highlighted on screen.
- No boat without a highlight responds to keypresses.
```
Works with either single player or multiplayer game (see HostController.hostGamePressed()).
The race.xml currently is not updated when players join/quit, so there are 6 boats by default, and any boats without playes will just sail off the side of the map.
- resolves#39
- resolves#37
- resolves#35
- resolves#27
- resolves#25
- resolves#32
See merge request !26
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