Question: Problem: Develop a simple 2 D pool game described in the following. An example is provided in the assignment item on Blackboard. There are four

Problem: Develop a simple 2D pool game described in the following. An example is provided in the
assignment item on Blackboard.
There are four disks in the game, the cue disk and three other disks. The four disks are the same
size and mass, but in distinct colors. The elasticities of the four disks are equal to 1. You decide
the values of the size, mass, and colors.
> Place the cue disk on the left side of the screen, for example, at (-15,0). The other three disks are
placed together on the right side of the screen to form a triangle, with each two touching each
other. For these three disks, one is placed at the position symmetric to the cue disk about the
origin, for example at (15,0). You need to do math to find the positions of the other two disks.
The triangle is symmetric about the horizontal axis.
> Once a mouse button is pressed, a line is drawn, connecting the cue disk and the mous. When the
button is released, the cue disk gets a velocity along the line with magnitude proportional to the
length of the line. You decide the proportional coefficient.
> Resolve the collisions among the disks using the Impulse method introduced in the module.
> The bounce ratio from the boundaries of the screen is 0.75. This means if a disk bounces off a
boundary, its speed is reduced by 25%.
> Add a friction force to the disks. You decide how much the friction force is proper, such that a ball
does not stop quickly or keep moving for a long time, when no other force is acted on it.
> No other forces are added.
Demonstration: Please create a video clip to demonstarte your game. The length of the video should not
be more than one minute. At least two shots should be demonstrated. One is the shot hitting the front disk
of the three disks in the triangle, and the other is a shot hitting any one of the three disks. You can
demonstrate more shots if you would like.
Problem: Develop a simple 2 D pool game described

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 Programming Questions!