This report is submitted in partial fullment of the requirements of the ELEN7045 - SD
Methodologies, Analysis and Design
Abstract
The Dodge Game is a mini project in Software Design and Modiability. The results of this development process are supposed to an executable game capable of running in a Windows environment. The game has be a developed using object oriented principles and makes use of a simple graphics. The chosen development environment was java and the graphics library was the Java 2D graphics. The approach taken in the design was a decoupling or component based design. The implemented solution runs on a JPanel and renders graphics on to the game screen
with …show more content…
Looking at the requirements there is so much motivation for having the player as a separate class. This class was sep- arated in order to facilitate making modications exibly in the class without aecting the other related classes.
Rg RainDrop
The key to the game as stated above is centered around this class. It has all the methods to create the raindrops, calling the pictures for the raindrops. This class also have a couple of methods responsible for randomly positioning the raindrops on the random places in
2
order to make it the rain almost real. The rectangle setbounds method sets the bounding dimension of a rectangle which in this case we are using to cater for the collision as there is no dened collision method dened for images in Java. The motivation for having this class separated is mainly because rain drops have a unique behavior as compared the the player and mixing the two would make such a confusion when modifying the methods.
The Rg RainDrop does not need to know what is going on in the player class as their only interaction is when the raindrops collide with the player but they never share similar methods. Rg Panel
Creates the panel and the back-end platform where all the game objects will be placed during runtime. It is the parent class to the Rg GameScreen. In the Model Views and
Controllers (MVC) pattern, the panel represents the