mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 13:10:02 +01:00
[MIRROR] Multiz Rework: Human Suffering Edition (Contains PLANE CUBE) [MDB IGNORE] (#16472)
* Multiz Rework: Human Suffering Edition (Contains PLANE CUBE) * skyrat changes * bodyparts merge * unres door floorlight fix * Future upstream fix for blindness * upcoming upstream airlock fix * fix button emissive * Fix FOV markings? Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com> Co-authored-by: tastyfish <crazychris32@gmail.com>
This commit is contained in:
co-authored by
LemonInTheDark
tastyfish
parent
ddf91791f1
commit
9bf006d189
@@ -1,55 +1,7 @@
|
||||
INITIALIZE_IMMEDIATE(/atom/movable/screen/color_matrix_proxy_view)
|
||||
|
||||
/atom/movable/screen/color_matrix_proxy_view
|
||||
name = "color_matrix_proxy_view"
|
||||
del_on_map_removal = FALSE
|
||||
layer = GAME_PLANE
|
||||
plane = GAME_PLANE
|
||||
|
||||
var/list/plane_masters = list()
|
||||
|
||||
/// The client that is watching this view
|
||||
var/client/client
|
||||
|
||||
/atom/movable/screen/color_matrix_proxy_view/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
assigned_map = "color_matrix_proxy_[REF(src)]"
|
||||
set_position(1, 1)
|
||||
|
||||
/atom/movable/screen/color_matrix_proxy_view/Destroy()
|
||||
for (var/plane_master in plane_masters)
|
||||
client?.screen -= plane_master
|
||||
qdel(plane_master)
|
||||
|
||||
client?.clear_map(assigned_map)
|
||||
|
||||
client = null
|
||||
plane_masters = null
|
||||
|
||||
return ..()
|
||||
|
||||
/atom/movable/screen/color_matrix_proxy_view/proc/register_to_client(client/client)
|
||||
QDEL_LIST(plane_masters)
|
||||
|
||||
src.client = client
|
||||
|
||||
if (!client)
|
||||
return
|
||||
|
||||
for (var/plane_master_type in subtypesof(/atom/movable/screen/plane_master) - /atom/movable/screen/plane_master/blackness)
|
||||
var/atom/movable/screen/plane_master/plane_master = new plane_master_type()
|
||||
plane_master.screen_loc = "[assigned_map]:CENTER"
|
||||
client?.screen |= plane_master
|
||||
|
||||
plane_masters += plane_master
|
||||
|
||||
client?.register_map_obj(src)
|
||||
|
||||
/datum/color_matrix_editor
|
||||
var/client/owner
|
||||
var/datum/weakref/target
|
||||
var/atom/movable/screen/color_matrix_proxy_view/proxy_view
|
||||
var/atom/movable/screen/map_view/proxy_view
|
||||
var/list/current_color
|
||||
var/closed
|
||||
|
||||
@@ -61,15 +13,19 @@ INITIALIZE_IMMEDIATE(/atom/movable/screen/color_matrix_proxy_view)
|
||||
current_color = color_hex2color_matrix(_target.color)
|
||||
else
|
||||
current_color = color_matrix_identity()
|
||||
proxy_view = new
|
||||
|
||||
var/mutable_appearance/view = image('icons/misc/colortest.dmi', "colors")
|
||||
if(_target)
|
||||
target = WEAKREF(_target)
|
||||
proxy_view.appearance = image(_target)
|
||||
else
|
||||
proxy_view.appearance = image('icons/misc/colortest.dmi', "colors")
|
||||
if(!(_target.appearance_flags & PLANE_MASTER))
|
||||
view = image(_target)
|
||||
|
||||
proxy_view = new
|
||||
proxy_view.generate_view("color_matrix_proxy_[REF(src)]")
|
||||
|
||||
proxy_view.appearance = view
|
||||
proxy_view.color = current_color
|
||||
proxy_view.register_to_client(owner)
|
||||
proxy_view.display_to(owner.mob)
|
||||
|
||||
/datum/color_matrix_editor/Destroy(force, ...)
|
||||
QDEL_NULL(proxy_view)
|
||||
|
||||
Reference in New Issue
Block a user