Welcome!

NAVIGATION:
Home
Projects


Lotus Project (Spring 2010)

bgg
(Image from BoardGameGeek.com)

    For a CSE 116 class, I was tasked with recreating a board game in Java with two other classmates. The board game is called "Lotus" and I believe it was created by Ravensberger in Germany. It's a simple game where players move stacking chips along spaces on a board. I won't go into much detail of how it's played, but basically the height of the stack of chips at each position on the board determines how far the top chip moves.


ty alphonce
(Image from the course website @cse.buffalo.edu)

    So we were tasked with the following:
1) Writing JUnit tests for the game.
2) Then implement the board game
3) Then take somebody elses version, and build upon it.

    Stage one was simple, and is pretty much the appetizer portion of test driven development. By writing a whole bunch of tests, we pretty much outline not only exactly what our code should be able to do, but in a way, also how we're going to implement those functions.

    For stage two, I came up with the idea of using lists of stacks to represent each position on the game board. Since there's a split on the board, we used three lists of which the left and right starts merged into the final shared main stretch. Each item in the lists were stacks, and each stack was a stack of pieces on that position. It's been a while, but basically we just defined a Piece or Tile class and implemented it exactly like it sounds. Each player has different colored pieces, and there are additional rules on moving and such, which we implemented and tested as well.

    In stage three, we went with one of three choice candidates provided by the instructor, written by our peers. The choice we made off the bat sounded very similar to our interpretation, but was very long winded and didn't actually work. Unfortunately, a majority of the time spent during phase 3 was actually spent getting phase 2 working again, before we could add any aditional functionality like multiplayer and AI. (Though, we still did).

    So eventually, we had two different working versions of lotus: Our interpretation from stage two, and our new edition from stage three. Here's a boring video on our stage two version! Click.