Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisPritchard committed Apr 29, 2019
1 parent 0fe3fec commit fd0043a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions samples/space-invaders-clone/Program.fs
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ let sprite (sw, sh, sx, sy) (w, h) (x, y) colour =
let text = text "connection" 24. Colour.White (0., 0.)

let random = System.Random()
let random chance =
let check chance =
random.NextDouble () <= chance

let view model dispatch =
Expand Down Expand Up @@ -257,7 +257,7 @@ let view model dispatch =
yield fun _ _ _ ->
if not (Array.isEmpty model.invaders)
&& List.length model.invaderProjectiles < maxInvaderProjectiles
&& random invaderShootChance then
&& check invaderShootChance then
dispatch InvaderShoot

yield fun _ _ _ -> dispatch MoveProjectiles
Expand Down

0 comments on commit fd0043a

Please sign in to comment.