diff options
Diffstat (limited to 'src/Update')
-rw-r--r-- | src/Update/CloudUpdate.elm | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/Update/CloudUpdate.elm b/src/Update/CloudUpdate.elm index ecbce8b..f509a5f 100644 --- a/src/Update/CloudUpdate.elm +++ b/src/Update/CloudUpdate.elm @@ -51,10 +51,9 @@ cloudUpdate time boardSize seed player {points, spawn, lastSpawn} = presentPoints : Float -> Vec2 -> List Point -> List Point presentPoints time boardSize points = - let isPresent point = (distance (pointMove point time) originVec) < (pointAwayDist boardSize) + let isPresent point = (distance (pointMove point time) originVec) < (pointSpawnDist boardSize) in List.filter isPresent points - getNewPoint : Float -> Vec2 -> Seed -> (Point, Seed) getNewPoint time boardSize seed = let (initPos, seed') = pointInitPos boardSize seed @@ -74,7 +73,7 @@ pointInitPos : Vec2 -> Seed -> (Vec2, Seed) pointInitPos boardSize seed = let (rand, seed') = generate floatGen seed angle = rand * (degrees 360) - dist = (boardDiagonal boardSize) * 3 / 5 + dist = pointSpawnDist boardSize in (polarToCartesian angle dist, seed') pointDestination : Vec2 -> Seed -> (Vec2, Seed) |