Cash-back offer from April 23rd to 27th, 2024: Get a flat 10% cash-back credited to your account for a minimum transaction of $50.Post Your Questions Today!

Question DetailsNormal
$ 40.00

CS 2530 Homework 7 - Robot Attack V2.0 | Complete Solution

Question posted by
Online Tutor Profile
request

Homework 7 - Robot Attack V2.0

Assignment:
You will create a new version of the Robot Attack app that you created in homework 2. In this version you will utilized the abstract class Robot and create subclasses with different implementations.

BattleDroid

  • Max power level of 50.
  • It has a range attack that causes a damage of 10 units, and has a 50% chance of hitting.
  • It has a melee attack that causes a damage of between 5 and 20 units, with a 95% chance of hitting.
  • They alternate between the range and melee attack.
  • Once their power level drops below 20 they will try to restore power. Each time they take this action they go up a random amount between 0 and 20.



SuperBattleDroid

  • Max power level of 100.
  • It has a range attack that causes a damage of 15 units, and has a 60% chance of hitting.
  • It has a melee attack that causes a damage of between 10 and 25 units, with a 90% chance of hitting.
  • They will randomly choose between the range and melee attack.
  • Once their power level drops below 10 they will try to restore power. Each time they take this action they go up a random amount between 0 and 10.



Cylon

  • Max power level of 200.
  • It has a range attack that causes a damage of 20 units, and has a 25% chance of hitting.
  • It has a melee attack that causes a damage of 5 units, and has a 90% chance of hitting.
  • They are agressive and will begin using their ranged attack, and continue doing so if they are successful at least once in the last three range attacks.
  • Once they have missed 3 times in a row with the range attack, they will use a melee attack.



Cylon

  • Max power level of 150.
  • It has a range attack that causes a damage of 100 units, and has a 5% chance of hitting.
  • It has a melee attack that causes a damage of 20 units, and has a 90% chance of hitting.
  • It will use its range attack while it's power is above 100, and then switch to the melee attack. If, however, its power level falls below 10 it will switch back to its range attack.
  • It only has the ability to use the range attack 10 times, once it has used up these 10 rounds, it must only use it's melee attack.



Goals:

 

  • Implement classes that use inheritence and abstract methods.
  • Understand how to code to the contract.
  • Utilize polymorphism to use any of the robot classes you create.

 



Assignment tips:

 

  • Use the code provided! (It includes the main program, Action, ActionResult and the abstract Robot class).
  • Use the APIs provided! (They will define what methods you need to implement in your subclasses).
  • Implement and test each subclass seperately.
  • Code incrementally. For example, implement and test each method one at a time.
  • To add the JavaDoc comments, complete the method and then type "/**" on the line above, and Eclipse will create the template for you.

 



Grading Rubric

You will only get points if your classes compile.

  • For each robot class that you implement correctly to the API, you will get: 2 points (max of 8 points)
    Be sure to include the JavaDoc style comments. See my code for examples.
  • Screen shot of your program successfully runing: 2 point
  • Code does not compile: 0 point



Homework Resources

The code is avaliable here: Robot.zip. The only code you will need to add are the new robot classes you create.

The APIs can be found here: Robot API.


Homework Submission

Zip up all of your source code into .zip file and submit on the homework submission site.

Available Answer
$ 40.00

[Solved] CS 2530 Homework 7 - Robot Attack V2.0 | Complete Solution

  • This Solution has been Purchased 2 time
  • Submitted On 13 Mar, 2015 12:54:40
Answer posted by
Online Tutor Profile
solution

This Tutorial is rated A+ previously,if...

Buy now to view the complete solution
Other Similar Questions
User Profile
AceTu...

CS 2530 Homework 7 - Robot Attack V2.0 | Complete Solution

This Tutorial is rated A+ previously,if you have any questions regarding this tutorial then you can contact me.

http://www.coursemerit.com/user/AceTutor

...

The benefits of buying study notes from CourseMerits

homeworkhelptime
Assurance Of Timely Delivery
We value your patience, and to ensure you always receive your homework help within the promised time, our dedicated team of tutors begins their work as soon as the request arrives.
tutoring
Best Price In The Market
All the services that are available on our page cost only a nominal amount of money. In fact, the prices are lower than the industry standards. You can always expect value for money from us.
tutorsupport
Uninterrupted 24/7 Support
Our customer support wing remains online 24x7 to provide you seamless assistance. Also, when you post a query or a request here, you can expect an immediate response from our side.
closebutton

$ 629.35