Course:CPSC312-2023/2DBasketball

From UBC Wiki

Basketball 🏀

Authors: Sarah Ibrahim, Kevin Wong

What is the problem?

Our goal is to implement a 2D basketball game using Prolog! In this implementation, the player will be shooting a basketball towards a hoop on on the right side of the screen. The speed and direction of the ball will be determined by a power meter and an arrow that continuously oscillates between 0 to 90 degrees respectively.

What is the something extra?

We will use XPCE to implement a GUI for the game! This GUI will include the basketball to be controlled by the player, the goal hoop, and the oscillating arrow animations determining the velocity of the ball. The player will be able to launch the ball at their desired velocity by pressing the space bar. The game physics at various points of the ball's trajectory will be implemented as well.

What did we learn from doing this?

(This should be written after you have done the work.) What is the bottom-line? Is functional programming suitable for (part-of) the task? Make sure you include the evidence for your claims.

Links