-
Notifications
You must be signed in to change notification settings - Fork 0
/
constant.js
62 lines (59 loc) · 818 Bytes
/
constant.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
const COLS = 10;
const ROWS = 20;
const CELL = 25
const figures = {
'I': [
[0,0,0,0],
[1,1,1,1],
[0,0,0,0],
[0,0,0,0]
],
'J': [
[1,0,0],
[1,1,1],
[0,0,0],
],
'L': [
[0,0,1],
[1,1,1],
[0,0,0],
],
'O': [
[1,1],
[1,1],
],
'S': [
[0,1,1],
[1,1,0],
[0,0,0],
],
'Z': [
[1,1,0],
[0,1,1],
[0,0,0],
],
'T': [
[0,1,0],
[1,1,1],
[0,0,0],
]
};
const color = {
'I': 'blue',
'J': 'yellow',
'L': 'green',
'O': 'purple',
'S': 'red',
'Z': 'orange',
'T': 'brown'
};
const levels = {
1: 1000,
2: 900,
3: 800,
4: 700,
5: 600,
6: 500,
7: 450,
8: 400
};