adjust mouse to isometric
This commit is contained in:
parent
0c6278cd5b
commit
2c6ac33e44
1 changed files with 2 additions and 2 deletions
|
@ -63,8 +63,8 @@ mouseToPlayer :: V2 Int32 -> Affection UserData ()
|
||||||
mouseToPlayer mv2 = do
|
mouseToPlayer mv2 = do
|
||||||
ud <- getAffection
|
ud <- getAffection
|
||||||
rela@(V2 rx ry) <- liftIO $ relativizeMouseCoords mv2
|
rela@(V2 rx ry) <- liftIO $ relativizeMouseCoords mv2
|
||||||
let dr = ry + rx
|
let dr = (ry / sin (atan (1/2)) / 2) + rx
|
||||||
dc = rx - ry / 2
|
dc = rx - (ry / sin (atan (1/2)) / 2)
|
||||||
(nws, nworld) <- yieldSystemT (worldState ud) $ do
|
(nws, nworld) <- yieldSystemT (worldState ud) $ do
|
||||||
emap $ do
|
emap $ do
|
||||||
with player
|
with player
|
||||||
|
|
Loading…
Reference in a new issue