Modified controller to fix autoplay problemo