-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdata.lua
More file actions
78 lines (69 loc) · 2.17 KB
/
data.lua
File metadata and controls
78 lines (69 loc) · 2.17 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
76
77
78
local package = ...
local counter = 0
local counter1 = 0
local tbl = Map.GetSettings()
local resourcemode = tbl['resource_richness']
function package:init()
for k, v in pairs( data.techs ) do
if data.techs[ k ].progress_count == nil then
else
x = data.techs[ k ].progress_count
data.techs[ k ].progress_count = x*0
end
end
for k, v in pairs( data.components ) do
if data.components[ k ].production_recipe == nil then
else
data.components[ k ].production_recipe = CreateProductionRecipe({ }, { c_fabricator = 5 })
end
end
for k, v in pairs( data.frames ) do
if data.frames[ k ].construction_recipe == nil then
else
data.frames[ k ].construction_recipe = CreateConstructionRecipe({ }, 5)
end
if data.frames[ k ].production_recipe == nil then
else
data.frames[ k ].production_recipe = CreateProductionRecipe({ }, { c_fabricator = 5 })
end
end
while #data.land_features >= 29 and counter1 < 2 do
table.remove(data.land_features, 29)
counter1 = counter1 + 1
end
if counter < 3 and resourcemode == 4
then
while #data.land_features >= 2 and counter < 3 do
table.remove(data.land_features, 2) -- remove small crystals
counter = counter + 1
end
end
if counter >= 3 and counter < 5
then
while #data.land_features >= 3 and counter < 5 do
table.remove(data.land_features, 3) -- remove small metals
counter = counter + 1
end
end
if counter >= 5 and counter < 7
then
while #data.land_features >= 4 and counter < 7 do
table.remove(data.land_features, 4) -- remove small silica
counter = counter + 1
end
end
if counter >= 7 and counter < 9
then
while #data.land_features >= 5 and counter < 7 do
table.remove(data.land_features, 5) -- remove small laterite
counter = counter + 1
end
end
if counter >= 9 and counter < 10
then
while #data.land_features >= 7 and counter < 10 do
table.remove(data.land_features, 7) -- remove small laterite
counter = counter + 1
end
end
end