first test
This commit is contained in:
22
main.py
22
main.py
@@ -0,0 +1,22 @@
|
|||||||
|
import pygame
|
||||||
|
import random
|
||||||
|
|
||||||
|
#start
|
||||||
|
pygame.init()
|
||||||
|
|
||||||
|
#background
|
||||||
|
WIDTH , HEIGHT = 600,200
|
||||||
|
screen = pygame.display.set_mode((WIDTH,HEIGHT))
|
||||||
|
pygame.display.set_caption("dinosour running")
|
||||||
|
|
||||||
|
#colour
|
||||||
|
WHITE = (255,255,255)
|
||||||
|
BLACK = (0,0,0)
|
||||||
|
|
||||||
|
clock = pygame.time.Clock()
|
||||||
|
FPS = 60
|
||||||
|
gravity = 0.8
|
||||||
|
jump_vel = -16
|
||||||
|
is_jump = False
|
||||||
|
|
||||||
|
#dinosaur
|
||||||
Reference in New Issue
Block a user