之前能运行的代码,现在运行的时候报下面错误。
Implicit conversion to integers using __int__ is deprecated, and may be removed in a future version of Python.
根据小伙伴的提示,原来是因为3.8版本对float类型的数据转int型的一个提示。
问题不大,我这里确实是要int类型的。
所以,我将数据全部加上了 int 的强制转换,然后就好了。
参考:
-pygame 贪吃蛇小游戏 部分代码错误分析
最后
以上就是精明海燕最近收集整理的关于Implicit conversion to integers using __int__ is deprecated的全部内容,更多相关Implicit内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复