assignment

Unit 3 Assignment: Animation Programs – Using ParametersUnit outcomes: Define a parameter.  Use a parameter in a method (procedure).  Discuss the relationship between a parameter and an argument.Course outcome(s) practiced in this unit:IT111-2: Apply the programming constructs of parameters and arguments.Problem: Grimm exercises. The fantasy characters in Grimm stories want to change their public image (which is slovenly, overweight, and aggressive). They want to become more physically fit and friendly characters. With this in mind, Sam (Ogre) and Bill (Troll) are starting an exercise class for the Grimm community. Create an animation where Sam and Bill demonstrate knee bend exercises.Initial Scene: In the Scene Editor, create an initial fantasy scene. Your scene does not have to look like the one shown, but can use any fantasy objects you choose to use. Be creative with the scene. However, it must have two fantasy characters, Sam (Ogre) and Bill (Troll) in the fantasy setting of your choice. You will find the Ogre class and the Troll class under the Biped class. Give the Ogre object you create the name Sam. Give the Troll object you create the name Bill. Once you have created your scene, save the world as GrimmExercise.Unit 3 [IT111: Programming Concepts]Algorithm: Do in order Sam knee bendBill knee bendDo togetherSam knee bendBill knee bendOf course, the Ogre and Troll classes do not have a knee bend procedural method. Therefore, you will need to write your own kneeBend procedure for each class. Decomposition: Start by decomposing the procedure into simple steps. Below is an example procedural decomposition, using the Ogre’s joint structure. This procedure is a bit more complicated than you might expect. This is because a knee bend is actually a combination of bending both knees and lifting both arms upward (for balance). In this example, the numbers specifying the amount of rotation for the joints is arbitrary. You may wish to experiment with other amounts to obtain a more realistic animation of a knee bend, although these amounts work fairly well.Do in order//bend knees downDo togetherEntire body move down 0.125Right and left hips turn backward 0.125Right and left ankles turn forward 0.25Right and left foot turn backward 0.15Right shoulder turn left 0.25Left shoulder turn right 0.25//return to original positionDo togetherUnit 3 [IT111: Programming Concepts]Entire body move up 0.125 mRight and left hips turn forward 0.125Right and left ankles turn backward 0.25Right and left foot turn forward 0.15Right shoulder turn right 0.25Left shoulder turn left 0.25Implementation: Create and test the program code for a kneeBend procedure in the Ogre class. HINT: This procedure has two basic parts – one part to bend the knees and one part to straighten up. You can take advantage of this in creating the code. Create the first do together code block for the downward knee bend and then hold down the ctrl key (alt on Mac) to drag a copy below to make the second code block. Then, in the second code block, reverse the motion (for example, change move down to move up) for each statement. Be sure to document and save your project before going on.Using the clipboard to duplicate code At this point in the project code, Sam (an instance of the Ogre class) has a kneeBend procedure. However, Bill (an instance of the Troll class) does not. One way to create a kneeBend procedure for the Troll class is to use the clipboard to copy and paste the code from the Ogre class to the Troll class. The screen grabs on the next page illustrate the process of using the clipboard for copy and paste of an entire procedure.(Step 1). In the procedure, if you have not already done so, add a Do in order block to enclose the two Do together blocks. Then drag the entire Do in order block to the clipboard.

Use the order calculator below and get started! Contact our live support team for any assistance or inquiry.

[order_calculator]