Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

COMP163 Introduction to Computer Programming In this program you will write a method to try to gently land a simulated rocket on the surface. Your

image text in transcribedimage text in transcribed

COMP163 Introduction to Computer Programming In this program you will write a method to try to gently land a simulated rocket on the surface. Your program adds the throttle method to a simple game. Your program should be structured as: public class MyGame extends Lander t public double throttle (double altitude, double speed, double fuel) double burn0.0 1/ 0 to 100, rate to burn the fuel your code here to set burn to a value return burn; public static void main (Stringl] args) ( MyGame program-new MyGame) You can download the Lander class in Lander.jar from Blackboard Save the jar file some place where you can find it. InjGRASP, click on: Settings then PATH/CLASSPATH then Workspace then tab Class then tab Classpaths Click the New button Browse to the directory containing the jar file and select the Lander.jar file Press OK Run the program and try to land the rocket manually. After you press the start button, you can set the fuel rate and press the burn button. Pressing the burn button again will stop the rocket engines. The idea is to get to an altitude of zero with very low speed. Develop a strategy for landing the rocket. Assume you have the reflexes and skill necessary to implement your strategy. It is not required that your program land the rocket perfectly. Just try to do the best you can. Write a short text file or Word document defining your strategy and upload it to Blackboard. Your strategy document is a required part of this assignment COMP163 Introduction to Computer Programming In this program you will write a method to try to gently land a simulated rocket on the surface. Your program adds the throttle method to a simple game. Your program should be structured as: public class MyGame extends Lander t public double throttle (double altitude, double speed, double fuel) double burn0.0 1/ 0 to 100, rate to burn the fuel your code here to set burn to a value return burn; public static void main (Stringl] args) ( MyGame program-new MyGame) You can download the Lander class in Lander.jar from Blackboard Save the jar file some place where you can find it. InjGRASP, click on: Settings then PATH/CLASSPATH then Workspace then tab Class then tab Classpaths Click the New button Browse to the directory containing the jar file and select the Lander.jar file Press OK Run the program and try to land the rocket manually. After you press the start button, you can set the fuel rate and press the burn button. Pressing the burn button again will stop the rocket engines. The idea is to get to an altitude of zero with very low speed. Develop a strategy for landing the rocket. Assume you have the reflexes and skill necessary to implement your strategy. It is not required that your program land the rocket perfectly. Just try to do the best you can. Write a short text file or Word document defining your strategy and upload it to Blackboard. Your strategy document is a required part of this assignment

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

=+ Why do we have markets and, according to economists,

Answered: 1 week ago