Implementation of Interface for a JAVA Game Assignment

Added on - Sep 2019

Trusted by 2+ million users,
1000+ happy students everyday
Showing pages 1 to 1 of 3 pages
Assignment #10 – Part 1Problem DescriptionYou are to begin the design and implementation of the interface for a Java game(to be completed in the following assignment). You have been provided with both aminimal skeleton of the code for the game itself as well as a library of a few fullydeveloped and documented methods that you must make use of. In order to use thislibrary file, you must first compile it to create a class file. You can then compile and runthe game file to confirm that it can read the methods and constants of the library.The skeleton game code you have been provided with contains a number ofmethods, each of which is paired with a detailed method comment. Your task is tocomplete the development of each of these methods, as well as determine how to bestmake use of them within the main method to accomplish the overall goal of the program.It is very important that you read and understand all of the method comments provided.Failing to understand the method comments in the library file may result in you notknowing how to correctly use those methods, while failing to understand those in thegame file may result in you failing to implement them correctly. Ask questions earlierrather than later.Your final submission for part 1 should function as follows. While the usercontinues to select a difficulty setting (as opposed to quitting) print a map generated tomatch the corresponding difficulty setting. An example of this is demonstrated below.While I have chosen specific dimensions and numbers of blox for each difficulty, you areencouraged to decide for yourself what these values should be, within reason (the mapshould fit on the screen).Game Rules(not implemented this week)The player is represented by a 'P'. The player can interact with the game bymoving in one of four directions; up, down, left, and right.The blox are represented by '*' and the holes by 'O'. The goal of the game is topush the blox around until each block has filled one of the available holes. Theplayer pushes blox by standing beside them and moving towards them. If the farside of the block is clear (or a hole), both the player and the block will move.If the player pushes one of the blox into a hole, both the block and the holedisappear (the block filled the hole).The map is surrounded by a border which is impassable to both the player andblox.The player wins the game once every block has been pushed into a hole.The player loses the game if they quit or walk into a hole that has not been filled.1
Desklib Logo
You are reading a preview
Upload your documents to download or

Become a Desklib member to get access