-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconf.lua
More file actions
75 lines (60 loc) · 1.6 KB
/
conf.lua
File metadata and controls
75 lines (60 loc) · 1.6 KB
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
function love.conf(t)
-- to change the number of blocks the screen spans, change the variables directly below
xblocks = 50
yblocks = 40
t.window.width = xblocks*16
t.window.height = yblocks*16+80
--Time delay between placing blocks
grab_delay = 15;
--Time delay between stealing blocks
steal_delay = 60;
--Initialize ColorGrid
--ColorGrid contains the color in each play cell. 1st and 2nd indices are for position.
--3rd is for red, green or blue (indices 0,1,2, respectively)
ColorGrid = {}
for i = 0, xblocks-1 do
ColorGrid[i] = {}
for j = 0, yblocks-1 do
ColorGrid[i][j] = {}
for k = 0, 2 do
ColorGrid[i][j][k] = 100
end
end
end
--Initialize OwnerGrid
--OwnerGrid tells you what player owns each square
OwnerGrid = {}
for i = 0, xblocks-1 do
OwnerGrid[i] = {}
for j = 0, yblocks-1 do
OwnerGrid[i][j] = "nobody"
end
end
--Initialize HazardGrid
--HazardGrid tells you where non-turf objects are located
--Possible options: "nothing", "water", "chaos", "lava", "radioactive", "forest", "mountain", "grassland", "desert", "light",
--"cave", "tundra", "metal", "dark", "stonehead", "tallmountain", "stronghold"
HazardGrid = {}
for i = 0, xblocks-1 do
HazardGrid[i] = {}
for j = 0, yblocks-1 do
HazardGrid[i][j] = "nothing"
end
end
--Initialize CleaveGrid
--HazardGrid keeps track of which spaces are about to cleave in two
CleaveGrid = {}
for i = 0, xblocks-1 do
CleaveGrid[i] = {}
for j = 0, yblocks-1 do
CleaveGrid[i][j] = 0
end
end
RebelGrid = {}
for i=0, xblocks-1 do
RebelGrid[i] = {}
for j=0, yblocks-1 do
RebelGrid[i][j] = 0
end
end
end --end of the config