Question: MILESTONE 5 : HIGH FIRST ( up to 1 0 0 % ) a . Introduce an NPC to the game: i . Create an

MILESTONE 5: HIGH FIRST (up to 100%)
a. Introduce an NPC to the game:
i. Create an enemy sphere model and set its skin to enemysphere.jpg.
ii. Choose a random position far away from the player sphere to position the enemy
sphere.
iii. Implement automatic movement for the enemy sphere, and set it up so that it
can pick up cubes in the same manner as the player sphere. At a minimum,
implement this so that the sphere appears tomake random movement decisions
e.g. whether to move up or down, left or right. Full marks will beawarded for
implementing "intelligent" behaviour.
iv. Declare an integer variable called enemyPoints to keep track of the enemy
sphere's points.
v. If the enemy sphere collides with the player sphere, they should bounce off
each other if the difference between their points is not greater than 40,
otherwise, the sphere with the higher pointsshould pick up the other sphere,
earn 40 points and increase in size by a factor of 1.2.
b. If the enemy sphere accumulates 120 points before the player sphere, or If the
player sphere is pickedup by the enemy sphere, then the game should enter a
GameOver state.
i. In the GameOver state, a game over message should be displayed on the
centre of the screen, however, the enemy sphere should continue to move
around as usual on the floor.
c. List the points of the player and NPC, highest point first, and aligned to the right of the
screen.
 MILESTONE 5: HIGH FIRST (up to 100%) a. Introduce an NPC

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!