Between school, tests and school projects, I have found some time to work on a new game: BATTLESHIP

For those of you who don't know Battleship:
The game revolves around two players placing ships on a 10x10 grid. They can both take turns to guess the possible location of a ship, by "bombing" a specific tile. The other player has to say if it hit or missed. With these clues, the players' objective is to fully bomb all the ships in the other player's waters. If a player has found every single one of the opponent's ships, they win the game.

I have so far added a 1v1-mode, where the players can just hand the calculator to each other, but I also created a bot to play against (which, despite the fact that it almost beat me, still requires some more brain cells). I still need to add a whole lot of other stuff, but the main game is there.

I unfortunately have no clue how long it will take to finish this, since I'm not sure how much time I'll get to work on this and if I'm going to spend more or less of that time wisely. I'll make sure to keep you updated.

Screenshot:
I can't wait for this program- I've absolutely loved your programs in the past for their graphics, can't wait to see how this turns out!
Looking neat Smile Are you planning to put things in the top half of the screen?
MateoConLechuga wrote:
Are you planning to put things in the top half of the screen?
Yeah, I think I'm going to make sort of GUI there, although it will serve more of a graphical purpose than an interactive one.
Very nice! I've always wanted to make an ICE battleship, but your design beats what I was thinking! How does 1v1 work with hiding the opponents side? It'd be pretty easy if you could both see each others sides. Laughing
TheLastMillennial wrote:
How does 1v1 work with hiding the opponents side? It'd be pretty easy if you could both see each others sides. 0x5

I was thinking of a simple transition screen, like in Polytopia for example. Just a black screen that says "Player 1's Turn" or something like that.
Looks very slick, I'm glad that you won in the screenshot too Very Happy.
_iPhoenix_ wrote:
I can't wait for this program

Haha... let's not talk about that... Rolling Eyes

I did some things last week. Quite a lot, the game is almost finished.
I made some animations, a GUI, a menu and some tweaks to the AI, though I'll need to work on that last thing some more.

My apologies for the delay. After CC22 I took a break from calculator programming, in favor of school, other hobbies and my mental health. I actually didn't think I'd work on this project anymore, but I started again with a clear mind, which helped a lot.

I'll upload the project when I'm convinced it's completely done.

Below is me playing a 1-player game:
This looks absolutely fantastic! way better than DungeonCE Good job! I am interested in trying out the AI :3
Oh, don't be like that. DungeonCE looks great! It's also probably way harder to program.

By the way, the AI isn't that smart: it guesses and advances when it has found something. I'll look into improving both of those actions.
I agree, this looks very good! It's not a complex game (and AI is pretty easy to program), but the graphics add a lot to the experience.

I wonder if you could add some more variety to the status text to spice it up a little? Even just a selection of phrases for each situation (randomly choosing one as appropriate) would be fun- I imagine something a little like the "Talking Tanks" setting in Scorched Earth.
Tari, the talking tanks in Scorched Earth was exactly what I was thinking as I was reading your post!

This game looks very polished btw BTH - well done!
How are having users enter ship positions? Are you storing the using a matrix?

I myself have a Battleship program, so if you need any help, I'm glad to offer it.
Caleb_J wrote:
How are having users enter ship positions? Are you storing the using a matrix?

Yes, I use a two-dimensional array, one uint8_t per tile, for whether the tile has a ship section on it, and whether the tiles has already been bombed. I should probably compress the data in the save file, but only 200 bytes of RAM for 200 tiles seemed fine to me for the actual game.

Caleb_J wrote:
I myself have a Battleship program, so if you need any help, I'm glad to offer it.

Thank you, but honestly, I think it's really important I do this by myself, sort of as a learning process. Thanks for offering though! Smile
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement