-
Notifications
You must be signed in to change notification settings - Fork 2
/
random.js
96 lines (92 loc) · 2.16 KB
/
random.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
//popular players for random
var newPlayers = [
"Zion Williamson",
"Luka Doncic",
"Lamelo Ball",
"James Harden",
"Kyrie Irving",
"Julius Randle",
"Devin Booker",
"Ja Morant",
"Damian Lillard",
"Ben Simmons",
"Joel Embiid",
"Nikola Jokic",
"Jamal Murray",
"Jaylen Brown",
"Jayson Tatum",
"Bam Adebayo",
"Zach Lavine",
"Giannis Antetokounmpo",
"Donovan Mitchell",
"Anthony Davis",
"Bradley Beal",
"Trae Young",
"Brandon Ingram",
"De'Aaron Fox",
"Collin Sexton",
"Pascal Siakam",
"Karl-Anthony Towns",
"Domantas Sabonis",
"Lonzo Ball",
"Anthony Edwards",
"John Collins",
"Tyrese Haliburton",
"Tyler Herro",
"Kristaps Porzingis",
"Jaren Jackson Jr.",
"Deandre Ayton",
"Jerami Grant",
"James Wiseman",
"Cade Cunningham",
"Jalen Green",
"Evan Mobley",
"Scottie Barnes"
]
var oldPlayers = ["Larry Bird",
"Magic Johnson",
"Julius Erving",
"Kareem Abdul-Jabbar",
"Wilt Chamberlain",
"Moses Malone",
"Patrick Ewing",
"Shawn Kemp",
"Charles Barkley",
"Shaquille O'Neal",
"Phil Jackson",
"Reggie Miller",
"Karl Malone",
"Dominique Wilkins",
"Clyde Drexler",
"John Stockton",
"George Gervin",
"James Worthy",
"Isiah Thomas",
"John Havlicek",
"Rick Barry",
"Bill Russell",
"George Mikan",
"Pete Maravich",
"Walt Frazier",
"Jerry West",
"Bill Walton",
"Hakeem Olajuwon",
"David Robinson",
"Michael Jordan",
"Chris Mullin",
"Scottie Pippen",
"Elgin Baylor",
"Oscar Robertson",
"Elvin Hayes",
"Alex English",
"Willis Reed",
"Bob Cousy"
]
function randomOld(){
var player = oldPlayers[Math.floor(Math.random()*oldPlayers.length)]
document.querySelector("#playerInput2").value = player
}
function randomNew(){
var player = newPlayers[Math.floor(Math.random()*newPlayers.length)]
document.querySelector("#playerInput1").value = player
}