A real basketball would fall to the floor and then bounce.

  • Click to open that section of the toolkit.
  • Drag Set Gravity into your program.
  • Drag Set Bounce into your program.
  • Click Run to see your work. Click Submit and Next to move on.

stage.set_background("halfcourt") sprite = codesters.Sprite("player4") sprite.go_to(215, -175) net = codesters.Sprite("basketballnet") net.go_to(215, 175) ball = codesters.Sprite("basketball") x = random.randint(-100, 150) ball.go_to(x, -25)