CSS 142 University of Washington Seattle Campus Mario Boards Revision Methods Hello i wanted someone to revision and make this program less complex and i h

CSS 142 University of Washington Seattle Campus Mario Boards Revision Methods Hello i wanted someone to revision and make this program less complex and i have uploaded the file and also what the homework should look like 2 files are what i have done and the other is what the homework needs.

And a final checklist of things to look at before you submit your work:

Don't use plagiarized sources. Get Your Custom Essay on
CSS 142 University of Washington Seattle Campus Mario Boards Revision Methods Hello i wanted someone to revision and make this program less complex and i h
Just from $13/Page
Order Essay

Remember you are turning in two files! (See the assignment description for details.) Please make sure any images are oriented so they are upright when opened.
Compile and execute your code before you submit the “.java” file. If it doesn’t work, something is wrong.
Check the extensions of the files you are submitting. The list of file types you can submit are given below.
Make sure both files start with “LastFirst”, i.e., your lastname then your firstname, with the first letter of each capitalized. If you do not do this, I cannot guarantee I’ll be able to properly credit you with creating a working program.
Limit the width of your code to 80 characters. This makes it easier for me to read.
Define variables mario and coin. What data type should they be? How might you use these variables?
Make methods in your code. These methods can all be part of the class that has the main method.
You shouldn’t need to use looping or branching, though, of course, you could if you wanted to. Unless you are already pretty comfortable with those constructs, I’d stick to doing this the more straightforward way.
If you’re using the BlueJ IDE, here is a quick review (Links to an external site.) of how to make it work:
Pay attention to the last sentence in that review that tells you how to clear the screen each time before you run your main method. Otherwise, successive screen writes will add onto previous writes.
In the same Options menu that controls clearing the screen, also select “Unlimited Buffering”. Otherwise, if your boards are long, all of them will not show on the screen.
Use Tab and Shift-Tab to quickly indent and deindent blocks of code Homework: Methods
CSS142: Computer Programming I
Homework: Methods — Mario Boards
CSS 142: Computer Programming I
Summary
The purpose of this assignment is to construct two separate Java programs that produce three distinct
levels or boards similar to those found in the Super Mario Brothers brand of games. These Java
programs will rely on method calls to reduce redundancy in your software. Additionally, you will get to
know the website tools and submission procedure to use for future homework.
Work Items
(1) In lab, you should have already installed the Java JDK and the BlueJ IDE on your home computer.
If you have not yet done so, please do so, as you will need both in order to do this homework.
(If you don’t want to use BlueJ, you don’t have to; feel free to use any programming
environment you wish. But I’ll be using BlueJ much of the time in lecture.)
(2) Draw a flow chart of your second program. That is to say, create a flow chart of only the
contents of the runProgramTwo method (as named below in item 3d). You can treat
methods called in the runProgramTwo method as black boxes (i.e., you don’t have to draw
flow charts for those “sub”-methods). Submit the image file of a scan of this flow chart:
a. The chart may be handwritten and can be more than one page. Please make it legible.
b. Your image file can be PDF, JPG, TIF, or PNG.
c. Please submit only one image file via Canvas. Do not email your instructor your work.
d. Name your file LastFirst_HW_Methods.pdf (or whatever is the extension for the graphic
format you’re using), where you put in your own last name and first name for “Last” and
“First”. You must name your file this way.
(3) Write the two programs described below. Submit the single Java file (i.e., “.java” text file) that
contains your two programs:
a. Please submit only a single Java file via Canvas (below I describe how you put two
programs into one file). Do not email your instructor your work.
b. Name your Java file LastFirst_HW_Methods.java, where you put in your own last name
and first name for “Last” and “First”. You must name your file this way.
c. Note that by requiring you name your Java file LastFirst_HW_Methods.java, it means
that the public class that is in that file has to be named LastFirst_HW_Methods (again,
substituting your own name as appropriate). Note, in general you wouldn’t put your
name in the class name (and thus filename), but in this course, it will simplify things for
the grader.
d. Each of your programs should be called by a method. Those methods should be written
in the same class as your program. Your Java file should have a main method that calls
these two methods. You probably will have a main method that looks like this:
CSS, University of Washington, Bothell
1
Homework: Methods
CSS142: Computer Programming I
public static void main(String[] args)
{
runProgramOne();
runProgramTwo();
}
Context
Let’s consider how we might represent a level from the game Super Mario Bros using just the symbols
on a keyboard. Specifically, look at the level design for the first board, and let’s see if we can recreate
some of the patterns we observe below.
(1) We could model the ground with a minus sign, equal sign, or an underscore:
===================================================================
(2) Next we could add some “?” boxes to our level (some of the coin and powerup boxes seen
between the bricks in the beginning of the level) along with bricks (denoted by the “|” sign):
|?|
|||||||||||||
|||?|||?|||
==========================
|||?|||
=======================================
=====================
(3) To make our task simpler here, we’re going to rotate our perspective 90 degrees so that we view
the board “top-down” instead of “left-to-right”. Just think of this as an exercise in changing your
culturally adopted reading style. Some cultures read left-to-right as you are doing now, and
some read top-to-bottom; can you think of any languages that are represented differently than
this? Either way let’s ….
R
o
t
a
t
e
CSS, University of Washington, Bothell
2
Homework: Methods
CSS142: Computer Programming I
Introduction
Your task is to write a program that outputs two distinct levels or boards from a Mario game. Your level
will be constructed from multiple smaller segments that you will “string together” by calling the correct
functions from your main function (remember, the terms “method” and “function,” for our purposes,
are interchangeable). Here is an example Mario level (note that some parts of the board are duplicates
– use methods for all segments to avoid duplicate code):
||
||
||
||
||
||
||
||
||
||
||
||
//segment1
|?|
//segment2
|?|
||
||||
||||||
||||||||
||||||||||
||||||||||||
||
||
^
|—————-
//segment3
Note that by changing our perspective, the “|” character now represents the “ground” while the hyphen
represents vertical towers or other vertical structures (that are not the ground). The text that kind of
hovers in the air, e.g., “//segment2”, are comment lines that indicate the portion to the left can be
thought of as a unit or chunk of the board. The syntax of that text follows the Java syntax for
comments. Your program should not write out “//segment2” etc.
CSS, University of Washington, Bothell
3
Homework: Methods
CSS142: Computer Programming I
Your First Program
The first program will clone the output from above and create two different Mario boards. Call the first
“Mario Board 1” and the second “Mario Board 2”. These two boards will be the same text for the
individual segments, but each will have unique look for due to the order and number of function calls in
your main function. For example, you could redesign the level above as a longer level while reusing the
same basic building blocks; here would be that output (which I preface by the label “Mario Board 1”),
again with the “//segment1” etc. as labels to help you see the modularity of the board segments:
Mario Board 1:
||
||
||
||
||
||
||
||
||
||
||
||
||
||
||
||
||
||
//segment1
|?|
//segment2
|?|
|?|
//segment2 repeated
|?|
||
||
||
||
||
||
||
||||
||||||
||||||||
||||||||||
||||||||||||
||
||
^
|—————-
CSS, University of Washington, Bothell
//segment1 repeated
//segment3
4
Homework: Methods
CSS142: Computer Programming I
Your Second Program
This program is quite similar to the first, so you might consider making a copy of your first program as a
starting point for your second. In future weeks, we’ll discuss better techniques for code reuse than
simply copying and pasting, but for this assignment, this is a fine way to shorten the work you have to
do. The goal of the second program is to ask the user for the unique text representation of the hero
Mario and of a coin; then your program will build a board and place Mario somewhere in it, as well as
one or more coins. To do the user input from the console (keyboard), you will want to use the Scanner
class. A sample execution of this program might look like:
CSS, University of Washington, Bothell
5
Homework: Methods
What does Mario Look like?
CSS142: Computer Programming I
>–
Purchase answer to see full
attachment

Homework On Time
Calculate the Price of your PAPER Now
Pages (550 words)
Approximate price: -

Why Choose Us

Top quality papers

We always make sure that writers follow all your instructions precisely. You can choose your academic level: high school, college/university or professional, and we will assign a writer who has a respective degree.

Professional academic writers

We have hired a team of professional writers experienced in academic and business writing. Most of them are native speakers and PhD holders able to take care of any assignment you need help with.

Free revisions

If you feel that we missed something, send the order for a free revision. You will have 10 days to send the order for revision after you receive the final paper. You can either do it on your own after signing in to your personal account or by contacting our support.

On-time delivery

All papers are always delivered on time. In case we need more time to master your paper, we may contact you regarding the deadline extension. In case you cannot provide us with more time, a 100% refund is guaranteed.

Original & confidential

We use several checkers to make sure that all papers you receive are plagiarism-free. Our editors carefully go through all in-text citations. We also promise full confidentiality in all our services.

24/7 Customer Support

Our support agents are available 24 hours a day 7 days a week and committed to providing you with the best customer experience. Get in touch whenever you need any assistance.

Try it now!

Calculate the price of your order

Total price:
$0.00

How it works?

Follow these simple steps to get your paper done

Place your order

Fill in the order form and provide all details of your assignment.

Proceed with the payment

Choose the payment system that suits you most.

Receive the final file

Once your paper is ready, we will email it to you.

Our Services

No need to work on your paper at night. Sleep tight, we will cover your back. We offer all kinds of writing services.

Essays

Essay Writing Service

You are welcome to choose your academic level and the type of your paper. Our academic experts will gladly help you with essays, case studies, research papers and other assignments.

Admissions

Admission help & business writing

You can be positive that we will be here 24/7 to help you get accepted to the Master’s program at the TOP-universities or help you get a well-paid position.

Reviews

Editing your paper

Our academic writers and editors will help you submit a well-structured and organized paper just on time. We will ensure that your final paper is of the highest quality and absolutely free of mistakes.

Reviews

Revising your paper

Our academic writers and editors will help you with unlimited number of revisions in case you need any customization of your academic papers