mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Adds two new particle smasher recipies
This commit is contained in:
@@ -760,3 +760,17 @@
|
|||||||
. = ..()
|
. = ..()
|
||||||
reagents.add_reagent("protein", 3)
|
reagents.add_reagent("protein", 3)
|
||||||
bitesize = 2
|
bitesize = 2
|
||||||
|
|
||||||
|
/obj/item/weapon/reagent_containers/food/snacks/donkpocket/ascended
|
||||||
|
name = "Donk-pocket EX"
|
||||||
|
desc = "This donk-pocket has seen things beyond comprehension of mortals. It survived because the fire inside it burned brighter than fire around it."
|
||||||
|
icon = 'icons/obj/food_vr.dmi'
|
||||||
|
icon_state = "donkpocket_ascended"
|
||||||
|
nutriment_amt = 5
|
||||||
|
nutriment_desc = list("burning fires of radioactive hell" = 20)
|
||||||
|
heated_reagents = list("supermatter" = 1)
|
||||||
|
|
||||||
|
/obj/item/weapon/reagent_containers/food/snacks/donkpocket/ascended/Initialize()
|
||||||
|
. = ..()
|
||||||
|
reagents.add_reagent("uranium", 3)
|
||||||
|
reagents.add_reagent("pyrotoxin", 3)
|
||||||
@@ -2,6 +2,9 @@
|
|||||||
* Contains the particle smasher and its recipes.
|
* Contains the particle smasher and its recipes.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define PS_RESULT_STACK "stack"
|
||||||
|
#define PS_RESULT_ITEM "item"
|
||||||
|
|
||||||
/obj/machinery/particle_smasher
|
/obj/machinery/particle_smasher
|
||||||
name = "Particle Focus"
|
name = "Particle Focus"
|
||||||
desc = "A strange device used to create exotic matter."
|
desc = "A strange device used to create exotic matter."
|
||||||
@@ -190,7 +193,7 @@
|
|||||||
var/max_prob = 0
|
var/max_prob = 0
|
||||||
for(var/datum/particle_smasher_recipe/R in recipes) // Only things for the smasher. Don't get things like the chef's cake recipes.
|
for(var/datum/particle_smasher_recipe/R in recipes) // Only things for the smasher. Don't get things like the chef's cake recipes.
|
||||||
if(R.probability) // It's actually a recipe you're supposed to be able to make.
|
if(R.probability) // It's actually a recipe you're supposed to be able to make.
|
||||||
if(istype(target, R.required_material))
|
if(!(R.required_material) || istype(target, R.required_material))
|
||||||
if(energy >= R.required_energy_min && energy <= R.required_energy_max) // The machine has enough Vaguely Defined 'Energy'.
|
if(energy >= R.required_energy_min && energy <= R.required_energy_max) // The machine has enough Vaguely Defined 'Energy'.
|
||||||
var/turf/T = get_turf(src)
|
var/turf/T = get_turf(src)
|
||||||
var/datum/gas_mixture/environment = T.return_air()
|
var/datum/gas_mixture/environment = T.return_air()
|
||||||
@@ -234,8 +237,11 @@
|
|||||||
break
|
break
|
||||||
|
|
||||||
var/result = recipe.result
|
var/result = recipe.result
|
||||||
var/obj/item/stack/material/M = new result(src)
|
if(recipe.recipe_type == PS_RESULT_STACK)
|
||||||
target = M
|
var/obj/item/stack/material/M = new result(src)
|
||||||
|
target = M
|
||||||
|
else if(recipe.recipe_type == PS_RESULT_ITEM)
|
||||||
|
new result(get_turf(src))
|
||||||
update_icon()
|
update_icon()
|
||||||
|
|
||||||
/obj/machinery/particle_smasher/verb/eject_contents()
|
/obj/machinery/particle_smasher/verb/eject_contents()
|
||||||
@@ -266,6 +272,7 @@
|
|||||||
/datum/particle_smasher_recipe
|
/datum/particle_smasher_recipe
|
||||||
var/list/reagents // example: = list("pacid" = 5)
|
var/list/reagents // example: = list("pacid" = 5)
|
||||||
var/list/items // example: = list(/obj/item/weapon/tool/crowbar, /obj/item/weapon/welder) Place /foo/bar before /foo. Do not include fruit. Maximum of 3 items.
|
var/list/items // example: = list(/obj/item/weapon/tool/crowbar, /obj/item/weapon/welder) Place /foo/bar before /foo. Do not include fruit. Maximum of 3 items.
|
||||||
|
var/recipe_type = PS_RESULT_STACK // Are we producing a stack or an item?
|
||||||
|
|
||||||
var/result = /obj/item/stack/material/iron // The sheet this will produce.
|
var/result = /obj/item/stack/material/iron // The sheet this will produce.
|
||||||
var/required_material = /obj/item/stack/material/iron // The required material sheet.
|
var/required_material = /obj/item/stack/material/iron // The required material sheet.
|
||||||
@@ -378,4 +385,35 @@
|
|||||||
|
|
||||||
required_atmos_temp_min = 3000
|
required_atmos_temp_min = 3000
|
||||||
required_atmos_temp_max = 10000
|
required_atmos_temp_max = 10000
|
||||||
probability = 1
|
probability = 1
|
||||||
|
|
||||||
|
/datum/particle_smasher_recipe/donkpockets_coal
|
||||||
|
items = list(/obj/item/weapon/reagent_containers/food/snacks/donkpocket)
|
||||||
|
|
||||||
|
recipe_type = PS_RESULT_ITEM
|
||||||
|
|
||||||
|
result = /obj/item/weapon/ore/coal
|
||||||
|
required_material = null
|
||||||
|
|
||||||
|
required_energy_min = 1
|
||||||
|
required_energy_max = 500
|
||||||
|
|
||||||
|
required_atmos_temp_min = 400
|
||||||
|
required_atmos_temp_max = 20000
|
||||||
|
probability = 90
|
||||||
|
|
||||||
|
/datum/particle_smasher_recipe/donkpockets_ascend
|
||||||
|
items = list(/obj/item/weapon/reagent_containers/food/snacks/donkpocket)
|
||||||
|
reagents = list("phoron" = 120)
|
||||||
|
|
||||||
|
recipe_type = PS_RESULT_ITEM
|
||||||
|
|
||||||
|
result = /obj/item/weapon/reagent_containers/food/snacks/donkpocket/ascended
|
||||||
|
required_material = /obj/item/stack/material/uranium
|
||||||
|
|
||||||
|
required_energy_min = 501
|
||||||
|
required_energy_max = 700
|
||||||
|
|
||||||
|
required_atmos_temp_min = 400
|
||||||
|
required_atmos_temp_max = 20000
|
||||||
|
probability = 20
|
||||||
Reference in New Issue
Block a user