Intro...
Over the last 2 or so weeks, I have been working on my game from my last post of connect four for the LiteCanvas game engine.
So Far...
So far, I have been able to commit changes of drawing the board, successful checks for win cases, and the drawing of the board assets in the game loop.
Stuck...
In my development of this connect four game, I have come into 2 small issues aside from learning the engine. First, I set out to have a clean looking falling animation. Due to the limitations of not using complicated assets, but using the inbuilt drawing methods of the engine, I found that I had to create this animation in a different way than I intended. Because of the way the board is being drawn, there were overlapping shapes that I could not have a continuous fall animation behind open circles on the game board. I opted to go with board positions that change colour as the piece drops into its final place. My current animation can be seen below:
For my second issue, the game updated so fast that if I wanted to move the selector for dropping a piece it would instantly move to the end of the board. As well, when the pieces dropped they would instantly show at the bottom despite my attempts at the falling animation. To fix this, I added delays for moving the selector, dropping a piece, and waiting for a piece to drop before moving the selector.
Figured Out...
So far in this release, I have been able to figure out how to draw objects, how to keep states of objects that change with keypresses, how to use the game loop, how to use the update method, and more. It's been fun so far reading the documentation and cheat sheet guide and using it to create and play my game.
My Goals...
My initial learning of this release was just studying the docs. As mentioned above, I have been using the docs and cheat sheet guide(s) and following the proper syntax for the game to run. As well, I closely followed the game logic of the other game present in the games repo of 'Asteroids'. Using that code, I was able to figure out how to get my logic and initializations of variables and states done in a similar way. By the end of this release I hope to achieve my main goals. The extra goals may not be completed because of exam prep and final projects I've been working on. But I am almost complete with the game and on track to hit my main goals.
Of my main goals I have:
- Created a Connect Four LiteCanvas game.
- Studied the documentation as well as prior implementations of games and examples.
- Added a dropping piece animation.
- Having a simple UI and with friendly controls.
- Having the game be 2 player back and forth.
Additional features I have added:
- Selector with delays for user inputs.
- Victory and Draw screens after game ends.
- Turn descriptors.
Features currently in the works:
- Score counter.
- Ability to replay/continue playing the game.
Overall, I think by the release 0.4 due date I will end up completing my main goals. I am currently still working towards completion of the game, and am on track to do so by the submission.
Top comments (0)