mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-26 06:22:26 +01:00
Adds a system for random explorable space sites (#6320)
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
var/base_icon = "bed"
|
||||
var/can_dismantle = 1
|
||||
gfi_layer_rotation = GFI_ROTATION_DEFDIR
|
||||
var/apply_material_color = TRUE
|
||||
|
||||
/obj/structure/bed/Initialize(mapload, var/new_material, var/new_padding_material)
|
||||
. = ..()
|
||||
@@ -48,7 +49,8 @@
|
||||
var/cache_key = "[base_icon]-[material.name]"
|
||||
if(!stool_cache[cache_key])
|
||||
var/image/I = image('icons/obj/furniture.dmi', base_icon)
|
||||
I.color = material.icon_colour
|
||||
if(apply_material_color)
|
||||
I.color = material.icon_colour
|
||||
stool_cache[cache_key] = I
|
||||
add_overlay(stool_cache[cache_key])
|
||||
// Padding overlay.
|
||||
@@ -56,7 +58,8 @@
|
||||
var/padding_cache_key = "[base_icon]-padding-[padding_material.name]"
|
||||
if(!stool_cache[padding_cache_key])
|
||||
var/image/I = image(icon, "[base_icon]_padding")
|
||||
I.color = padding_material.icon_colour
|
||||
if(apply_material_color)
|
||||
I.color = padding_material.icon_colour
|
||||
stool_cache[padding_cache_key] = I
|
||||
add_overlay(stool_cache[padding_cache_key])
|
||||
|
||||
|
||||
@@ -41,7 +41,8 @@
|
||||
var/cache_key = "[base_icon]-[material.name]-over"
|
||||
if(isnull(stool_cache[cache_key]))
|
||||
var/image/I = image('icons/obj/furniture.dmi', "[base_icon]_over")
|
||||
I.color = material.icon_colour
|
||||
if(apply_material_color)
|
||||
I.color = material.icon_colour
|
||||
I.layer = FLY_LAYER
|
||||
stool_cache[cache_key] = I
|
||||
add_overlay(stool_cache[cache_key])
|
||||
@@ -50,7 +51,8 @@
|
||||
var/padding_cache_key = "[base_icon]-padding-[padding_material.name]-over"
|
||||
if(isnull(stool_cache[padding_cache_key]))
|
||||
var/image/I = image(icon, "[base_icon]_padding_over")
|
||||
I.color = padding_material.icon_colour
|
||||
if(apply_material_color)
|
||||
I.color = padding_material.icon_colour
|
||||
I.layer = FLY_LAYER
|
||||
stool_cache[padding_cache_key] = I
|
||||
add_overlay(stool_cache[padding_cache_key])
|
||||
@@ -60,7 +62,8 @@
|
||||
if(isnull(stool_cache[cache_key]))
|
||||
var/image/I = image(icon, "[base_icon]_armrest")
|
||||
I.layer = MOB_LAYER + 0.1
|
||||
I.color = padding_material.icon_colour
|
||||
if(apply_material_color)
|
||||
I.color = padding_material.icon_colour
|
||||
stool_cache[cache_key] = I
|
||||
add_overlay(stool_cache[cache_key])
|
||||
|
||||
@@ -216,3 +219,42 @@
|
||||
|
||||
/obj/structure/bed/chair/unmovable
|
||||
can_dismantle = 0
|
||||
|
||||
/obj/structure/bed/chair/shuttle
|
||||
icon_state = "shuttlechair"
|
||||
base_icon = "shuttlechair"
|
||||
can_dismantle = FALSE
|
||||
apply_material_color = FALSE
|
||||
anchored = TRUE
|
||||
|
||||
/obj/structure/bed/chair/shuttle/update_icon()
|
||||
cut_overlays()
|
||||
|
||||
var/image/O = image(icon, "[icon_state]_over")
|
||||
O.layer = FLY_LAYER
|
||||
add_overlay(O)
|
||||
|
||||
var/list/stool_cache = SSicon_cache.stool_cache
|
||||
|
||||
var/cache_key = "[base_icon]_over"
|
||||
if(isnull(stool_cache[cache_key]))
|
||||
var/image/I = image('icons/obj/furniture.dmi', "[base_icon]_over")
|
||||
if(apply_material_color)
|
||||
I.color = material.icon_colour
|
||||
I.layer = FLY_LAYER
|
||||
stool_cache[cache_key] = I
|
||||
add_overlay(stool_cache[cache_key])
|
||||
|
||||
if(buckled_mob)
|
||||
icon_state = "[base_icon]_down"
|
||||
cache_key = "[base_icon]-armrest"
|
||||
if(isnull(stool_cache[cache_key]))
|
||||
var/image/I = image(icon, "[base_icon]_armrest")
|
||||
I.layer = MOB_LAYER + 0.1
|
||||
if(apply_material_color)
|
||||
I.color = padding_material.icon_colour
|
||||
stool_cache[cache_key] = I
|
||||
add_overlay(stool_cache[cache_key])
|
||||
|
||||
else
|
||||
icon_state = initial(icon_state)
|
||||
@@ -0,0 +1,12 @@
|
||||
/obj/structure/warp_drive
|
||||
name = "old warp drive"
|
||||
desc = "A worn down, partially dismantled warp drive. A marvel of engineering from a more civilized age. It doesn't look like it'll be moving anything any time soon."
|
||||
icon_state = "warpdrive"
|
||||
density = TRUE
|
||||
anchored = TRUE
|
||||
light_color = "#6C6CFF"
|
||||
light_power = 4
|
||||
light_range = 3
|
||||
|
||||
/obj/structure/warp_drive/attack_hand(var/mob/user)
|
||||
do_teleport(user, get_turf(user), 8, asoundin = 'sound/effects/phasein.ogg')
|
||||
Reference in New Issue
Block a user