Array user interface, Computer Engineering

You were offered bonus marks for separating the user interface code from the main logic of your program. This design choice makes it very easy to replace the user interface without having to change the main program logic.

Make a copy of the class BasicUI, called ArrayUI. Within ArrayUI, make sure all references to BasicUI are renamed to ArrayUI.

In this task, you will modify the updateScreen() method of class ArrayUI to print out two lines in the following format:

....%.

_#__PX

This line gives a spatial view of where the all of the objects are. For example, the player, represented by "P" is at position 4 and is holding stone "%". The treasure chest "X" is at position 5. The stone "#" is still on the ground at position 1. This task must be implemented using two arrays of chars in class ArrayUI. The first array, called sky will hold the array of characters representing {‘.','.','.','.','%','.'} and the second array, called ground, will hold the array of characters representing {‘_','#','_','_','P','X'}. Of course, the actual characters found in the array will change as the game progresses.

Posted Date: 3/25/2013 5:52:23 AM | Location : United States







Related Discussions:- Array user interface, Assignment Help, Ask Question on Array user interface, Get Answer, Expert's Help, Array user interface Discussions

Write discussion on Array user interface
Your posts are moderated
Related Questions
Explain Debug monitors. Debug monitors give debugging support for a program. A debug monitor executes the program being debugged in its own control thereby giving execution e

A Header in CGI document can represent? A header into CGI document can show format of the document and the location if document used to various URL.

Q. Explain about disk caching scheme? The disk caching scheme can be used to speed up performance of disk drive system. A set (cache) of buffers is assigned to hold some disk b

Face Scanning Security System - Biometric Computer Security Systems Finally, face scanning security system are also one of biometric technologies. Generally, the principle of

explain classification of computers in detail.also explain various application areas of computers


Discrete Mathematics - (A?B)-(AnB)=(A-B)?(B-A) - prove by cases?? State which law you have used at each step. I''ve just started learning this, this semester .. and i havnt quite

What are the characteristics of the E-Cash? These kinds of payments, turning the Internet within a transaction oriented forum, need mediums which are easy and cheap (through a

What is the difference between wire and reg? Net types: (wire,tri)Physical connection between structural elements. Value assigned by a continuous assignment or a gate output.

Nested Macro calls are expanded using the? Ans. By using the LIFO (Last in First out) Nested Macro calls are expanded.