I am busy making a game in python using tkinter, time and PIL, and I have a character that I want to animate very simply, but when I try this code, it doesn't do anything then jumps to the last image, can someone please tell me why this is?
def move_char(event):
if event.keysym == "w":
character = ch1
c.delete(character)
character = ch2_1
c.create_image(725, 450, image = character)
sleep(0.2)
c.delete(character)
character = ch2
c.create_image(725, 450, image = character)
sleep(0.2)
c.delete(character)
character = ch2_2
c.create_image(725, 450, image = character)
sleep(0.2)
c.delete(character)
character = ch2
c.create_image(725, 450, image = character)
Appreciate any help