Fix glitch between animation transition