我尝试在文本中使用带有“x”变量的文本制作标签。我的问题是标签有大括号。这是我的代码示例。我该如何删除它们?
victory_screen=Label(root,compound=CENTER, text=("PLAYER 1 WINS with
",x,"points""\n""\n""\n""\n""\n""\n"))
答案 0 :(得分:1)
只需将while not Fin:
for event in pygame.event.get():
if event.type == pygame.KEYDOWN
MoveUp = event.key
替换为,
s即可。如:
+