/
mineral.dm
500 lines (434 loc) · 17 KB
/
mineral.dm
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
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
/*
Mineral Sheets
Contains:
- Sandstone
- Sandbags
- Diamond
- Snow
- Uranium
- Plasma
- Gold
- Silver
- Clown
- Titanium
- Plastitanium
Others:
- Adamantine
- Mythril
- Alien Alloy
- Coal
*/
/*
* Sandstone
*/
GLOBAL_LIST_INIT(sandstone_recipes, list ( \
new/datum/stack_recipe("pile of dirt", /obj/machinery/hydroponics/soil, 3, time = 10, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("sandstone door", /obj/structure/mineral_door/sandstone, 10, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Assistant Statue", /obj/structure/statue/sandstone/assistant, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Breakdown into sand", /obj/item/stack/ore/glass, 1, one_per_turf = 0, on_floor = 1) \
))
/obj/item/stack/sheet/mineral/sandstone
name = "sandstone brick"
desc = "This appears to be a combination of both sand and stone."
singular_name = "sandstone brick"
icon_state = "sheet-sandstone"
inhand_icon_state = "sheet-sandstone"
throw_speed = 3
throw_range = 5
custom_materials = list(/datum/material/sandstone=MINERAL_MATERIAL_AMOUNT)
sheettype = "sandstone"
merge_type = /obj/item/stack/sheet/mineral/sandstone
walltype = /turf/closed/wall/mineral/sandstone
material_type = /datum/material/sandstone
/obj/item/stack/sheet/mineral/sandstone/get_main_recipes()
. = ..()
. += GLOB.sandstone_recipes
/obj/item/stack/sheet/mineral/sandstone/thirty
amount = 30
/*
* Sandbags
*/
/obj/item/stack/sheet/mineral/sandbags
name = "sandbags"
icon_state = "sandbags"
singular_name = "sandbag"
layer = LOW_ITEM_LAYER
novariants = TRUE
merge_type = /obj/item/stack/sheet/mineral/sandbags
GLOBAL_LIST_INIT(sandbag_recipes, list ( \
new/datum/stack_recipe("sandbags", /obj/structure/barricade/sandbags, 1, time = 25, one_per_turf = 1, on_floor = 1), \
))
/obj/item/stack/sheet/mineral/sandbags/get_main_recipes()
. = ..()
. += GLOB.sandbag_recipes
/obj/item/emptysandbag
name = "empty sandbag"
desc = "A bag to be filled with sand."
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "sandbag"
w_class = WEIGHT_CLASS_TINY
/obj/item/emptysandbag/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/stack/ore/glass))
var/obj/item/stack/ore/glass/G = W
to_chat(user, "<span class='notice'>You fill the sandbag.</span>")
var/obj/item/stack/sheet/mineral/sandbags/I = new /obj/item/stack/sheet/mineral/sandbags(drop_location())
qdel(src)
if (Adjacent(user) && !issilicon(user))
user.put_in_hands(I)
G.use(1)
else
return ..()
/*
* Diamond
*/
/obj/item/stack/sheet/mineral/diamond
name = "diamond"
icon_state = "sheet-diamond"
inhand_icon_state = "sheet-diamond"
singular_name = "diamond"
sheettype = "diamond"
custom_materials = list(/datum/material/diamond=MINERAL_MATERIAL_AMOUNT)
novariants = TRUE
grind_results = list(/datum/reagent/carbon = 20)
point_value = 25
merge_type = /obj/item/stack/sheet/mineral/diamond
material_type = /datum/material/diamond
walltype = /turf/closed/wall/mineral/diamond
GLOBAL_LIST_INIT(diamond_recipes, list ( \
new/datum/stack_recipe("diamond door", /obj/structure/mineral_door/transparent/diamond, 10, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("diamond tile", /obj/item/stack/tile/mineral/diamond, 1, 4, 20), \
new/datum/stack_recipe("Captain Statue", /obj/structure/statue/diamond/captain, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("AI Hologram Statue", /obj/structure/statue/diamond/ai1, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("AI Core Statue", /obj/structure/statue/diamond/ai2, 5, one_per_turf = 1, on_floor = 1), \
))
/obj/item/stack/sheet/mineral/diamond/get_main_recipes()
. = ..()
. += GLOB.diamond_recipes
/*
* Uranium
*/
/obj/item/stack/sheet/mineral/uranium
name = "uranium"
icon_state = "sheet-uranium"
inhand_icon_state = "sheet-uranium"
singular_name = "uranium sheet"
sheettype = "uranium"
custom_materials = list(/datum/material/uranium=MINERAL_MATERIAL_AMOUNT)
novariants = TRUE
grind_results = list(/datum/reagent/uranium = 20)
point_value = 20
merge_type = /obj/item/stack/sheet/mineral/uranium
material_type = /datum/material/uranium
walltype = /turf/closed/wall/mineral/uranium
GLOBAL_LIST_INIT(uranium_recipes, list ( \
new/datum/stack_recipe("uranium door", /obj/structure/mineral_door/uranium, 10, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("uranium tile", /obj/item/stack/tile/mineral/uranium, 1, 4, 20), \
new/datum/stack_recipe("Nuke Statue", /obj/structure/statue/uranium/nuke, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Engineer Statue", /obj/structure/statue/uranium/eng, 5, one_per_turf = 1, on_floor = 1), \
))
/obj/item/stack/sheet/mineral/uranium/get_main_recipes()
. = ..()
. += GLOB.uranium_recipes
/*
* Plasma
*/
/obj/item/stack/sheet/mineral/plasma
name = "solid plasma"
icon_state = "sheet-plasma"
inhand_icon_state = "sheet-plasma"
singular_name = "plasma sheet"
sheettype = "plasma"
resistance_flags = FLAMMABLE
max_integrity = 100
custom_materials = list(/datum/material/plasma=MINERAL_MATERIAL_AMOUNT)
grind_results = list(/datum/reagent/toxin/plasma = 20)
point_value = 20
merge_type = /obj/item/stack/sheet/mineral/plasma
material_type = /datum/material/plasma
walltype = /turf/closed/wall/mineral/plasma
/obj/item/stack/sheet/mineral/plasma/suicide_act(mob/living/carbon/user)
user.visible_message("<span class='suicide'>[user] begins licking \the [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
return TOXLOSS//dont you kids know that stuff is toxic?
GLOBAL_LIST_INIT(plasma_recipes, list ( \
new/datum/stack_recipe("plasma door", /obj/structure/mineral_door/transparent/plasma, 10, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("plasma tile", /obj/item/stack/tile/mineral/plasma, 1, 4, 20), \
new/datum/stack_recipe("Scientist Statue", /obj/structure/statue/plasma/scientist, 5, one_per_turf = 1, on_floor = 1), \
))
/obj/item/stack/sheet/mineral/plasma/get_main_recipes()
. = ..()
. += GLOB.plasma_recipes
/obj/item/stack/sheet/mineral/plasma/attackby(obj/item/W as obj, mob/user as mob, params)
if(W.get_temperature() > 300)//If the temperature of the object is over 300, then ignite
var/turf/T = get_turf(src)
message_admins("Plasma sheets ignited by [ADMIN_LOOKUPFLW(user)] in [ADMIN_VERBOSEJMP(T)]")
log_game("Plasma sheets ignited by [key_name(user)] in [AREACOORD(T)]")
fire_act(W.get_temperature())
else
return ..()
/obj/item/stack/sheet/mineral/plasma/fire_act(exposed_temperature, exposed_volume)
atmos_spawn_air("plasma=[amount*10];TEMP=[exposed_temperature]")
qdel(src)
/*
* Gold
*/
/obj/item/stack/sheet/mineral/gold
name = "gold"
icon_state = "sheet-gold"
inhand_icon_state = "sheet-gold"
singular_name = "gold bar"
sheettype = "gold"
custom_materials = list(/datum/material/gold=MINERAL_MATERIAL_AMOUNT)
grind_results = list(/datum/reagent/gold = 20)
point_value = 20
merge_type = /obj/item/stack/sheet/mineral/gold
material_type = /datum/material/gold
walltype = /turf/closed/wall/mineral/gold
GLOBAL_LIST_INIT(gold_recipes, list ( \
new/datum/stack_recipe("golden door", /obj/structure/mineral_door/gold, 10, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("gold tile", /obj/item/stack/tile/mineral/gold, 1, 4, 20), \
new/datum/stack_recipe("blank plaque", /obj/item/plaque, 1), \
new/datum/stack_recipe("HoS Statue", /obj/structure/statue/gold/hos, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("HoP Statue", /obj/structure/statue/gold/hop, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("CE Statue", /obj/structure/statue/gold/ce, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("RD Statue", /obj/structure/statue/gold/rd, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Simple Crown", /obj/item/clothing/head/crown, 5), \
new/datum/stack_recipe("CMO Statue", /obj/structure/statue/gold/cmo, 5, one_per_turf = 1, on_floor = 1), \
))
/obj/item/stack/sheet/mineral/gold/get_main_recipes()
. = ..()
. += GLOB.gold_recipes
/*
* Silver
*/
/obj/item/stack/sheet/mineral/silver
name = "silver"
icon_state = "sheet-silver"
inhand_icon_state = "sheet-silver"
singular_name = "silver bar"
sheettype = "silver"
custom_materials = list(/datum/material/silver=MINERAL_MATERIAL_AMOUNT)
grind_results = list(/datum/reagent/silver = 20)
point_value = 20
merge_type = /obj/item/stack/sheet/mineral/silver
material_type = /datum/material/silver
tableVariant = /obj/structure/table/optable
walltype = /turf/closed/wall/mineral/silver
GLOBAL_LIST_INIT(silver_recipes, list ( \
new/datum/stack_recipe("silver door", /obj/structure/mineral_door/silver, 10, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("silver tile", /obj/item/stack/tile/mineral/silver, 1, 4, 20), \
new/datum/stack_recipe("Med Officer Statue", /obj/structure/statue/silver/md, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Janitor Statue", /obj/structure/statue/silver/janitor, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Sec Officer Statue", /obj/structure/statue/silver/sec, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Sec Borg Statue", /obj/structure/statue/silver/secborg, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Med Borg Statue", /obj/structure/statue/silver/medborg, 5, one_per_turf = 1, on_floor = 1), \
))
/obj/item/stack/sheet/mineral/silver/get_main_recipes()
. = ..()
. += GLOB.silver_recipes
/*
* Clown
*/
/obj/item/stack/sheet/mineral/bananium
name = "bananium"
icon_state = "sheet-bananium"
inhand_icon_state = "sheet-bananium"
singular_name = "bananium sheet"
sheettype = "bananium"
custom_materials = list(/datum/material/bananium=MINERAL_MATERIAL_AMOUNT)
novariants = TRUE
grind_results = list(/datum/reagent/consumable/banana = 20)
point_value = 50
merge_type = /obj/item/stack/sheet/mineral/bananium
material_type = /datum/material/bananium
walltype = /turf/closed/wall/mineral/bananium
GLOBAL_LIST_INIT(bananium_recipes, list ( \
new/datum/stack_recipe("bananium tile", /obj/item/stack/tile/mineral/bananium, 1, 4, 20), \
new/datum/stack_recipe("Clown Statue", /obj/structure/statue/bananium/clown, 5, one_per_turf = 1, on_floor = 1), \
))
/obj/item/stack/sheet/mineral/bananium/get_main_recipes()
. = ..()
. += GLOB.bananium_recipes
/*
* Titanium
*/
/obj/item/stack/sheet/mineral/titanium
name = "titanium"
icon_state = "sheet-titanium"
inhand_icon_state = "sheet-titanium"
singular_name = "titanium sheet"
force = 5
throwforce = 5
w_class = WEIGHT_CLASS_NORMAL
throw_speed = 1
throw_range = 3
sheettype = "titanium"
custom_materials = list(/datum/material/titanium=MINERAL_MATERIAL_AMOUNT)
point_value = 20
merge_type = /obj/item/stack/sheet/mineral/titanium
material_type = /datum/material/titanium
walltype = /turf/closed/wall/mineral/titanium
GLOBAL_LIST_INIT(titanium_recipes, list ( \
new/datum/stack_recipe("titanium tile", /obj/item/stack/tile/mineral/titanium, 1, 4, 20), \
new/datum/stack_recipe("shuttle seat", /obj/structure/chair/comfy/shuttle, 2, one_per_turf = TRUE, on_floor = TRUE), \
))
/obj/item/stack/sheet/mineral/titanium/get_main_recipes()
. = ..()
. += GLOB.titanium_recipes
/obj/item/stack/sheet/mineral/titanium/fifty
amount = 50
/*
* Plastitanium
*/
/obj/item/stack/sheet/mineral/plastitanium
name = "plastitanium"
icon_state = "sheet-plastitanium"
inhand_icon_state = "sheet-plastitanium"
singular_name = "plastitanium sheet"
force = 5
throwforce = 5
w_class = WEIGHT_CLASS_NORMAL
throw_speed = 1
throw_range = 3
sheettype = "plastitanium"
custom_materials = list(/datum/material/titanium=MINERAL_MATERIAL_AMOUNT, /datum/material/plasma=MINERAL_MATERIAL_AMOUNT)
point_value = 45
merge_type = /obj/item/stack/sheet/mineral/plastitanium
material_flags = MATERIAL_NO_EFFECTS
walltype = /turf/closed/wall/mineral/plastitanium
GLOBAL_LIST_INIT(plastitanium_recipes, list ( \
new/datum/stack_recipe("plastitanium tile", /obj/item/stack/tile/mineral/plastitanium, 1, 4, 20), \
))
/obj/item/stack/sheet/mineral/plastitanium/get_main_recipes()
. = ..()
. += GLOB.plastitanium_recipes
/*
* Snow
*/
/obj/item/stack/sheet/mineral/snow
name = "snow"
icon_state = "sheet-snow"
inhand_icon_state = "sheet-snow"
custom_materials = list(/datum/material/snow = MINERAL_MATERIAL_AMOUNT)
singular_name = "snow block"
force = 1
throwforce = 2
grind_results = list(/datum/reagent/consumable/ice = 20)
merge_type = /obj/item/stack/sheet/mineral/snow
walltype = /turf/closed/wall/mineral/snow
material_type = /datum/material/snow
GLOBAL_LIST_INIT(snow_recipes, list ( \
new/datum/stack_recipe("Snow wall", /turf/closed/wall/mineral/snow, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Snowman", /obj/structure/statue/snow/snowman, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Snowball", /obj/item/toy/snowball, 1), \
new/datum/stack_recipe("Snow tile", /obj/item/stack/tile/mineral/snow, 1, 4, 20), \
))
/obj/item/stack/sheet/mineral/snow/get_main_recipes()
. = ..()
. += GLOB.snow_recipes
/****************************** Others ****************************/
/*
* Adamantine
*/
GLOBAL_LIST_INIT(adamantine_recipes, list(
new /datum/stack_recipe("incomplete servant golem shell", /obj/item/golem_shell/servant, req_amount=1, res_amount=1),
))
/obj/item/stack/sheet/mineral/adamantine
name = "adamantine"
icon_state = "sheet-adamantine"
inhand_icon_state = "sheet-adamantine"
singular_name = "adamantine sheet"
custom_materials = list(/datum/material/adamantine=MINERAL_MATERIAL_AMOUNT)
merge_type = /obj/item/stack/sheet/mineral/adamantine
/obj/item/stack/sheet/mineral/adamantine/get_main_recipes()
. = ..()
. += GLOB.adamantine_recipes
/*
* Runite
*/
/obj/item/stack/sheet/mineral/runite
name = "runite"
desc = "Rare material found in distant lands."
singular_name = "runite bar"
icon_state = "sheet-runite"
inhand_icon_state = "sheet-runite"
custom_materials = list(/datum/material/runite=MINERAL_MATERIAL_AMOUNT)
merge_type = /obj/item/stack/sheet/mineral/runite
material_type = /datum/material/runite
/*
* Mythril
*/
/obj/item/stack/sheet/mineral/mythril
name = "mythril"
icon_state = "sheet-mythril"
inhand_icon_state = "sheet-mythril"
singular_name = "mythril sheet"
novariants = TRUE
custom_materials = list(/datum/material/mythril=MINERAL_MATERIAL_AMOUNT)
merge_type = /obj/item/stack/sheet/mineral/mythril
/*
* Alien Alloy
*/
/obj/item/stack/sheet/mineral/abductor
name = "alien alloy"
icon = 'icons/obj/abductor.dmi'
icon_state = "sheet-abductor"
inhand_icon_state = "sheet-abductor"
singular_name = "alien alloy sheet"
sheettype = "abductor"
merge_type = /obj/item/stack/sheet/mineral/abductor
GLOBAL_LIST_INIT(abductor_recipes, list ( \
new/datum/stack_recipe("alien bed", /obj/structure/bed/abductor, 2, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("alien locker", /obj/structure/closet/abductor, 2, time = 15, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("alien table frame", /obj/structure/table_frame/abductor, 1, time = 15, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("alien airlock assembly", /obj/structure/door_assembly/door_assembly_abductor, 4, time = 20, one_per_turf = 1, on_floor = 1), \
null, \
new/datum/stack_recipe("alien floor tile", /obj/item/stack/tile/mineral/abductor, 1, 4, 20), \
))
/obj/item/stack/sheet/mineral/abductor/get_main_recipes()
. = ..()
. += GLOB.abductor_recipes
/*
* Coal
*/
/obj/item/stack/sheet/mineral/coal
name = "coal"
desc = "Someone's gotten on the naughty list."
icon = 'icons/obj/mining.dmi'
icon_state = "slag"
singular_name = "coal lump"
merge_type = /obj/item/stack/sheet/mineral/coal
grind_results = list(/datum/reagent/carbon = 20)
novariants = TRUE
/obj/item/stack/sheet/mineral/coal/attackby(obj/item/W, mob/user, params)
if(W.get_temperature() > 300)//If the temperature of the object is over 300, then ignite
var/turf/T = get_turf(src)
message_admins("Coal ignited by [ADMIN_LOOKUPFLW(user)] in [ADMIN_VERBOSEJMP(T)]")
log_game("Coal ignited by [key_name(user)] in [AREACOORD(T)]")
fire_act(W.get_temperature())
return TRUE
else
return ..()
/obj/item/stack/sheet/mineral/coal/fire_act(exposed_temperature, exposed_volume)
atmos_spawn_air("co2=[amount*10];TEMP=[exposed_temperature]")
qdel(src)
/obj/item/stack/sheet/mineral/coal/five
amount = 5
/obj/item/stack/sheet/mineral/coal/ten
amount = 10
//Metal Hydrogen
GLOBAL_LIST_INIT(metalhydrogen_recipes, list(
new /datum/stack_recipe("incomplete servant golem shell", /obj/item/golem_shell/servant, req_amount=20, res_amount=1),
))
/obj/item/stack/sheet/mineral/metal_hydrogen
name = "Metal Hydrogen"
icon_state = "sheet-metalhydrogen"
inhand_icon_state = "sheet-metalhydrogen"
singular_name = "Metal Hydrogen sheet"
w_class = WEIGHT_CLASS_NORMAL
resistance_flags = FIRE_PROOF | LAVA_PROOF | ACID_PROOF | INDESTRUCTIBLE
point_value = 100
custom_materials = list(/datum/material/metalhydrogen=MINERAL_MATERIAL_AMOUNT)
merge_type = /obj/item/stack/sheet/mineral/metal_hydrogen
/obj/item/stack/sheet/mineral/metal_hydrogen/get_main_recipes()
. = ..()
. += GLOB.metalhydrogen_recipes