首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往
您找到你想要的搜索结果了吗?
是的
没有找到

使用 Python 开发一个恐龙跑跑小游戏,玩起来

restart_rect.x,restart_rect.y = (900-restart.get_rect().width)/2,(200-restart.get_rect().height)/2+50 # 加载 gameover...gameover = pygame.image.load("dino/gameover.png") gameover_rect = gameover.get_rect() gameover_rect.x..., gameover_rect.y = (     900-gameover.get_rect().width)/2, (200-gameover.get_rect().height)/2 # 地面移动速度与距离... = 10             # 设置重新再来图片             screen.blit(restart, restart_rect)             screen.blit(gameover..., gameover_rect)             pygame.display.update() 对于碰撞,只要恐龙碰撞到了仙人掌,那么游戏结束,展示重新再来图片 由于我们希望游戏可以记录我们的最好成绩

35830
领券