moiri / kobold

jump and run on web page
2 stars 0 forks source link

Manually Scrolling #36

Closed moiri closed 10 years ago

moiri commented 11 years ago

Scrolling manually is very slow, when character is below the window overflow delta

moiri commented 10 years ago

As soon as the movable is below the window, the window overflow callback function scrolls the window in the direction of the movable in order to "center it again". A manual scrolling counteracts this -> the scrolling seems slow. Solution1: prevent manual scrolling as long as the movable is active Solution2: on receiving a scroll event, ignore the position of the movable. On movable action, scroll to the right position. This would require to check the position in all directions upon input command (now it only checkes the position related to the direction of the command)