我正在尝试制作我的玩家何时被击中的动画,以使他看起来像是倒在地上。我已经尝试了下面的代码,但这似乎不起作用。它减慢了帧的速度并且只显示我的动画的最后一张图像在 pygame 中是否有更简单的动画方式? if player2_hit_sequence == True: stage1 = True if stage1 == True: game_display.blit(dying1_p2, (player2X, player2Y)) time.sleep(0.2) stage1 = False stage2 = True if stage2 == True: game_display.blit(dying2_p2, (player2X, player2Y)) time.sleep(0.2) stage2 = False stage3 = True if stage3 == True: game_display.blit(dying3_p2, (player2X, player2Y)) time.sleep(0.2)是否有制作一系列图像或类似功能的功能?
添加回答
举报
0/150
提交
取消