Please answer the following questions:
Describe the incremental and iterative development process of your program, focusing on two distinct points in that process. Describe the difficulties and/or opportunities you encountered and how they were resolved or incorporated. In your description clearly indicate whether the development described was collaborative or independent. At least one of these points must refer to independent program development; the second could refer to either collaborative or independent program development.
You will need to write around 150-200 words to do a good job
When we were making the game, we wanted to make a program that has branches and when different responses are entered by the user. the game would permanently change and it will be different. By having many types of ways you can play the program, it would be more fun to see the variety of ways you can play the game. Also, the battle mechanics have also added a nice touch to the game such as attacking or taking cover. Working with David, we were able to fix each other’s syntax errors and pass around ideas on what could we do to make this program even more fun when people play it. For example, we made different branches that led to completely extraordinary levels and monsters you would come across depending on your responses in the game. While I worked on half of the levels, I made them each unique by adding a twist to each monster (such as random number generators and patterns you could use to defeat the monster).
Capture and paste the program code segment that implements an algorithm that is fundamental for your program to achieve its intended purpose.
Your code segment must include an algorithm that integrates mathematical and/or logical concepts.
Describe how each algorithm functions.
public void PepeBoss() {
// Done by Josh Lim
// Pepe Boss Fight
String name;
Scanner input = new Scanner(System.in);
int a = 0;
int b = 50; // Monster's HP
int c = 20; // User's health points
int d;
int e = 0;
int f = 20; // Monster's damage
int g;
int h;
int boomerang = 4;
int boomatk;
int crit;
int rod = 3;
int pepe;
int num7;
System.out.println("__________████████_____██████");
System.out.println("_________█░░░░░░░░██_██░░░░░░█");
System.out.println("________█░░░░░░░░░░░█░░░░░░░░░█");
System.out.println("_______█░░░░░░░███░░░█░░░░░░░░░█");
System.out.println("_______█░░░░███░░░███░█░░░████░█");
System.out.println("______█░░░██░░░░░░░░███░██░░░░██");
System.out.println("_____█░░░░░░░░░░░░░░░░░█░░░░░░░░███");
System.out.println("____█░░░░░░░░░░░░░██████░░░░░████░░█");
System.out.println("____█░░░░░░░░░█████░░░████░░██░░██░░█");
System.out.println("___██░░░░░░░███░░░░░░░░░░█░░░░░░░░███");
System.out.println("__█░░░░░░░░░░░░░░█████████░░█████████");
System.out.println("_█░░░░░░░░░░█████_████___████_█████___█");
System.out.println("_█░░░░░░░░░░█______█_███__█_____███_█___█");
System.out.println("█░░░░░░░░░░░░█___████_████____██_██████");
System.out.println("░░░░░░░░░░░░░█████████░░░████████░░░█");
System.out.println("░░░░░░░░░░░░░░░░█░░░░░█░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░██░░░░█░░░░░░██");
System.out.println("░░░░░░░░░░░░░░░░░░██░░░░░░░███████");
System.out.println("░░░░░░░░░░░░░░░░██░░░░░░░░░░█░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░█████████░░░░░░░░░░░░░░██");
System.out.println("░░░░░░░░░░█▒▒▒▒▒▒▒▒███████████████▒▒█");
System.out.println("░░░░░░░░░█▒▒███████▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒█");
System.out.println("░░░░░░░░░█▒▒▒▒▒▒▒▒▒█████████████████");
System.out.println("░░░░░░░░░░████████▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒█");
System.out.println("░░░░░░░░░░░░░░░░░░██████████████████");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("██░░░░░░░░░░░░░░░░░░░░░░░░░░░██");
System.out.println("▓██░░░░░░░░░░░░░░░░░░░░░░░░██");
System.out.println("▓▓▓███░░░░░░░░░░░░░░░░░░░░█");
System.out.println("▓▓▓▓▓▓███░░░░░░░░░░░░░░░██");
System.out.println("▓▓▓▓▓▓▓▓▓███████████████▓▓█");
System.out.println("▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓██");
System.out.println("▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓█");
System.out.println("▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓█");
if (e == 0) {
while (b > 0) {
System.out.println ("You have " + c +" health points");
System.out.println ("The health of the monster has " +b);
System.out.println ("The frog has an AK-47 but doesn't know how to aim so it is 40% that he'll shoot you in the head.");
System.out.println("You can either: \n1.) Attack with your sword (5 dmg) \n2.) Attack with your boomerang \n3.) Take cover (never get hit)");
d = input.nextInt();
pepe = (int)((10 - 2 + 1) * Math.random() + 2);
if (d==3) {
System.out.println("\nYou took cover! There's no way you could be shot from here!");
c = 20;
pepe = 6;
}
if (c <= 0) {
System.out.println ("You died.");
System.out.println ("Respawning you to last checkpoint (before boss battle)\n");
System.out.println("________");
System.out.println(" ( )");
System.out.println(" \\../");
System.out.println(" )(");
System.out.println(" / \\");
System.out.println(" (::::)");
System.out.println("~~~~~~~~");
b = 50;
c = 20;
e = 0;
} else {
if (4 >= pepe) {
System.out.println("\nPEPE NO-SCOPED U OFF THE FRONT LINES WITH THAT NICE RNG!");
System.out.println("You ded. Respawning you back to the boss battle.");
System.out.println("__________████████_____██████");
System.out.println("_________█░░░░░░░░██_██░░░░░░█");
System.out.println("________█░░░░░░░░░░░█░░░░░░░░░█");
System.out.println("_______█░░░░░░░███░░░█░░░░░░░░░█");
System.out.println("_______█░░░░███░░░███░█░░░████░█");
System.out.println("______█░░░██░░░░░░░░███░██░░░░██");
System.out.println("_____█░░░░░░░░░░░░░░░░░█░░░░░░░░███");
System.out.println("____█░░░░░░░░░░░░░██████░░░░░████░░█");
System.out.println("____█░░░░░░░░░█████░░░████░░██░░██░░█");
System.out.println("___██░░░░░░░███░░░░░░░░░░█░░░░░░░░███");
System.out.println("__█░░░░░░░░░░░░░░█████████░░█████████");
System.out.println("_█░░░░░░░░░░█████_████___████_█████___█");
System.out.println("_█░░░░░░░░░░█______█_███__█_____███_█___█");
System.out.println("█░░░░░░░░░░░░█___████_████____██_██████");
System.out.println("░░░░░░░░░░░░░█████████░░░████████░░░█");
System.out.println("░░░░░░░░░░░░░░░░█░░░░░█░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░██░░░░█░░░░░░██");
System.out.println("░░░░░░░░░░░░░░░░░░██░░░░░░░███████");
System.out.println("░░░░░░░░░░░░░░░░██░░░░░░░░░░█░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("░░░░░░░░░░░█████████░░░░░░░░░░░░░░██");
System.out.println("░░░░░░░░░░█▒▒▒▒▒▒▒▒███████████████▒▒█");
System.out.println("░░░░░░░░░█▒▒███████▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒█");
System.out.println("░░░░░░░░░█▒▒▒▒▒▒▒▒▒█████████████████");
System.out.println("░░░░░░░░░░████████▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒█");
System.out.println("░░░░░░░░░░░░░░░░░░██████████████████");
System.out.println("░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█");
System.out.println("██░░░░░░░░░░░░░░░░░░░░░░░░░░░██");
System.out.println("▓██░░░░░░░░░░░░░░░░░░░░░░░░██");
System.out.println("▓▓▓███░░░░░░░░░░░░░░░░░░░░█");
System.out.println("▓▓▓▓▓▓███░░░░░░░░░░░░░░░██");
System.out.println("▓▓▓▓▓▓▓▓▓███████████████▓▓█");
System.out.println("▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓██");
System.out.println("▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓█");
System.out.println("▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓█");
b = 50;
c = 20;
e = 0;
} else {
System.out.println("\nPepe shot with his AK-47. It missed!");
}
if (d == 2) {
boomatk = (int) ((2 - 1 + 1) * Math.random() + 1);
b = b - boomatk;
System.out.println("\nYou hit the enemy with your boomerang! The monster now has " + b + " HP.");
System.out.println("Pepe shot but he missed!");
} else {
if (d==1) {
System.out.println("\nYou inflicted 5 damage to the meanie.. :)");
b = b - 5;
if (b == 0) {
System.out.println("\nYou defeated one of the meme lords.");
System.out.println("\nYou returned back to the mage's house and found out the treasure was a necklace.");
System.out.println("He thanked you and summoned a portal for you to get to the Dragon's Den.");
System.out.println("TIME TO DEFEAT THE BOSS!\n");
}
}else {
if (b == 0) {
System.out.println("\nYou defeated one of the meme lords.");
System.out.println("\nYou returned back to the mage's house and found out the treasure was a necklace.");
System.out.println("He thanked you and summoned a portal for you to get to the Dragon's Den.");
System.out.println("TIME TO DEFEAT THE BOSS!\n");
}
}
}
}
}
}
DragonsDen();
}
You will need to write around 150-200 words to do a good job
For this particular segment I did alone, I created the Castle Level with the boss who can randomly instant-kill you with a random number generator. I added options where you can attack and risk getting killed or taking cover and playing it safe. What is also unique is that using the attack button 7 times in a row can get you killed than taking cover and missing the monster’s attack. Additionally, I added another weapon called the boomerang which has a random number generator as well which determines if you dealt extra damage or not. After defeating the boss, I added in more coding that allowed you to move to the final level of the program, the Dragon’s Den. With this being one of the ways you can go in the game, this boss and the Castle Level are pretty extraordinary and fun to test your luck.