Commit cd04f661 by BellCodeEditor

save project

parent abdcc7d2
Showing with 5 additions and 4 deletions
...@@ -20,14 +20,15 @@ while True: ...@@ -20,14 +20,15 @@ while True:
for event in pygame.event.get(): for event in pygame.event.get():
if event.type == locals.QUIT: if event.type == locals.QUIT:
exit() exit()
elif event.type==locals.K_RIGHT: if event.type==locals.KEYDOWN:
elif event.key==locals.K_RIGHT:
if lie[1]<15: if lie[1]<15:
lie[1]+=1 lie[1]+=1
elif event.type==locals.K_LEFT: elif event.key==locals.K_LEFT:
if lie[1]>1: if lie[1]>1:
lie[1]-=1 lie[1]-=1
elif event.type==locals.K_DOWN: elif event.key==locals.K_DOWN:
if lie[1]<25: if lie[0]<25:
lie[0]+=1 lie[0]+=1
# 将背景图画上去 # 将背景图画上去
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment