Skip to content

Commit

Permalink
Remove use of deprecated rand functions
Browse files Browse the repository at this point in the history
  • Loading branch information
StackDoubleFlow committed Jan 31, 2025
1 parent 931cd3b commit 3d240d2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crates/core/src/plot/worldedit/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -868,8 +868,8 @@ impl WorldEditPattern {
weight_sum += part.weight;
}

let mut rng = rand::thread_rng();
let mut random = rng.gen_range(0.0..weight_sum);
let mut rng = rand::rng();
let mut random = rng.random_range(0.0..weight_sum);

let mut selected = &WorldEditPatternPart {
block_id: 0,
Expand Down

0 comments on commit 3d240d2

Please sign in to comment.