5/09/2013

C++ Jeweles

Hi, today I have been programming a bit on a Bejeweled clone. Doing this was once a work test that I failed at the time. There were strict time restrictions and I rushed which became my downfall. Regardless I'm now trying to do it slowly and surely so I can do it again if I encounter a similar problem.

Step one was to create a playing field that worked with dynamically moving tiles. At first I thought hey, tiles, 2D array. Since this is on PC and I have a pretty limited scope I can focus on making it work and worry about optimizing later (if I feel it's needed). I started to go to work with vectors and lists. In the end I want with vectors. In the video below I implemented a function for resetting the field at the press of a button, doing so kills all the tiles and spawns new ones.


In the second video below I've gotten so far that I've been able to remove any tiles that are three in a row. The final piece, switching places between two adjacent jewels, will have to wait til tomorrow.




Until next time.

No comments:

Post a Comment