optimized ui and fixed glitchiness