Solitaire

Why Did I Make This?

This was a project outside of the scope of The Odin Project. Myself and another developer had decided we wanted first hand experience what it would be like to both be working on a repo and decided we would build something together. We chose a solitaire game.

solitaire game in progress

What Were The Biggest Hurdles?

Interacting with git with another person left us a little bit stunned at first, and building something from the ground up definitely left us with a lot of merge conflicts to deal with. Overall, it was a great experience and cemented concepts such as working in separate branches, committing often and commenting your code. We had a lot of struggles with Objects during the early phase of Solitaire. We had a core misunderstanding of copying objects, where we were copying the reference values and not deeply copying objects. When the core of card handling was complete, we went separate directions for logic where he worked on logic for double clicking on cards to move them to a legal move and I worked on single click from one sepecific pile to another. My biggest issue during Solitaire logic was stacking listeners on cards. Once a card moved to a new pile I needed to remove the original listener. A lot of fighting with binding finally led me to a solution. I had the task of mashing the two separate logics together once they were completed, and as you can see, Solitaire is playable using one or both methods!

Any Further Plans With This Project?

Yes! It is actually completed, well, isn't everything just an ongoing work in progress? Check out my other project card-factory NPM Package.