// Start of a simple game that scores the number of times a player // can hit a target with a ship within a time of their choice package { import flash.display.*; import flash.events.*; import flash.ui.*; public class Assign4 extends MovieClip { public function Assign4( ) { // TASK 1: Create a custom score property for the ship and // initialize it to 0 // TASK 2: Add a KEY_DOWN event listener to allow the player to move the ship } // end constructor function moveShip( evt: KeyboardEvent ) { // TASK 1: Check which key has been pressed. If it's an // arrow key, rotate and move the ship in that direction // TASK 2: Check if player has hit target. If so, // add 1 to the player's score and display it in the text field. } // end moveShip function } }