1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

rand: change rand.seed() to receive seed value

This commit is contained in:
d2verb
2019-07-14 01:17:45 +09:00
committed by Alexander Medvednikov
parent af7d49103b
commit 2cb12b4f4e
5 changed files with 41 additions and 12 deletions

View File

@ -140,7 +140,7 @@ fn main() {
}
fn (g mut Game) init_game() {
rand.seed()
rand.seed(time.now().uni)
g.generate_tetro()
g.field = []array_int // TODO: g.field = [][]int
// Generate the field, fill it with 0's, add -1's on each edge