mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Convert /material to /datum/material
This commit is contained in:
@@ -20,8 +20,8 @@ var/list/table_icon_cache = list()
|
||||
var/can_plate = 1
|
||||
|
||||
var/manipulating = 0
|
||||
var/material/material = null
|
||||
var/material/reinforced = null
|
||||
var/datum/material/material = null
|
||||
var/datum/material/reinforced = null
|
||||
|
||||
// Gambling tables. I'd prefer reinforced with carpet/felt/cloth/whatever, but AFAIK it's either harder or impossible to get /obj/item/stack/material of those.
|
||||
// Convert if/when you can easily get stacks of these.
|
||||
@@ -237,7 +237,7 @@ var/list/table_icon_cache = list()
|
||||
|
||||
// Returns the material to set the table to.
|
||||
/obj/structure/table/proc/common_material_add(obj/item/stack/material/S, mob/user, verb) // Verb is actually verb without 'e' or 'ing', which is added. Works for 'plate'/'plating' and 'reinforce'/'reinforcing'.
|
||||
var/material/M = S.get_material()
|
||||
var/datum/material/M = S.get_material()
|
||||
if(!istype(M))
|
||||
to_chat(user, "<span class='warning'>You cannot [verb]e \the [src] with \the [S].</span>")
|
||||
return null
|
||||
@@ -253,7 +253,7 @@ var/list/table_icon_cache = list()
|
||||
return M
|
||||
|
||||
// Returns the material to set the table to.
|
||||
/obj/structure/table/proc/common_material_remove(mob/user, material/M, delay, what, type_holding, sound)
|
||||
/obj/structure/table/proc/common_material_remove(mob/user, datum/material/M, delay, what, type_holding, sound)
|
||||
if(!M.stack_type)
|
||||
to_chat(user, "<span class='warning'>You are unable to remove the [what] from this [src]!</span>")
|
||||
return M
|
||||
@@ -322,7 +322,7 @@ var/list/table_icon_cache = list()
|
||||
if(full_return || prob(20))
|
||||
new /obj/item/stack/material/steel(src.loc)
|
||||
else
|
||||
var/material/M = get_material_by_name(DEFAULT_WALL_MATERIAL)
|
||||
var/datum/material/M = get_material_by_name(DEFAULT_WALL_MATERIAL)
|
||||
S = M.place_shard(loc)
|
||||
if(S) shards += S
|
||||
qdel(src)
|
||||
|
||||
Reference in New Issue
Block a user