Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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.
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

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

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

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

Get Started

Students also viewed these Databases questions