Fork me on GitHub

Modify Pygame

by Zekun Yu

13 Nov 2013

Modify Paygame

Firstly, I change the frame rates or other variables at the top:

FPS = 10
WINWIDTH = 1000
WINHEIGHT = 800
HALF_WINWIDTH = int(WINWIDTH / 2)
HALF_WINHEIGHT = int(WINHEIGHT / 2)

TILEWIDTH = 60
TILEHEIGHT = 90
TILEFLOORHEIGHT = 50

CAM_MOVE_SPEED = 8

OUTSIDE_DECORATION_PCT = 30

BRIGHTBLUE = (155, 155, 155)
WHITE      = (255, 255, 255)
BGCOLOR = BRIGHTBLUE
TEXTCOLOR = WHITE

OUTSIDE_DECORATION_PCT = 30

BRIGHTBLUE = (155, 155, 155)
WHITE      = (255, 255, 255)
BGCOLOR = BRIGHTBLUE
TEXTCOLOR = WHITE

Secondly, I change the default pictures used in the game.

It looks like:

Image

Also, I make some changes in starPusherLevels.txt, so I can control the layout and difficulty of the game.

It looks like:

Image

Image

Yu is a first year MSIS student. He likes programming and wants to learn more from class. Find Zekun Yu on Twitter, Github, and on the web.
comments powered by Disqus