subject

The game will have 4 types of information you need to keep track of: the user, the Butterflies, the Bees and the Flowers. Here’s what you need to know for each (hint: some of these can be passed/given to the class constructor): • Human User/Player
o Name - You’ll need to ask who is going to play the game
o Whether they want to be a butterfly or bee
• Butterflies
o Butterfly colony name - Every colony needs a name, right? So you’ll need to ask the user what the name of the butterfly colony is.
o Butterfly color - Butterflies come in many different colors. To make things simpler, your colony will start with butterflies that only have two colors, a main color and accent color. You’ll want to integrate the colors into the butterfly colony name. So you’ll need to ask the user about which colors they want.
o Colony starting size - How many butterflies is the colony starting out with? This can vary, so you better ask the user about that also.
o Carry capacity – Butterflies come in different sizes. So we need to know how much pollen each butterfly can carry, from 1 – 10 grams. Users won’t know this information, so we’ll need to generate it.
• Bees
o Bee colony name - Every colony needs a name, right? So you’ll need to ask the user what the name of the bee colony is
o Colony starting size - How many bees is the colony starting out with? This can vary, so you better ask the user about that also.
o Carry capacity – Bees come in different sizes. So we need to know how much pollen each bee can carry, from 3 – 7 grams. Users won’t know this information, so we’ll need to generate it.
• Flower
o Flower name/type – We’ll need to ask the user what types of flowers to use in the contest. (e. g., Rose, Lily, etc.)
o Color – Every flower has a color, so ask the user what color the flower should be
o Distance from colonies - Each flower is a different distance from the colonies, 1 – 5 miles. The user won’t know this, so we’ll have to generate it.
o Round – Which round the flower was used in (see below).

Here is the flow of the game and the things that can be done with the game:
(hint: Do not assume that these must be methods. Think about how they will be used and then decide)
• User Information - Start by asking the user for their name and whether they want to be on team butterflies or team bees
• Colony Information - Ask the user for names of the butterfly and bee colonies, the colors of the butterflies, and the starting size of the butterfly and bee colonies
• Flower Information – Ask the user for the names, colors and distance of 3 flowers they want used in the contest.
• 3 Rounds - There will be 3 rounds where in each round, one butterfly and one bee will race to the selected flower, grab as much nectar as they can carry, and race back to the colony. At the colony, the nectar will be put into a collective pot for each colony.
• Nectar Loss – As the butterflies and bees fly back with their colony, they lose some of the nectar that they have picked up. How much they lose depends on how far they have to fly. For every mile they have to fly, they lose 5% of the nectar that they are carrying. For example, if they have to fly 3 miles, then when they have reached the colony, they will have lost 15% of their nectar.
• Each Round - For each round, the user should be told the following:
o Round number
o Which flower (including its color) the butterflies (the integrated name as discussed above) and bees are racing to
o The distance to the flower
o The carrying capacity of the butterfly and bee
o How much nectar made it back to the colony
o The amount of nectar in each colony’s collective pot at the end of that round
• Ending colony size - At the end of the 3 rounds, you’ll determine who wins and calculate the ending colony sizes.
o Whichever colony’s collective pot has the most nectar wins.
o For the winning colony, the colony triples in size. For full credit, you must use the appropriate math function.
o For the losing colony, the colony loses 10% of its population
• Winning Output - For your last output (nicely formatted in a JOptionPane), you will want to include:
o Whether the user’s team won or lost (including the user and colony name)
o For both teams
▪ The starting size
▪ Total carrying capacity
▪ Total distance flown
▪ Total amount of pollen collected
▪ The ending size

ansver
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 17:30, josephvcarter
Who invented the tv .hint it was 2 people
Answers: 1
image
Computers and Technology, 22.06.2019 18:30, yayamcneal05
Which cultural aspect does this type of song best portray? a german polka dance
Answers: 1
image
Computers and Technology, 23.06.2019 05:00, mikeysoulemison
Jason works as an accountant in a department store. he needs to keep a daily record of all the invoices issued by the store. which file naming convention would him the most?
Answers: 2
image
Computers and Technology, 23.06.2019 09:30, rowdycar313p0ao5k
[java] create an application called registrar that has the following classes: a. a student class that minimally stores the following data fields for a student: - name - student id number - number of credits - total grade points earned and this class should also be provides the following methods: - a constructor that initializes the name and id fields - a method that returns the student name field - a method that returns the student id field - methods to set and retrieve the total number of credits - methods to set and retrieve the total number of grade points earned. - a method that returns the gpa (grade points divided by credits) b. an instructor class that minimally stores the following data fields for an instructor: - name - faculty id number - department the following methods should be provided: - a constructor that initializes the name and id fields - methods to set and retrieve the instructor’s department. c. a course class that minimally stores the following data for a course: - name of the course- course registration code- maximum number of 35 students- instructor- number of students- students registered in the course (an array)the following methods should also be provided: - a constructor that initializes the name, registration code, and maximum number of students- methods to set and retrieve the instructor- a method to search for a student in the course; the search should be based on an id number.- a method to add a student to the course. if the course is hill, then an exception with an appropriate message should be raised (try creating your own exception class for this). also, be sure that the student is not already registered in the course. the list of students should be in the order that they registered.- a method to remove a student from the course. if the student is not found, then an exception with an appropriate message should be raised (use the same exception class mentioned a method that will allow course objects to be output to a file using object serialization- a method that will allow course objects to be read in from a file created with object serializationyou will note that the student and instructor classes described above have some commonality. create aperson class that captures this commonality and uses it as a base class for student and instructor. this class should be responsible for the name and id fields and also provide atostring method that returns a string of the form name, id. this will be the inheritedtostring method for the student and instructor classes.1. draw a uml diagram for diss application.2. implement the previous classes in java. write a main program that can serve as a test class that tests all of the methods created and demonstrates that they are working
Answers: 2
You know the right answer?
The game will have 4 types of information you need to keep track of: the user, the Butterflies, the...

Questions in other subjects:

Konu
History, 15.01.2021 18:00
Konu
Mathematics, 15.01.2021 18:00