3-hour TicTacToe

Today I build a TicTacToe web version for about 3-4 hours from scratch. I got this far => latest commit on my GitHub

I had thought about it earlier a bit so it was a little easier. Anyway I made a huge progress compared to that text-based terminal version. Not only on the UI side but also in the game engine. I got much further and with much more elegant code.

It’s not ready yet, I made a seven bullet point list about things to improve:
# 1. Doesn’t take diagonals from right to left when checking the winner
# 2. Player can replace the computers button => should be error
# 3. Board CSS (square size, font size & shadow) should follow the board width / height arguments
# 4. Board could be responsive and will fit to screen size
# 5. Computer could be more intelligent, not just random
# 6. There could be UI for board size & signs & in_a_row => preferences
# 7. 2 player mode? => on a tablet?

I think I will complete some of those tasks still in the future and then deploy it to Heroku so everybody can check it out.

——

I need this kind of practice to build my confidence and skills to build something from end-to-end (as our Tealeaf instructor Chris says). It starts with these and in the future it hopefully be something more impressive.

But this was fun and I was really impressed that I can already build something like this from scratch in few hours. It really motivates to continue and learn new skills.

One thought on “3-hour TicTacToe

  1. Cool game! I can tell it’s not finished, but it’s a good start. I know you said it wasn’t done, but I ran it just to see anyway. I have a feeling we are going to be neck and neck during the course. Maybe down the road we can work on something together. The rails course should be more of a challenge then the first one.

    Also, thanks for stopping by my blog and leaving a comment.

Leave a comment