added jump function, fixed bugs