mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2025-12-25 17:42:26 +00:00
Medical Expansion (#6465)
* Starts work on the Medical Expansion. * Further Work * Save Everything! * Large volume of things. * Log of Change * I'm an idiot. * Kidney assisted sprites. They didn't exist, for some reason. * Fixfix * Fixfix * Update encased.dm * Update glass.dm * Update Chemistry-Reagents.dm I am once more an idiot. * Split augs. * Fixfix
This commit is contained in:
@@ -24,6 +24,9 @@
|
||||
var/list/datum/matter_synth/synths = null
|
||||
var/no_variants = TRUE // Determines whether the item should update it's sprites based on amount.
|
||||
|
||||
var/pass_color = FALSE // Will the item pass its own color var to the created item? Dyed cloth, wood, etc.
|
||||
var/strict_color_stacking = FALSE // Will the stack merge with other stacks that are different colors? (Dyed cloth, wood, etc)
|
||||
|
||||
/obj/item/stack/New(var/loc, var/amount=null)
|
||||
..()
|
||||
if (!stacktype)
|
||||
@@ -159,6 +162,17 @@
|
||||
for (var/obj/item/I in O)
|
||||
qdel(I)
|
||||
|
||||
if ((pass_color || recipe.pass_color))
|
||||
if(!color)
|
||||
if(recipe.use_material)
|
||||
var/material/MAT = get_material_by_name(recipe.use_material)
|
||||
if(MAT.icon_colour)
|
||||
O.color = MAT.icon_colour
|
||||
else
|
||||
return
|
||||
else
|
||||
O.color = color
|
||||
|
||||
/obj/item/stack/Topic(href, href_list)
|
||||
..()
|
||||
if ((usr.restrained() || usr.stat || usr.get_active_hand() != src))
|
||||
@@ -242,6 +256,9 @@
|
||||
return 0
|
||||
if ((stacktype != S.stacktype) && !type_verified)
|
||||
return 0
|
||||
if ((strict_color_stacking || S.strict_color_stacking) && S.color != color)
|
||||
return 0
|
||||
|
||||
if (isnull(tamount))
|
||||
tamount = src.get_amount()
|
||||
|
||||
@@ -355,8 +372,9 @@
|
||||
var/one_per_turf = 0
|
||||
var/on_floor = 0
|
||||
var/use_material
|
||||
var/pass_color
|
||||
|
||||
New(title, result_type, req_amount = 1, res_amount = 1, max_res_amount = 1, time = 0, one_per_turf = 0, on_floor = 0, supplied_material = null)
|
||||
New(title, result_type, req_amount = 1, res_amount = 1, max_res_amount = 1, time = 0, one_per_turf = 0, on_floor = 0, supplied_material = null, pass_stack_color)
|
||||
src.title = title
|
||||
src.result_type = result_type
|
||||
src.req_amount = req_amount
|
||||
@@ -366,6 +384,7 @@
|
||||
src.one_per_turf = one_per_turf
|
||||
src.on_floor = on_floor
|
||||
src.use_material = supplied_material
|
||||
src.pass_color = pass_stack_color
|
||||
|
||||
/*
|
||||
* Recipe list datum
|
||||
|
||||
Reference in New Issue
Block a user