Array user interface, Computer Engineering

Assignment Help:

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.


Related Discussions:- Array user interface

DBMS SQL Queries, How to fetch random ID from table by SQL query Select ...

How to fetch random ID from table by SQL query Select * from Table_Name order by NewID()

Typewriters with special attachments, Typewriters with special attachments ...

Typewriters with special attachments Certain special attachments can be used to the typewriter for typing work of a special nature. These are: The continuous stationery dev

Design a model for object oriented development, Design a model for object o...

Design a model for object oriented development The model for object oriented development could be shown as in Figure. It could be classified as dynamic / static and physical /

The concept of parallel execution and concurrent , The Concept of Parallel ...

The Concept of Parallel Execution and Concurrent Real world systems are obviously concurrent, and computer science is about modelling the actual world. Examples of actual worl

Creating a new directory in dos, Q. Creating a New Directory in DOS? Yo...

Q. Creating a New Directory in DOS? You can create any directory under any directory in the hard disk or floppy disk. The command to create a new directory is MKDIR or MD. To c

What are the different layers of tcp/ip protocol stack, What are the differ...

What are the different layers of TCP/IP protocol stack? Layers in the TCP/IP protocol architecture are:- o  Application Layer o   Host-to-Host Transport Layer,  o  Net

Translate the following sentences into predicate logic, Translate the follo...

Translate the following sentences into predicate logic. Give as much structure as possible. Provide a translation key for each predicate letter and individual constant. In your tra

Define about anchor tag, Q. Define about Anchor Tag? Anchor tag is used...

Q. Define about Anchor Tag? Anchor tag is used to create links between various objects such as HTML pages, web sites, files etc. It is introduced by characters and termi

Computer architecture, 6.How can we improve the performance of pipeline pro...

6.How can we improve the performance of pipeline processing

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd