Advertisement Jump to content
  • Advertisement

Bug Fixes 1

Daniel Ricci


In my last post, I talked about the `Undo` feature that was implemented. Undo allows you to revert the last valid move that you made and will put back the score that you had then, with a hit of two points. I demonstrated all the different ways that you can undo your moves, basically all the different possible moves that constitute a valid `Undo` move.

Furthermore, I introduced a bunch of bug fixes related to the game. I did not demonstrate how the bug fixes are now working, however, this blog post future blog posts that include bug fixes will now be accompanied by a small demonstration of the expected result.

I had scheduled some time for me to work on the `Autocomplete` feature. For this feature, the user will be able to right click anywhere on the board, and all the cards that are face up that can be moved to any of the foundations will be moved there. As I was preparing myself to start work on this feature, I glanced over at the number of bugs that were lingering, and I felt that it would be a nice gesture to get a few of the bugs out the door before I start work on a new feature.

Therefore, I took a step back and got to work on a bunch of bugs, which I will present to you below, and one feature that handles the spacing of the cards more accurately to that of the original game. 

1. Clicking on the stock and then performing an undo, does not subtract 2

This is now working, and as you can see, performing an undo after clicking on the stock, will now subtract 2 from your score


2. Double-clicking on an Ace will position itself momentarily at 0,0 if you hold the mouse down on the second mouse down

There is an issue related to the container of the game being invalidated, causing a refresh and whatever card you have on that container having its bounds set to 0,0. This is now fixed and working as expected.


3. Switching from outline to non-outline does not update the cards in the talon view

There was an assumption made a while back that if something is not visible, it should not be able to receive events.

This is obviously not a good assumption to make. The code has been changed so that all registered objects of a particular event will receive event handler invokes, and it is up to the underlying object to handle if it should do something or not.


4. When dragging multiple cards in outline mode, the outline does not look consistent

There was a small miscalculation when the card's bounds were being computed. This is now working as expected.


5. In outline mode, doubling clicking to automove a card shows a small green artifact on the status bar

This required the underlying game view to be refreshed, this is now working as expected.


6. Talon Card Proportions (NEW FEATURE)

The spacing on the tableau views is now proportional to that from the original Solitaire game. Cards that have their backsides shown are approximately 3 pixels apart on the y-axis.
Whenever a card has it's face shown, further cards below will be approximately 12 pixels apart. This feature will now work as expected. I still have to handle the stock and the talon views
with respect to proportions, those have been logged as feature requests.


7. Automove shows the card at the top left on the second mouse down

This issue is related to other issues with the container being invalidated, this is now working as expected.


8. Dragging more than one card causes the cards to be cut at the bottom when playing in a timed game

This issue is related to other issues with the container being invalidated, this is now working as expected.


9. Playing a timed game causes the card to jump to the origin every tick

This issue is related to other issues with the container being invalidated, this is now working as expected.


Now that I've closed a lot of bugs, It's time to implement another feature. I will continue my work on the Autocomplete item.

You can always follow my progress by following the game located at and if you have any questions I will do my best to answer them. 

Take care, until my next blog post. 


Recommended Comments

don't really have anything constructive to say.. but wanted to tell you that I enjoyed reading this post.

Share this comment

Link to comment
2 hours ago, A4L said:

don't really have anything constructive to say.. but wanted to tell you that I enjoyed reading this post.


Thank you! :)

Share this comment

Link to comment

Agreed with @A4L, even though I have nothing especially constructive to add, I enjoyed the walkthrough of all the changes! :)

Share this comment

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!