33 lines
427 B
Python
33 lines
427 B
Python
# Import library code
|
|
from p5 import *
|
|
from random import randint
|
|
|
|
# Set up global variables
|
|
screen_size = 400
|
|
|
|
# The draw_rocket function goes here
|
|
|
|
|
|
|
|
# The draw_background function goes here
|
|
|
|
|
|
|
|
def setup():
|
|
# Set up your animation here
|
|
size(screen_size, screen_size)
|
|
image_mode(CENTER)
|
|
global planet
|
|
planet = load_image('planet.png')
|
|
|
|
|
|
def draw():
|
|
# Things to do in every frame
|
|
|
|
|
|
|
|
|
|
run()
|
|
|
|
|
|
|