The tools required by this application include:
- a two-dimensional array for the game board
- a data type for a game piece (Tetris pieces)
- a set of rules and checks for game functions
- a viewer to display things graphically (Swing)
- a runnable thread to keep the game moving
- a event handler class to tie everything together
Using the MVC design pattern, we can categorize these into three main components:
Files:
- Model Class: holds all game assets, including objects and rules (functions)
- Viewer Class: with subcomponents done in Swing
- Controller Class: implements Runnable and acts as listener for Swing components
- jar:
- src:
- screenshots:



No comments:
Post a Comment