pygame删除非精灵对象
因此,我正在尝试制作一个向上的滚动平台游戏,我需要一种方法来删除分数计数器并在玩家死亡并重新启动时隐藏死亡屏幕。但是,这些对象不是精灵。还有一种删除它们的方法吗?
So Im trying to make an upward scrolling platformer, and I need a way to delete the score counter and hide the death screen when a player dies and restarts. However, those objects aren't sprites. Is there still a way to delete them?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这只是一个示例,因为您尚未提供任何代码:'(
您必须使用游戏来代码,但希望它会有所帮助:))。
this is just an example because you have not provided any code :'(
you have to personilize this code with your game but hopefully it helps :))).