mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-29 06:58:30 +01:00
Fixes
- Material comparisons done by name rather than reference equality - get_material_by_name proc that ensures the material list is initialised, initialising it if neccessary - holographic materials moved into main material list - table frames are not a source of infinite metal, and can be deconstructed correctly - gambling table icons are no longer E-W flipped
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
var/list/name_to_material
|
||||
|
||||
/proc/populate_material_list()
|
||||
if(name_to_material) return // Already set up!
|
||||
/proc/populate_material_list(force_remake=0)
|
||||
if(name_to_material && !force_remake) return // Already set up!
|
||||
name_to_material = list()
|
||||
for(var/type in typesof(/material) - /material)
|
||||
var/material/new_mineral = new type
|
||||
@@ -10,6 +10,12 @@ var/list/name_to_material
|
||||
name_to_material[lowertext(new_mineral.name)] = new_mineral
|
||||
return 1
|
||||
|
||||
/proc/get_material_by_name(name)
|
||||
if(!name_to_material)
|
||||
populate_material_list()
|
||||
|
||||
return name_to_material[name]
|
||||
|
||||
/*
|
||||
Valid sprite masks:
|
||||
stone
|
||||
@@ -102,6 +108,11 @@ var/list/name_to_material
|
||||
icon_reinf = "reinf_over"
|
||||
icon_colour = "#666666"
|
||||
|
||||
/material/steel/holographic
|
||||
name = "holographic [DEFAULT_WALL_MATERIAL]"
|
||||
display_name = DEFAULT_WALL_MATERIAL
|
||||
stack_type = null
|
||||
|
||||
/material/plasteel
|
||||
name = "plasteel"
|
||||
stack_type = /obj/item/stack/sheet/plasteel
|
||||
@@ -159,6 +170,11 @@ var/list/name_to_material
|
||||
icon_base = "solid"
|
||||
explosion_resistance = 2
|
||||
|
||||
/material/wood/holographic
|
||||
name = "holographic wood"
|
||||
display_name = "wood"
|
||||
stack_type = null
|
||||
|
||||
/material/cult
|
||||
name = "cult"
|
||||
display_name = "disturbing stone"
|
||||
|
||||
Reference in New Issue
Block a user