Anthony Russo's profile

ARusso - LCR Dice Game (C++)

Artifact Name: Left Center Right C++ Game

Artifact Description: This artifact was created early on in my school experience. It is based the real life game of the same name, where the objective is for players to roll 6-sided dice and move their 'tokens' to either their left, right or to the center. The game ends when only one player has tokens left. This project was entirely written in C++ and there is no real GUI. It is a console-based application.

Tool(s) Used: Visual Studio Community 2022

Highlighted Skills: Programming Knowledge with C++


Reflection

How would I describe the process of creating and polishing this artifact?

When I originally made this piece, it was at the start of my SNHU journey. I had never done any C++ related work prior and haven't done much since. This added an extra difficult dynamic to the project as I'd had to learn C++ fundamentals and create a functioning game at the same time.

The difference between the time when I started this project and the polishing stage (which happened almost three years later) felt almost like night and day. When I first created the project, I couldn't even get it to work. The original prompt had been simple: create a C++ game that displays the rules of the game, prompts the user to input the player count and then proceed to play the game and save the game results to a file. I couldn't do any of it.

I chose this project largely as a way to re-test myself on my understanding of C++. As I've been more exposed to C#, I felt that with a better understanding of programming principles I could at least make a better project than the first time around. All of the pictures you see above are from the new version of the project, not the original.

What did I learn as I was creating it and improving it?

In short, I learned how to program in C++ at a fundamental level. I'm under no illusion that this project is neither particularly impressive or ground-breaking. It is, however, showing a marketable skill. 

Throughout my journey and foray into game development and programming, I noticed a significant flaw in my early work: I lacked dynamic code. What do I mean by this? Instead of using a For loop to loop through iterations for a dynamic player count, I originally tried to limit the total amount of players to 10 because I hand-coded each instance of a player's turn in main(). This is true for almost every instance of a repeated system I used to create this game.

What challenges did I face?

The biggest challenge I faced was getting everything to work. Having never played the actual LCR dice game (digitally or otherwise) I had the added challenge of also trying to understand the game's rules so that I could translate them into a playable game. I also had no understanding of the more advanced concepts in C++ programming, such as classes and header files. My first iteration of the game was all done in a single C++ file. It hadn't even occurred to be how sub-optimal this was at the time and the project was so uninspiring that I chose to not even include it in this portfolio.

How did I incorporate feedback as I made changes to the artifact?

This was the hardest part because feedback wasn't specifically given at any point. The trouble with a broad grading scheme for an online school experience is the lack of one on one review and feedback. As long as my project hit the right beats in a rubric, the score was perfect even if the product wasn't as finished as intended. This left me to give myself feedback. Did this project reach my expectations? Can I play this game at all? Did I learn anything by writing this code? The answer to these questions is what drove me to choose this as my first project. I thought bringing myself back to basics was the right call.

How was the artifact improved?

The project is now playable, although still incomplete. Instead, I chose to pursue all of the areas in my C++ learning that I'd failed on previously. This version of the game has bug-free For loops, separate classes for the Player, Dice and Game, dynamic functions and switch statements and clearer code/commenting. These are all fundamental principles that become marketable skills and are what I chose to focus on to improve this project. The first time I made this game, it took me eight weeks to push out something that couldn't even run. In one week I managed to create a game that can play, track players and simulate the game with commented code to fill in the gaps. 
ARusso - LCR Dice Game (C++)
Published:

ARusso - LCR Dice Game (C++)

Published: