Fixes compiler errors in the preload_rsc external resource thingy (#34061)

Fixes compiler errors in the preload_rsc external resource thingy
This commit is contained in:
Kyle Spier-Swenson
2018-01-15 07:32:20 -08:00
committed by CitadelStationBot
parent a7b75651f9
commit 32adfdae00
3 changed files with 16 additions and 17 deletions

View File

@@ -138,7 +138,7 @@
//CONNECT//
///////////
#if (PRELOAD_RSC == 0)
GLOBAL_LIST(external_rsc_urls)
GLOBAL_LIST_EMPTY(external_rsc_urls)
#endif
@@ -150,13 +150,6 @@ GLOBAL_LIST(external_rsc_urls)
if(connection != "seeker" && connection != "web")//Invalid connection type.
return null
#if (PRELOAD_RSC == 0)
var/static/next_external_rsc = 0
if(external_rsc_urls && external_rsc_urls.len)
next_external_rsc = WRAP(next_external_rsc+1, 1, external_rsc_urls.len+1)
preload_rsc = external_rsc_urls[next_external_rsc]
#endif
GLOB.clients += src
GLOB.directory[ckey] = src
@@ -654,6 +647,12 @@ GLOBAL_LIST(external_rsc_urls)
//send resources to the client. It's here in its own proc so we can move it around easiliy if need be
/client/proc/send_resources()
#if (PRELOAD_RSC == 0)
var/static/next_external_rsc = 0
if(GLOB.external_rsc_urls && GLOB.external_rsc_urls.len)
next_external_rsc = WRAP(next_external_rsc+1, 1, GLOB.external_rsc_urls.len+1)
preload_rsc = GLOB.external_rsc_urls[next_external_rsc]
#endif
//get the common files
getFiles(
'html/search.js',