Update: rand
This commit is contained in:
parent
a5fddf9ee6
commit
5f27ed4720
|
@ -7,4 +7,4 @@ publish = false
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
iced = { path = "../..", features = ["canvas", "tokio", "debug"] }
|
iced = { path = "../..", features = ["canvas", "tokio", "debug"] }
|
||||||
rand = "0.7"
|
rand = "0.8.3"
|
||||||
|
|
|
@ -117,15 +117,13 @@ impl State {
|
||||||
(
|
(
|
||||||
Point::new(
|
Point::new(
|
||||||
rng.gen_range(
|
rng.gen_range(
|
||||||
-(width as f32) / 2.0,
|
(-(width as f32) / 2.0)..(width as f32 / 2.0),
|
||||||
width as f32 / 2.0,
|
|
||||||
),
|
),
|
||||||
rng.gen_range(
|
rng.gen_range(
|
||||||
-(height as f32) / 2.0,
|
(-(height as f32) / 2.0)..(height as f32 / 2.0),
|
||||||
height as f32 / 2.0,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
rng.gen_range(0.5, 1.0),
|
rng.gen_range(0.5..1.0),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
.collect()
|
.collect()
|
||||||
|
|
Loading…
Reference in New Issue