From 4e5306f75415f267be278d90528562a1a0d19cc3 Mon Sep 17 00:00:00 2001 From: L Date: Mon, 1 Jun 2020 20:18:44 -0300 Subject: [PATCH] More defines moves --- code/_onclick/hud/map_popups.dm | 24 ------------------- code/_onclick/hud/screen_objects.dm | 13 ++++++++++ .../modules/asset_cache/asset_cache_client.dm | 9 +------ code/modules/client/client_defines.dm | 16 +++++++++++++ 4 files changed, 30 insertions(+), 32 deletions(-) diff --git a/code/_onclick/hud/map_popups.dm b/code/_onclick/hud/map_popups.dm index dc9e255cba9..2ecfe80ab57 100644 --- a/code/_onclick/hud/map_popups.dm +++ b/code/_onclick/hud/map_popups.dm @@ -1,27 +1,3 @@ -/client - /** - * Assoc list with all the active maps - when a screen obj is added to - * a map, it's put in here as well. - * - * Format: list( = list(/obj/screen)) - */ - var/list/screen_maps = list() - -/obj/screen - /** - * Map name assigned to this object. - * Automatically set by /client/proc/add_obj_to_map. - */ - var/assigned_map - /** - * Mark this object as garbage-collectible after you clean the map - * it was registered on. - * - * This could probably be changed to be a proc, for conditional removal. - * But for now, this works. - */ - var/del_on_map_removal = TRUE - /** * A screen object, which acts as a container for turfs and other things * you want to show on the map, which you usually attach to "vis_contents". diff --git a/code/_onclick/hud/screen_objects.dm b/code/_onclick/hud/screen_objects.dm index 3236a1a0ce8..1f011b619bb 100644 --- a/code/_onclick/hud/screen_objects.dm +++ b/code/_onclick/hud/screen_objects.dm @@ -15,6 +15,19 @@ appearance_flags = APPEARANCE_UI var/obj/master = null //A reference to the object in the slot. Grabs or items, generally. var/datum/hud/hud = null // A reference to the owner HUD, if any. + /** + * Map name assigned to this object. + * Automatically set by /client/proc/add_obj_to_map. + */ + var/assigned_map + /** + * Mark this object as garbage-collectible after you clean the map + * it was registered on. + * + * This could probably be changed to be a proc, for conditional removal. + * But for now, this works. + */ + var/del_on_map_removal = TRUE /obj/screen/take_damage() return diff --git a/code/modules/asset_cache/asset_cache_client.dm b/code/modules/asset_cache/asset_cache_client.dm index 046e6cbfe5b..0755a736af2 100644 --- a/code/modules/asset_cache/asset_cache_client.dm +++ b/code/modules/asset_cache/asset_cache_client.dm @@ -1,11 +1,4 @@ -/client - var/list/sent_assets = list() // List of all asset filenames sent to this client by the asset cache, along with their assoicated md5s - var/list/completed_asset_jobs = list() /// List of all completed blocking send jobs awaiting acknowledgement by send_asset - - var/last_asset_job = 0 /// Last asset send job id. - var/last_completed_asset_job = 0 - /// Process asset cache client topic calls for "asset_cache_confirm_arrival=[INT]" /client/proc/asset_cache_confirm_arrival(job_id) var/asset_cache_job = round(text2num(job_id)) @@ -50,7 +43,7 @@ var/t = 0 var/timeout_time = timeout src << browse({""}, "window=asset_cache_browser&file=asset_cache_send_verify.htm") - + while(!completed_asset_jobs["[job]"] && t < timeout_time) // Reception is handled in Topic() stoplag(1) // Lock up the caller until this is received. t++ diff --git a/code/modules/client/client_defines.dm b/code/modules/client/client_defines.dm index b6849d06335..99caba8a9ac 100644 --- a/code/modules/client/client_defines.dm +++ b/code/modules/client/client_defines.dm @@ -156,3 +156,19 @@ var/parallax_movedir = 0 var/parallax_layers_max = 4 var/parallax_animate_timer + + /** + * Assoc list with all the active maps - when a screen obj is added to + * a map, it's put in here as well. + * + * Format: list( = list(/obj/screen)) + */ + var/list/screen_maps = list() + + // List of all asset filenames sent to this client by the asset cache, along with their assoicated md5s + var/list/sent_assets = list() + /// List of all completed blocking send jobs awaiting acknowledgement by send_asset + var/list/completed_asset_jobs = list() + /// Last asset send job id. + var/last_asset_job = 0 + var/last_completed_asset_job = 0