DeprecationWarning: an integer is required (got type float). Implicit conversion to integers using
int
is deprecated, and may be removed in a future version of Python.
win.blit(playerStand, (x, y))
DeprecationWarning: an integer is required (got type float). Implicit conversion to integers using
int
is deprecated, and may be removed in a future version of Python.
win.blit(walkLeft[animCount // 5], (x, y))
警告与^{} 的坐标参数有关。浮点坐标意味着^{} 的原点在窗口中的到个像素之间。那没什么意义。坐标会自动隐式截断,并由警告指示。} 或^{} 将浮点坐标转换为整数:
使用^{
相关问题 更多 >
编程相关推荐