[US-03] Ship damage, announcing sunk, and finishing
Description
Implements ship damage tracking, sunk ship announcements, and game finishing logic for the Battleship game.
Changes
- Added ship damage tracking with hit counting
- Implemented sunk ship detection and announcements
- Added game completion logic when all ships are destroyed
- Implemented input blocking after game completion
- Added game reset functionality for new games
- Enhanced status reporting with detailed ship damage information
Requirements Implemented
Acceptance Criteria Validated
Technical Implementation
- Enhanced
Shipclass with hit tracking and sunk detection - Enhanced
Gameclass with game completion logic - Added
Player.hasLost()method to check if all ships are sunk - Added comprehensive unit tests for all new functionality
Closes #3