File size: 16,180 Bytes
b6a38d7
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
-- ========== GENERATED BY ClassDef Editor (Ctrl-Alt-F3) DO NOT EDIT MANUALLY! ==========

DefineClass.FloorSlabMaterials = {
	__parents = { "SlabMaterialsBase", },
	__generated_by_class = "ClassAsGroupPresetDef",

	properties = {
		{ category = "Subvariants", id = "broken_t_subvariants", name = "Broken T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_b_subvariants", name = "Broken B Subvariants", help = "Note that only walls have B subvariants. Floors do not.", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_r_subvariants", name = "Broken R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_rb_subvariants", name = "Broken RB Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_r_subvariants", name = "Broken Attaches R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_t_subvariants", name = "Broken Attaches T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_b_subvariants", name = "Broken Attaches B Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
	},
	Documentation = "Creates a custom floor material and defines its properties - color, required resources, integrity, etc.",
	group = "FloorSlabMaterials",
}

DefineModItemPreset("FloorSlabMaterials", { EditorName = "Floor material", EditorSubmenu = "Buildings" })

DefineClass.RoofSlabMaterials = {
	__parents = { "SlabMaterialsBase", },
	__generated_by_class = "ClassAsGroupPresetDef",

	properties = {
		{ id = "EntitySet", 
			editor = "text", default = false, },
		{ id = "roof_additional_height", name = "Roof Additional Height", 
			editor = "number", default = 0, scale = "m", slider = true, min = 0, max = 700, },
		{ category = "Subvariants", id = "broken_t_subvariants", name = "Broken T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_b_subvariants", name = "Broken B Subvariants", help = "Note that only walls have B subvariants. Floors do not.", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_r_subvariants", name = "Broken R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_rb_subvariants", name = "Broken RB Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_rt_subvariants", name = "Broken RT Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_r_subvariants", name = "Broken Attaches R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_t_subvariants", name = "Broken Attaches T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_b_subvariants", name = "Broken Attaches B Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "eave_subvariants", name = "Eave Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_eave_r_subvariants", name = "Broken Eave Attaches R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "rake_subvariants", name = "Rake Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_rake_t_subvariants", name = "Broken Rake Attaches T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_rake_b_subvariants", name = "Broken Rake Attaches B Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "ridge_subvariants", name = "Ridge Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_ridge_r_subvariants", name = "Broken Ridge Attaches R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "gable_subvariants", name = "Gable Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_gable_r_subvariants", name = "Broken Gable Attaches R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "rake_ridge_subvariants", name = "RakeRidge Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "rake_eave_subvariants", name = "RakeEave Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "rake_gable_subvariants", name = "RakeGable Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "crest_subvariants", name = "GableCrest Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "crest_top_subvariants", name = "RakeGableCrestTop Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "crest_bot_subvariants", name = "RakeGableCrestBot Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "slope_subvariants", name = "GableSlope Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "slope_top_subvariants", name = "RakeGableSlopeTop Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "slope_bot_subvariants", name = "RakeGableSlopeBot Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
	},
	Documentation = "Creates a custom material and defines its properties - color, required resources, integrity, etc.",
	group = "RoofSlabMaterials",
}

DefineModItemPreset("RoofSlabMaterials", { EditorName = "Roof material", EditorSubmenu = "Buildings" })

DefineClass.ShelterSlabMaterials = {
	__parents = { "SlabMaterialsBase", },
	__generated_by_class = "ClassAsGroupPresetDef",

	group = "ShelterSlabMaterials",
}

DefineModItemPreset("ShelterSlabMaterials", { EditorName = "Shelter material", EditorSubmenu = "Buildings" })

DefineClass.SlabIndoorMaterials = {
	__parents = { "SlabPreset", },
	__generated_by_class = "ClassAsGroupPresetDef",

	properties = {
		{ category = "Subvariants", id = "subvariants", name = "Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "corner_subvariants", name = "Corner Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_t_subvariants", name = "Broken T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_b_subvariants", name = "Broken B Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_r_subvariants", name = "Broken R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attach_attaches_t_subvariants", name = "Broken Attach Attaches T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attach_attaches_b_subvariants", name = "Broken Attach Attaches B Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attach_attaches_r_subvariants", name = "Broken Attach Attaches R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ id = "display_name", name = "Display Name", 
			editor = "text", default = false, translate = true, },
	},
	group = "SlabIndoorMaterials",
}

DefineClass.SlabMaterials = {
	__parents = { "SlabMaterialsBase", },
	__generated_by_class = "ClassAsGroupPresetDef",

	properties = {
		{ category = "Subvariants", id = "corner_subvariants", name = "Corner Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_t_subvariants", name = "Broken T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_b_subvariants", name = "Broken B Subvariants", help = "Note that only walls have B subvariants. Floors do not.", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_r_subvariants", name = "Broken R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_rb_subvariants", name = "Broken RB Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_t_subvariants", name = "Broken Attaches T Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_b_subvariants", name = "Broken Attaches B Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "broken_attaches_r_subvariants", name = "Broken Attaches R Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ id = "max_voxel_xy", name = "Max Voxel XY", help = "A room wall can only be this long when using this material.", 
			editor = "number", default = -1, min = -1, },
		{ id = "max_voxel_height", name = "Max Voxel Height", help = "A room wall can only be this high when using this material.", 
			editor = "number", default = -1, min = -1, },
		{ id = "max_voxel_depth", name = "Max Voxel Depth", help = "A room base can only be this high above ground when using this material.", 
			editor = "number", default = -1, min = -1, },
		{ id = "max_voxel_area", name = "Max Voxel Area", help = "A room can only have an area as big or smaller than this when using this material.", 
			editor = "number", default = -1, min = -1, },
		{ id = "foundation_requirement", name = "Foundation Requirement", help = "Determines how many rooms can stack on top of each other.", 
			editor = "number", default = -1, min = -1, },
		{ id = "is_symmetric", name = "Is Symmetric", 
			editor = "bool", default = false, },
		{ id = "is_small", name = "Is Small", 
			editor = "bool", default = true, },
	},
	Documentation = "Creates a custom material and defines its properties - color, required resources, integrity, etc.",
	group = "SlabMaterials",
}

DefineModItemPreset("SlabMaterials", { EditorName = "Slab material", EditorSubmenu = "Buildings" })

DefineClass.SlabMaterialsBase = {
	__parents = { "SlabPreset", },
	__generated_by_class = "ClassAsGroupPresetDef",

	properties = {
		{ id = "obj_material", name = "ObjMaterial", help = "Combat material", 
			editor = "preset_id", default = false, 
			no_edit = function(self) return g_Classes.ConstructionSite end, preset_class = "ObjMaterial", },
		{ category = "Subvariants", id = "subvariants", name = "Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ category = "Subvariants", id = "damaged_subvariants", name = "Damaged Subvariants", 
			editor = "nested_list", default = false, base_class = "SlabMaterialSubvariant", inclusive = true, },
		{ id = "repair_cost", name = "Repair Cost", help = "The repair cost per slab", 
			editor = "nested_obj", default = false, 
			no_edit = function() return not g_Classes.ConstructionCost end, base_class = "ConstructionCost", inclusive = true, },
		{ id = "repair_points", name = "Repair Points", help = "Repair work costs (40 sec = 1h)", 
			editor = "number", default = 0, scale = "sec", min = -1, },
		{ id = "health", name = "Health", help = "Room max health is calculated on the base of it's slabs health", 
			editor = "number", default = 0, scale = 1000, },
		{ id = "strength", name = "Material Strength", help = "When walls are on top of each other, the wall with most strength is the one visible.", 
			editor = "number", default = -1, min = -1, },
		{ id = "display_name", name = "Display Name", 
			editor = "text", default = false, translate = true, },
		{ id = "mat_props", name = "Material Props", 
			editor = "set", default = false, items = function (self) return const.SlabMaterialProps end, },
		{ id = "max_voxel_xy", name = "Max Voxel XY", help = "A room wall can only be this long when using this material.", 
			editor = "number", default = 16, min = 1, max = 16, },
		{ id = "use_damaged", name = "Use Damaged Subvariants", help = "When destroyed will only replace ent with damaged subvariant;", 
			editor = "bool", default = false, },
		{ id = "use_damaged_first_floor", name = "Use Damaged Subvariant For First Floor Only", help = "When destroyed will only replace ent with damaged subvariant, if on first floor, else behave as normal;", 
			editor = "bool", default = false, },
	},
	group = "SlabMaterialsBase",
}

DefineClass.SlabVariants = {
	__parents = { "SlabPreset", },
	__generated_by_class = "ClassAsGroupPresetDef",

	group = "SlabVariants",
}

DefineClass.StairsSlabMaterials = {
	__parents = { "SlabMaterialsBase", },
	__generated_by_class = "ClassAsGroupPresetDef",

	Documentation = "Creates a custom material and defines its properties - color, required resources, integrity, etc.",
	group = "StairsSlabMaterials",
}

DefineModItemPreset("StairsSlabMaterials", { EditorName = "Stairs material", EditorSubmenu = "Buildings" })