diff --git a/code/datums/components/fantasy/_fantasy.dm b/code/datums/components/fantasy/_fantasy.dm index 1122b7b3960..457313471e6 100644 --- a/code/datums/components/fantasy/_fantasy.dm +++ b/code/datums/components/fantasy/_fantasy.dm @@ -91,7 +91,7 @@ master.force = max(0, master.force + quality) master.throwforce = max(0, master.throwforce + quality) - master.armor = master.armor.modifyAllRatings(quality) + master.armor = master.armor?.modifyAllRatings(quality) var/newName = originalName for(var/i in affixes) @@ -122,7 +122,7 @@ master.force = max(0, master.force - quality) master.throwforce = max(0, master.throwforce - quality) - master.armor = master.armor.modifyAllRatings(-quality) + master.armor = master.armor?.modifyAllRatings(-quality) master.name = originalName diff --git a/code/datums/materials/_material.dm b/code/datums/materials/_material.dm index dcfaf4ad68b..e1e8c29871d 100644 --- a/code/datums/materials/_material.dm +++ b/code/datums/materials/_material.dm @@ -18,12 +18,12 @@ Simple datum which is instanced once per type and is used for every object of sa var/list/categories = list() ///The type of sheet this material creates. This should be replaced as soon as possible by greyscale sheets. var/sheet_type - ///The type of coin this material spawns. This should be replaced as soon as possible by greyscale coins. - var/coin_type ///This is a modifier for force, and resembles the strength of the material var/strength_modifier = 1 ///This is a modifier for integrity, and resembles the strength of the material var/integrity_modifier = 1 + ///This is the amount of value per 1 unit of the material + var/value_per_unit = 0 ///Armor modifiers, multiplies an items normal armor vars by these amounts. var/armor_modifiers = list("melee" = 1, "bullet" = 1, "laser" = 1, "energy" = 1, "bomb" = 1, "bio" = 1, "rad" = 1, "fire" = 1, "acid" = 1) diff --git a/code/datums/materials/basemats.dm b/code/datums/materials/basemats.dm index 26882b1bb2f..55d3760cf5e 100644 --- a/code/datums/materials/basemats.dm +++ b/code/datums/materials/basemats.dm @@ -6,7 +6,7 @@ color = "#878687" categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/metal - coin_type = /obj/item/coin/iron + value_per_unit = 0.0025 ///Breaks extremely easily but is transparent. /datum/material/glass @@ -18,6 +18,7 @@ categories = list(MAT_CATEGORY_RIGID = TRUE) integrity_modifier = 0.1 sheet_type = /obj/item/stack/sheet/glass + value_per_unit = 0.0025 armor_modifiers = list("melee" = 0.2, "bullet" = 0.2, "laser" = 0, "energy" = 1, "bomb" = 0, "bio" = 0.2, "rad" = 0.2, "fire" = 1, "acid" = 0.2) // yeah ok retard ///Has no special properties. Could be good against vampires in the future perhaps. @@ -28,7 +29,7 @@ color = "#bdbebf" categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/silver - coin_type = /obj/item/coin/silver + value_per_unit = 0.025 ///Slight force increase /datum/material/gold @@ -39,7 +40,7 @@ strength_modifier = 1.2 categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/gold - coin_type = /obj/item/coin/gold + value_per_unit = 0.0625 armor_modifiers = list("melee" = 1.1, "bullet" = 1.1, "laser" = 1.15, "energy" = 1.15, "bomb" = 1, "bio" = 1, "rad" = 1, "fire" = 0.7, "acid" = 1.1) ///Has no special properties @@ -50,7 +51,7 @@ color = "#22c2d4" categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/diamond - coin_type = /obj/item/coin/diamond + value_per_unit = 0.25 armor_modifiers = list("melee" = 1.3, "bullet" = 1.3, "laser" = 0.6, "energy" = 1, "bomb" = 1.2, "bio" = 1, "rad" = 1, "fire" = 1, "acid" = 1) ///Is slightly radioactive @@ -61,7 +62,7 @@ color = "#1fb83b" categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/uranium - coin_type = /obj/item/coin/uranium + value_per_unit = 0.05 armor_modifiers = list("melee" = 1.5, "bullet" = 1.4, "laser" = 0.5, "energy" = 0.5, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 1, "acid" = 1) /datum/material/uranium/on_applied(atom/source, amount, material_flags) @@ -81,7 +82,7 @@ color = "#eb80f2" categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/plasma - coin_type = /obj/item/coin/plasma + value_per_unit = 0.1 armor_modifiers = list("melee" = 1.4, "bullet" = 0.7, "laser" = 0, "energy" = 1.2, "bomb" = 0, "bio" = 1.2, "rad" = 1, "fire" = 0, "acid" = 0.5) /datum/material/plasma/on_applied(atom/source, amount, material_flags) @@ -103,6 +104,7 @@ color = "#506bc7" categories = list(MAT_CATEGORY_ORE = TRUE) sheet_type = /obj/item/stack/sheet/bluespace_crystal + value_per_unit = 0.15 ///Honks and slips /datum/material/bananium @@ -112,7 +114,7 @@ color = "#fff263" categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/bananium - coin_type = /obj/item/coin/bananium + value_per_unit = 0.5 armor_modifiers = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 100, "bio" = 0, "rad" = 0, "fire" = 10, "acid" = 0) //Clowns cant be blown away. /datum/material/bananium/on_applied(atom/source, amount, material_flags) @@ -136,6 +138,7 @@ strength_modifier = 1.3 categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/titanium + value_per_unit = 0.0625 armor_modifiers = list("melee" = 1.35, "bullet" = 1.3, "laser" = 1.3, "energy" = 1.25, "bomb" = 1.25, "bio" = 1, "rad" = 1, "fire" = 0.7, "acid" = 1) /datum/material/runite @@ -146,16 +149,19 @@ strength_modifier = 1.3 categories = list(MAT_CATEGORY_RIGID = TRUE) sheet_type = /obj/item/stack/sheet/mineral/runite + value_per_unit = 0.3 armor_modifiers = list("melee" = 1.35, "bullet" = 2, "laser" = 0.5, "energy" = 1.25, "bomb" = 1.25, "bio" = 1, "rad" = 1, "fire" = 1.4, "acid" = 1) //rune is weak against magic lasers but strong against bullets. This is the combat triangle. ///Force decrease /datum/material/plastic name = "plastic" id = "plastic" - desc = "plastic" + desc = "Plastic" color = "#caccd9" strength_modifier = 0.85 sheet_type = /obj/item/stack/sheet/plastic + value_per_unit = 0.0125 + armor_modifiers = list("melee" = 1.5, "bullet" = 1.1, "laser" = 0.3, "energy" = 0.5, "bomb" = 1, "bio" = 1, "rad" = 1, "fire" = 1.1, "acid" = 1) ///Force decrease and mushy sound effect. (Not yet implemented) /datum/material/biomass @@ -164,3 +170,37 @@ desc = "Organic matter" color = "#735b4d" strength_modifier = 0.8 + value_per_unit = 0.025 + +///Stronk force increase +/datum/material/adamantine + name = "adamantine" + id = "adamantine" + desc = "A powerful material made out of magic, I mean science!" + color = "#6d7e8e" + strength_modifier = 1.5 + categories = list(MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/adamantine + value_per_unit = 0.25 + armor_modifiers = list("melee" = 1.5, "bullet" = 1.5, "laser" = 1.3, "energy" = 1.3, "bomb" = 1, "bio" = 1, "rad" = 1, "fire" = 2.5, "acid" = 1) + +///RPG Magic. (Admin only) +/datum/material/mythril + name = "mythril" + id = "mythril" + desc = "How this even exists is byond me" + color = "#ffedee" + categories = list(MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/mythril + value_per_unit = 0.75 + armor_modifiers = list("melee" = 2, "bullet" = 2, "laser" = 2, "energy" = 2, "bomb" = 2, "bio" = 2, "rad" = 2, "fire" = 2, "acid" = 2) + +/datum/material/mythril/on_applied_obj(atom/source, amount, material_flags) + . = ..() + if(istype(source, /obj/item)) + source.AddComponent(/datum/component/fantasy) + +/datum/material/mythril/on_removed_obj(atom/source, material_flags) + . = ..() + if(istype(source, /obj/item)) + qdel(source.GetComponent(/datum/component/fantasy)) diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 33fd61adfcc..46297241d97 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -155,8 +155,7 @@ if(custom_materials && custom_materials.len) var/temp_list = list() for(var/i in custom_materials) - var/datum/material/material = getmaterialref(i) || i - temp_list[material] = custom_materials[material] //Get the proper instanced version + temp_list[getmaterialref(i)] = custom_materials[i] //Get the proper instanced version custom_materials = null //Null the list to prepare for applying the materials properly set_custom_materials(temp_list) diff --git a/code/game/machinery/autolathe.dm b/code/game/machinery/autolathe.dm index 29f6a6786a0..04dd796eda4 100644 --- a/code/game/machinery/autolathe.dm +++ b/code/game/machinery/autolathe.dm @@ -1,6 +1,6 @@ -#define AUTOLATHE_MAIN_MENU 1 -#define AUTOLATHE_CATEGORY_MENU 2 -#define AUTOLATHE_SEARCH_MENU 3 +#define AUTOLATHE_MAIN_MENU 1 +#define AUTOLATHE_CATEGORY_MENU 2 +#define AUTOLATHE_SEARCH_MENU 3 /obj/machinery/autolathe name = "autolathe" @@ -59,8 +59,11 @@ /datum/material/bluespace, /datum/material/bananium, /datum/material/titanium, - /datum/material/runite), - 0, TRUE, null, null, CALLBACK(src, .proc/AfterMaterialInsert)) + /datum/material/runite, + /datum/material/plastic, + /datum/material/adamantine, + /datum/material/mythril + ), 0, TRUE, null, null, CALLBACK(src, .proc/AfterMaterialInsert)) . = ..() wires = new /datum/wires/autolathe(src) diff --git a/code/game/machinery/slotmachine.dm b/code/game/machinery/slotmachine.dm index f0af836bfba..3d8a67c69df 100644 --- a/code/game/machinery/slotmachine.dm +++ b/code/game/machinery/slotmachine.dm @@ -93,7 +93,7 @@ else if(!user.temporarilyRemoveItemFromInventory(C)) return - to_chat(user, "You insert a [C.cmineral] coin into [src]'s slot!") + to_chat(user, "You insert [C] into [src]'s slot!") balance += C.value qdel(C) else diff --git a/code/game/objects/items/stacks/sheets/mineral.dm b/code/game/objects/items/stacks/sheets/mineral.dm index f6fe9f1c119..3abefe3cce2 100644 --- a/code/game/objects/items/stacks/sheets/mineral.dm +++ b/code/game/objects/items/stacks/sheets/mineral.dm @@ -365,6 +365,7 @@ GLOBAL_LIST_INIT(adamantine_recipes, list( icon_state = "sheet-adamantine" item_state = "sheet-adamantine" singular_name = "adamantine sheet" + materials = list(/datum/material/adamantine=MINERAL_MATERIAL_AMOUNT) merge_type = /obj/item/stack/sheet/mineral/adamantine /obj/item/stack/sheet/mineral/adamantine/Initialize(mapload, new_amount, merge = TRUE) @@ -394,6 +395,7 @@ GLOBAL_LIST_INIT(adamantine_recipes, list( item_state = "sheet-mythril" singular_name = "mythril sheet" novariants = TRUE + materials = list(/datum/material/mythril=MINERAL_MATERIAL_AMOUNT) merge_type = /obj/item/stack/sheet/mineral/mythril /* diff --git a/code/game/objects/items/stacks/sheets/sheet_types.dm b/code/game/objects/items/stacks/sheets/sheet_types.dm index 322f0d08918..720dca9d757 100644 --- a/code/game/objects/items/stacks/sheets/sheet_types.dm +++ b/code/game/objects/items/stacks/sheets/sheet_types.dm @@ -257,7 +257,6 @@ GLOBAL_LIST_INIT(bamboo_recipes, list ( \ icon_state = "sheet-bamboo" item_state = "sheet-bamboo" icon = 'icons/obj/stack_objects.dmi' - sheettype = "bamboo" throwforce = 15 armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 0) resistance_flags = FLAMMABLE diff --git a/code/modules/cargo/exports/materials.dm b/code/modules/cargo/exports/materials.dm index 4f478d3c6e8..8982ed1fd68 100644 --- a/code/modules/cargo/exports/materials.dm +++ b/code/modules/cargo/exports/materials.dm @@ -32,47 +32,67 @@ /datum/export/material/bananium cost = 1000 material_id = /datum/material/bananium - message = "cm3 of bananium" + message = "cm3 of bananium" /datum/export/material/diamond cost = 500 material_id = /datum/material/diamond - message = "cm3 of diamonds" + message = "cm3 of diamonds" /datum/export/material/plasma cost = 200 k_elasticity = 0 material_id = /datum/material/plasma - message = "cm3 of plasma" + message = "cm3 of plasma" /datum/export/material/uranium cost = 100 material_id = /datum/material/uranium - message = "cm3 of uranium" + message = "cm3 of uranium" /datum/export/material/gold cost = 125 material_id = /datum/material/gold - message = "cm3 of gold" + message = "cm3 of gold" /datum/export/material/silver cost = 50 material_id = /datum/material/silver - message = "cm3 of silver" + message = "cm3 of silver" /datum/export/material/titanium cost = 125 material_id = /datum/material/titanium - message = "cm3 of titanium" + message = "cm3 of titanium" -/datum/export/material/plastitanium - cost = 325 // plasma + titanium costs - material_id = /datum/material/titanium // code can only check for one material_id; plastitanium is half plasma, half titanium - message = "cm3 of plastitanium" +/datum/export/material/adamantine + cost = 500 + material_id = /datum/material/adamantine + message = "cm3 of adamantine" + +/datum/export/material/mythril + cost = 1500 + material_id = /datum/material/mythril + message = "cm3 of mythril" + +/datum/export/material/bscrystal + cost = 300 + message = "of bluespace crystals" + material_id = /datum/material/bluespace + +/datum/export/material/plastic + cost = 25 + message = "cm3 of plastic" + material_id = /datum/material/plastic + +/datum/export/material/runite + cost = 600 + message = "cm3 of runite" + material_id = /datum/material/runite /datum/export/material/metal cost = 5 - message = "cm3 of metal" + message = "cm3 of metal" material_id = /datum/material/iron export_types = list( /obj/item/stack/sheet/metal, /obj/item/stack/tile/plasteel, @@ -80,7 +100,7 @@ /datum/export/material/glass cost = 5 - message = "cm3 of glass" + message = "cm3 of glass" material_id = /datum/material/glass export_types = list(/obj/item/stack/sheet/glass, /obj/item/stack/ore, /obj/item/shard) diff --git a/code/modules/cargo/exports/sheets.dm b/code/modules/cargo/exports/sheets.dm index 708eb34133a..1c666a4db4d 100644 --- a/code/modules/cargo/exports/sheets.dm +++ b/code/modules/cargo/exports/sheets.dm @@ -67,10 +67,10 @@ message = "of reinforced glass" export_types = list(/obj/item/stack/sheet/rglass) -/datum/export/stack/bscrystal - cost = 300 - message = "of bluespace crystals" - export_types = list(/obj/item/stack/sheet/bluespace_crystal) +/datum/export/stack/plastitanium + cost = 325 // plasma + titanium costs + message = "of plastitanium" + export_types = list(/obj/item/stack/sheet/mineral/plastitanium) /datum/export/stack/wood cost = 30 @@ -99,10 +99,3 @@ cost = 1000 message = "of alien alloy" export_types = list(/obj/item/stack/sheet/mineral/abductor) - -/datum/export/stack/adamantine - unit_name = "bar" - cost = 500 - message = "of adamantine" - export_types = list(/obj/item/stack/sheet/mineral/adamantine) - diff --git a/code/modules/mining/mint.dm b/code/modules/mining/mint.dm index a85f07c7cad..330571146fb 100644 --- a/code/modules/mining/mint.dm +++ b/code/modules/mining/mint.dm @@ -15,8 +15,21 @@ /obj/machinery/mineral/mint/Initialize() . = ..() - AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/plasma, /datum/material/silver, /datum/material/gold, /datum/material/uranium, /datum/material/diamond, /datum/material/bananium), MINERAL_MATERIAL_AMOUNT * 50, FALSE, /obj/item/stack) - chosen = getmaterialref(chosen) + AddComponent(/datum/component/material_container, list( + /datum/material/iron, + /datum/material/plasma, + /datum/material/silver, + /datum/material/gold, + /datum/material/uranium, + /datum/material/titanium, + /datum/material/diamond, + /datum/material/bananium, + /datum/material/adamantine, + /datum/material/mythril, + /datum/material/plastic, + /datum/material/runite + ), MINERAL_MATERIAL_AMOUNT * 50, FALSE, /obj/item/stack) + chosen = getmaterialref(chosen) /obj/machinery/mineral/mint/process() @@ -74,18 +87,19 @@ chosen = new_material if(href_list["chooseAmt"]) coinsToProduce = CLAMP(coinsToProduce + text2num(href_list["chooseAmt"]), 0, 1000) + updateUsrDialog() if(href_list["makeCoins"]) var/temp_coins = coinsToProduce processing = TRUE icon_state = "coinpress1" var/coin_mat = MINERAL_MATERIAL_AMOUNT * 0.2 var/datum/material/M = chosen - if(!M || !M.coin_type) + if(!M) updateUsrDialog() return while(coinsToProduce > 0 && materials.use_amount_mat(coin_mat, chosen)) - create_coins(M.coin_type) + create_coins() coinsToProduce-- newCoins++ src.updateUsrDialog() @@ -97,12 +111,15 @@ src.updateUsrDialog() return -/obj/machinery/mineral/mint/proc/create_coins(P) +/obj/machinery/mineral/mint/proc/create_coins() var/turf/T = get_step(src,output_dir) + var/temp_list = list() + temp_list[chosen] = 400 if(T) - var/obj/item/O = new P(src) - var/obj/item/storage/bag/money/M = locate(/obj/item/storage/bag/money, T) - if(!M) - M = new /obj/item/storage/bag/money(src) - unload_mineral(M) - O.forceMove(M) + var/obj/item/O = new /obj/item/coin(src) + var/obj/item/storage/bag/money/B = locate(/obj/item/storage/bag/money, T) + O.set_custom_materials(temp_list) + if(!B) + B = new /obj/item/storage/bag/money(src) + unload_mineral(B) + O.forceMove(B) diff --git a/code/modules/mining/ores_coins.dm b/code/modules/mining/ores_coins.dm index 9592c0150c1..2a689b780c3 100644 --- a/code/modules/mining/ores_coins.dm +++ b/code/modules/mining/ores_coins.dm @@ -304,18 +304,33 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ /obj/item/coin icon = 'icons/obj/economy.dmi' name = "coin" - icon_state = "coin__heads" + icon_state = "coin" flags_1 = CONDUCT_1 force = 1 throwforce = 2 w_class = WEIGHT_CLASS_TINY + custom_materials = list(/datum/material/iron = 400) + material_flags = MATERIAL_ADD_PREFIX var/string_attached var/list/sideslist = list("heads","tails") - var/cmineral = null var/cooldown = 0 - var/value = 1 + var/value var/coinflip +/obj/item/coin/Initialize() + . = ..() + coinflip = pick(sideslist) + icon_state = "coin_[coinflip]" + pixel_x = rand(0,16)-8 + pixel_y = rand(0,8)-8 + +/obj/item/coin/set_custom_materials(var/list/materials, multiplier = 1) + . = ..() + value = 0 + for(var/i in custom_materials) + var/datum/material/M = i + value += M.value_per_unit * custom_materials[M] + /obj/item/coin/get_item_credit_value() return value @@ -338,101 +353,9 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ else user.visible_message("\the [src] lands on [coinflip]! [user] keeps on living!") -/obj/item/coin/Initialize() - . = ..() - pixel_x = rand(0,16)-8 - pixel_y = rand(0,8)-8 - /obj/item/coin/examine(mob/user) . = ..() - if(value) - . += "It's worth [value] credit\s." - -/obj/item/coin/gold - name = "gold coin" - cmineral = "gold" - icon_state = "coin_gold_heads" - value = 25 - materials = list(/datum/material/gold = MINERAL_MATERIAL_AMOUNT*0.2) - grind_results = list(/datum/reagent/gold = 4) - -/obj/item/coin/silver - name = "silver coin" - cmineral = "silver" - icon_state = "coin_silver_heads" - value = 10 - materials = list(/datum/material/silver = MINERAL_MATERIAL_AMOUNT*0.2) - grind_results = list(/datum/reagent/silver = 4) - -/obj/item/coin/diamond - name = "diamond coin" - cmineral = "diamond" - icon_state = "coin_diamond_heads" - value = 100 - materials = list(/datum/material/diamond = MINERAL_MATERIAL_AMOUNT*0.2) - grind_results = list(/datum/reagent/carbon = 4) - -/obj/item/coin/iron - name = "iron coin" - cmineral = "iron" - icon_state = "coin_iron_heads" - value = 1 - materials = list(/datum/material/iron = MINERAL_MATERIAL_AMOUNT*0.2) - grind_results = list(/datum/reagent/iron = 4) - -/obj/item/coin/plasma - name = "plasma coin" - cmineral = "plasma" - icon_state = "coin_plasma_heads" - value = 40 - materials = list(/datum/material/plasma = MINERAL_MATERIAL_AMOUNT*0.2) - grind_results = list(/datum/reagent/toxin/plasma = 4) - -/obj/item/coin/uranium - name = "uranium coin" - cmineral = "uranium" - icon_state = "coin_uranium_heads" - value = 25 - materials = list(/datum/material/uranium = MINERAL_MATERIAL_AMOUNT*0.2) - grind_results = list(/datum/reagent/uranium = 4) - -/obj/item/coin/bananium - name = "bananium coin" - cmineral = "bananium" - icon_state = "coin_bananium_heads" - value = 200 //makes the clown cry - materials = list(/datum/material/bananium = MINERAL_MATERIAL_AMOUNT*0.2) - grind_results = list(/datum/reagent/consumable/banana = 4) - -/obj/item/coin/adamantine - name = "adamantine coin" - cmineral = "adamantine" - icon_state = "coin_adamantine_heads" - value = 100 - -/obj/item/coin/mythril - name = "mythril coin" - cmineral = "mythril" - icon_state = "coin_mythril_heads" - value = 300 - -/obj/item/coin/twoheaded - cmineral = "iron" - icon_state = "coin_iron_heads" - desc = "Hey, this coin's the same on both sides!" - sideslist = list("heads") - materials = list(/datum/material/iron = MINERAL_MATERIAL_AMOUNT*0.2) - value = 1 - grind_results = list(/datum/reagent/iron = 4) - -/obj/item/coin/antagtoken - name = "antag token" - icon_state = "coin_valid_valid" - cmineral = "valid" - desc = "A novelty coin that helps the heart know what hard evidence cannot prove." - sideslist = list("valid", "salad") - value = 0 - grind_results = list(/datum/reagent/consumable/sodiumchloride = 4) + . += "It's worth [value] credit\s." /obj/item/coin/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/stack/cable_coil)) @@ -467,10 +390,10 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ if(string_attached) //does the coin have a wire attached to_chat(user, "The coin won't flip very well with something attached!" ) return FALSE//do not flip the coin - coinflip = pick(sideslist) cooldown = world.time + 15 - flick("coin_[cmineral]_flip", src) - icon_state = "coin_[cmineral]_[coinflip]" + flick("coin_[coinflip]_flip", src) + coinflip = pick(sideslist) + icon_state = "coin_[coinflip]" playsound(user.loc, 'sound/items/coinflip.ogg', 50, TRUE) var/oldloc = loc sleep(15) @@ -480,5 +403,50 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ "You hear the clattering of loose change.") return TRUE//did the coin flip? useful for suicide_act +/obj/item/coin/gold + custom_materials = list(/datum/material/gold = 400) + +/obj/item/coin/silver + custom_materials = list(/datum/material/silver = 400) + +/obj/item/coin/diamond + custom_materials = list(/datum/material/diamond = 400) + +/obj/item/coin/plasma + custom_materials = list(/datum/material/plasma = 400) + +/obj/item/coin/uranium + custom_materials = list(/datum/material/uranium = 400) + +/obj/item/coin/titanium + custom_materials = list(/datum/material/titanium = 400) + +/obj/item/coin/bananium + custom_materials = list(/datum/material/bananium = 400) + +/obj/item/coin/adamantine + custom_materials = list(/datum/material/adamantine = 400) + +/obj/item/coin/mythril + custom_materials = list(/datum/material/mythril = 400) + +/obj/item/coin/plastic + custom_materials = list(/datum/material/plastic = 400) + +/obj/item/coin/runite + custom_materials = list(/datum/material/runite = 400) + +/obj/item/coin/twoheaded + desc = "Hey, this coin's the same on both sides!" + sideslist = list("heads") + +/obj/item/coin/antagtoken + name = "antag token" + desc = "A novelty coin that helps the heart know what hard evidence cannot prove." + custom_materials = list(/datum/material/plastic = 400) + sideslist = list("valid", "salad") + material_flags = MATERIAL_NO_COLOR + +/obj/item/coin/iron #undef ORESTACK_OVERLAYS_MAX diff --git a/icons/obj/economy.dmi b/icons/obj/economy.dmi index cb050e27ab0..caaa9436182 100644 Binary files a/icons/obj/economy.dmi and b/icons/obj/economy.dmi differ