pygame game opening animation rendering learning, draw 10*7=70 small squares

This series of columns will take you to consolidate your knowledge of Python by continuously writing games.

The purpose of this blog

The main goal today is to draw 10*7a small box, shown in renderings and ultimately follows.

pygame game opening animation rendering learning, draw 10*7=70 small squares

Logic realization

To draw a square on the interface, you only need to get the coordinates, the color of the square is white, and the width is designed to be 40 pixels.

The core function call is:

# 游戏开场动画
start_game_animation(main_board)

Function body content

# 游戏入场动画函数
def start_game_animation

Guess you like

Origin blog.csdn.net/hihell/article/details/115229659