I'm trying to make the character flip to the left when he is walking left and flip to the right when he is walking right and it says this "invalid set index 'flip_h' (on base: 'null instance') with value of type 'bool'." Please could you help I've been stuck on this for a few hours and I don't know how to fix it. This is the script I am using:
if vel.x < 0:
sprite.flip_h = true
elif vel.x > 0:
sprite.flip_h = true