Commit 10ba0a94 by BellCodeEditor

save project

parent 8f00f165
Showing with 16 additions and 1 deletions
...@@ -83,6 +83,21 @@ while True: ...@@ -83,6 +83,21 @@ while True:
if center[0] < 25: if center[0] < 25:
center[0] += 1 center[0] += 1
if states ==False:
states =true
center =[2,8]
shape =random.choice(shape_list)
index =random.randint(0,len(shape)-1)
current_shape =shape[index]
color =random.choice(cube_colors)
elif event.key ==locals.k_up: elif event.key ==locals.k_up:
old_index+=1 old_index+=1
index +=1 index +=1
...@@ -92,7 +107,7 @@ while True: ...@@ -92,7 +107,7 @@ while True:
if check(center) ==false: if check(center) ==false:
index =old_index index =old_index
current_shape =shape[index] current_shape =shape[index]
# 将背景图画上去 count += 1
screen.blit(background, (0, 0)) screen.blit(background, (0, 0))
# 计算出所有小方块的行、列位置 # 计算出所有小方块的行、列位置
current_pos = [] current_pos = []
......
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