Skip to content

Releases: Carlbytes/BattleShip_cpp_Game

🚢 Battleship v1.0.0

28 Nov 16:13

Choose a tag to compare

First official release of the C++ Multiplayer Battleship Game!

This release features a fully playable, turn-based naval combat game that works over LAN and VPNs. It utilizes a Client-Server architecture built on SFML sockets.

✨ Key Features

Multiplayer Networking: Host and Join games via TCP/IP.

Smart Quality of Life:

    IP History: Automatically remembers the last successful server IP.

    Cursor Aiming: Use WASD or Arrow Keys to move your cursor on the grid.

    Visual Feedback: Color-coded hits (Red), misses (White), and ship placements.

Game Mechanics:

    Coin Flip: Randomly decides who takes the first turn.

    Win Condition: Correctly tracks sunk ships and declares a winner.

    Pass Turn: Chat and pass turns without firing (Walkie-Talkie style).

🛠️ Technical Highlights

OOP Architecture: Full class hierarchy for Ships (Battleship, Cruiser, etc.) using Inheritance and Polymorphism.

Design Patterns: Implements the Singleton Pattern for the GameManager to ensure state safety.

Robustness: Includes Unit Tests covering board logic and placement validation.

Distribution: Statically linked executable packaged via Inno Setup for easy installation.

📥 How to Install & Play

Download Battleship_Setup.exe from the Assets below.

Run the installer (It will install to your Program Files and create a Desktop Shortcut).

Host: Run the game, select 1, and tell your friend your IP (displayed on screen).

Client: Run the game, select 2, and enter the Host's IP.

⚠️ Note on Windows Warnings: Because this is a student project and not digitally signed, Windows Defender (SmartScreen) might show a blue warning pop-up.

    Click "More Info" -> "Run Anyway".

    When hosting, you must click "Allow Access" on the Firewall popup to let your friend connect.