I finally did it! Please check out (& roast) my Battleship Python Terminal game!

Battleship Galactica

I chose the Battleship Game because it seemed like one of the harder games in the suggestions and also wasn’t in CS101 already like Tarot etc.
Boy was I right, I’m extremely new at all this and I have a full time job on the side but I got it done! I had to overcome alot of negative self talk and thinking I’m too dumb and old to figure it out but I did.

That being said I do enjoy constructive criticism, if you have time to check out the code please let me know how I can fix things.
Thanks
Adam

Good job overall. The game seems to play as expected. I have a few ideas you may want to consider, but they aren’t necessary.

  • Let the player know how big the ships in play are.
  • Consider labeling the rows and columns.
  • It would be a nice addition if a player could enter something like B3 for each shot rather than entering the row number, and then the column number on separate lines.
  • To make the terminal window less cluttered, you could clear it between turns.
How to clear the terminal. (If you're interested.)
from os import system
system("cls") # windows cmnd terminal
system("clear") # bash

Thanks so much for your reply!
I think I added the ship size reminder at the beginning but maybe I didn’t commit it!
I wasn’t sure how to add the labels without messing up the coordinates on the board, ill have to keep tinkering with it.
I really like the terminal clear, I’ll add that for sure.
Thanks again.

1 Like