move it faster
This commit is contained in:
parent
ef40eed917
commit
bbc7142b74
1 changed files with 6 additions and 6 deletions
|
@ -164,8 +164,8 @@ handle (SDL.KeyboardEvent dat) =
|
||||||
nmap <- return $ M.adjust
|
nmap <- return $ M.adjust
|
||||||
(updateProperties $ props $ prop "x" $
|
(updateProperties $ props $ prop "x" $
|
||||||
case SDL.keysymKeycode $ SDL.keyboardEventKeysym dat of
|
case SDL.keysymKeycode $ SDL.keyboardEventKeysym dat of
|
||||||
SDL.KeycodeLeft -> xpos - 5
|
SDL.KeycodeLeft -> xpos - 20
|
||||||
SDL.KeycodeRight -> xpos + 5
|
SDL.KeycodeRight -> xpos + 20
|
||||||
_ -> xpos
|
_ -> xpos
|
||||||
)
|
)
|
||||||
"rect"
|
"rect"
|
||||||
|
@ -184,7 +184,7 @@ handle (SDL.KeyboardEvent dat) =
|
||||||
then
|
then
|
||||||
case SDL.keysymKeycode $ SDL.keyboardEventKeysym dat of
|
case SDL.keysymKeycode $ SDL.keyboardEventKeysym dat of
|
||||||
SDL.KeycodeLeft ->
|
SDL.KeycodeLeft ->
|
||||||
if bgPos <= 0 then bgPos + 5 else bgPos
|
if bgPos <= 0 then bgPos + 20 else bgPos
|
||||||
SDL.KeycodeRight ->
|
SDL.KeycodeRight ->
|
||||||
bgPos
|
bgPos
|
||||||
_ -> bgPos
|
_ -> bgPos
|
||||||
|
@ -193,7 +193,7 @@ handle (SDL.KeyboardEvent dat) =
|
||||||
SDL.KeycodeLeft ->
|
SDL.KeycodeLeft ->
|
||||||
bgPos
|
bgPos
|
||||||
SDL.KeycodeRight ->
|
SDL.KeycodeRight ->
|
||||||
if True {- TODO: CHANGE-} then bgPos - 5 else bgPos
|
if bgPos >= -2489 then bgPos - 20 else bgPos
|
||||||
_ -> bgPos
|
_ -> bgPos
|
||||||
)
|
)
|
||||||
"background"
|
"background"
|
||||||
|
@ -206,11 +206,11 @@ handle (SDL.KeyboardEvent dat) =
|
||||||
then
|
then
|
||||||
xpos
|
xpos
|
||||||
else
|
else
|
||||||
xpos - 5
|
xpos - 20
|
||||||
SDL.KeycodeRight ->
|
SDL.KeycodeRight ->
|
||||||
if xpos < 40
|
if xpos < 40
|
||||||
then
|
then
|
||||||
xpos + 5
|
xpos + 20
|
||||||
else
|
else
|
||||||
xpos
|
xpos
|
||||||
_ -> xpos
|
_ -> xpos
|
||||||
|
|
Loading…
Reference in a new issue