mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-09 16:12:17 +00:00
[MIRROR] code/global.dm => code/_global_vars/ (#10689)
Co-authored-by: Selis <12716288+ItsSelis@users.noreply.github.com> Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
a7718c6177
commit
f04f992cfe
@@ -7,7 +7,7 @@
|
||||
event_type = /datum/event2/event/wildlife_encounter
|
||||
|
||||
/datum/event2/meta/wildlife_encounter/get_weight()
|
||||
var/explorers = metric.count_people_with_job(/datum/job/explorer) + metric.count_people_with_job(/datum/job/sar)
|
||||
var/explorers = GLOB.metric.count_people_with_job(/datum/job/explorer) + GLOB.metric.count_people_with_job(/datum/job/sar)
|
||||
|
||||
if(!explorers)
|
||||
return 0
|
||||
|
||||
@@ -178,7 +178,7 @@ var/global/list/pipe_colors = list("grey" = PIPE_COLOR_GREY, "red" = PIPE_COLOR_
|
||||
|
||||
var/cache_name = state
|
||||
|
||||
for(var/D in cardinal)
|
||||
for(var/D in GLOB.cardinal)
|
||||
var/image/I = image('icons/atmos/pipe_underlays.dmi', icon_state = state, dir = D)
|
||||
underlays[cache_name + "[D]"] = I
|
||||
for(var/pipe_color in pipe_colors)
|
||||
@@ -210,7 +210,7 @@ var/global/list/pipe_colors = list("grey" = PIPE_COLOR_GREY, "red" = PIPE_COLOR_
|
||||
if(state == "")
|
||||
continue
|
||||
|
||||
for(var/D in cardinal)
|
||||
for(var/D in GLOB.cardinal)
|
||||
var/image/I = image('icons/atmos/pipe_underlays.dmi', icon_state = state, dir = D)
|
||||
switch(state)
|
||||
if("intact")
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
var/image/I = image(icon = icon, icon_state = "algae-pipe-overlay", dir = dir)
|
||||
I.color = PIPE_COLOR_BLUE
|
||||
add_overlay(I)
|
||||
I = image(icon = icon, icon_state = "algae-pipe-overlay", dir = reverse_dir[dir])
|
||||
I = image(icon = icon, icon_state = "algae-pipe-overlay", dir = GLOB.reverse_dir[dir])
|
||||
I.color = PIPE_COLOR_BLACK
|
||||
add_overlay(I)
|
||||
|
||||
@@ -186,7 +186,7 @@
|
||||
data["materials"] = materials_ui
|
||||
data["last_flow_rate"] = last_flow_rate
|
||||
data["last_power_draw"] = last_power_draw
|
||||
data["inputDir"] = dir2text(reverse_dir[dir])
|
||||
data["inputDir"] = dir2text(GLOB.reverse_dir[dir])
|
||||
data["outputDir"] = dir2text(dir)
|
||||
data["usePower"] = use_power
|
||||
data["errorText"] = ui_error
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
icon_state = "base"
|
||||
|
||||
ports = new()
|
||||
for(var/d in cardinal)
|
||||
for(var/d in GLOB.cardinal)
|
||||
var/datum/omni_port/new_port = new(src, d)
|
||||
switch(d)
|
||||
if(NORTH)
|
||||
|
||||
@@ -129,7 +129,7 @@
|
||||
|
||||
// Return the air from the turf in "front" of us (opposite the way the pipe is facing)
|
||||
/obj/machinery/atmospherics/unary/vent_pump/high_volume/wall_mounted/return_air()
|
||||
var/turf/T = get_step(src, reverse_dir[dir])
|
||||
var/turf/T = get_step(src, GLOB.reverse_dir[dir])
|
||||
if(isnull(T))
|
||||
return ..()
|
||||
return T.return_air()
|
||||
|
||||
@@ -151,7 +151,7 @@
|
||||
var/node1_dir
|
||||
var/node2_dir
|
||||
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
if(direction&initialize_directions)
|
||||
if (!node1_dir)
|
||||
node1_dir = direction
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
var/node1_dir
|
||||
var/node2_dir
|
||||
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
if(direction&initialize_directions_he)
|
||||
if (!node1_dir)
|
||||
node1_dir = direction
|
||||
|
||||
@@ -137,7 +137,7 @@
|
||||
/obj/machinery/atmospherics/pipe/manifold/atmos_init()
|
||||
var/connect_directions = (NORTH|SOUTH|EAST|WEST)&(~dir)
|
||||
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
if(direction&connect_directions)
|
||||
for(var/obj/machinery/atmospherics/target in get_step(src,direction))
|
||||
if (can_be_node(target, 1))
|
||||
@@ -148,7 +148,7 @@
|
||||
break
|
||||
|
||||
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
if(direction&connect_directions)
|
||||
for(var/obj/machinery/atmospherics/target in get_step(src,direction))
|
||||
if (can_be_node(target, 2))
|
||||
@@ -159,7 +159,7 @@
|
||||
break
|
||||
|
||||
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
if(direction&connect_directions)
|
||||
for(var/obj/machinery/atmospherics/target in get_step(src,direction))
|
||||
if (can_be_node(target, 3))
|
||||
|
||||
@@ -132,7 +132,7 @@
|
||||
var/node1_dir
|
||||
var/node2_dir
|
||||
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
if(direction&initialize_directions)
|
||||
if (!node1_dir)
|
||||
node1_dir = direction
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
/*
|
||||
|
||||
Overview:
|
||||
The connection_manager class stores connections in each cardinal direction on a turf.
|
||||
The connection_manager class stores connections in each GLOB.cardinal direction on a turf.
|
||||
It isn't always present if a turf has no connections, check if(connections) before using.
|
||||
Contains procs for mass manipulation of connection data.
|
||||
|
||||
Class Vars:
|
||||
|
||||
NSEWUD - Connections to this turf in each cardinal direction.
|
||||
NSEWUD - Connections to this turf in each GLOB.cardinal direction.
|
||||
|
||||
Class Procs:
|
||||
|
||||
|
||||
@@ -158,7 +158,7 @@ If it gains pressure too slowly, it may leak or just rupture instead of explodin
|
||||
A.fire_act(air_contents, air_contents.temperature, air_contents.volume)
|
||||
|
||||
//spread
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
var/turf/simulated/enemy_tile = get_step(my_tile, direction)
|
||||
|
||||
if(istype(enemy_tile))
|
||||
@@ -197,7 +197,7 @@ If it gains pressure too slowly, it may leak or just rupture instead of explodin
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
set_dir(pick(cardinal))
|
||||
set_dir(pick(GLOB.cardinal))
|
||||
|
||||
var/datum/gas_mixture/air_contents = loc.return_air()
|
||||
color = fire_color(air_contents.temperature)
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
var/unconnected_dirs = check_dirs
|
||||
|
||||
#ifdef MULTIZAS
|
||||
var/to_check = cornerdirsz
|
||||
var/to_check = GLOB.cornerdirsz
|
||||
#else
|
||||
var/to_check = cornerdirs
|
||||
#endif
|
||||
@@ -99,7 +99,7 @@
|
||||
/*
|
||||
//check that they are connected by the corner turf
|
||||
var/connected_dirs = get_zone_neighbours(get_step(src, dir))
|
||||
if(connected_dirs && (dir & reverse_dir[connected_dirs]) == dir)
|
||||
if(connected_dirs && (dir & GLOB.reverse_dir[connected_dirs]) == dir)
|
||||
unconnected_dirs &= ~dir //they are, so unflag the cardinals in question
|
||||
*/
|
||||
var/turf/simulated/T = get_step(src, dir)
|
||||
@@ -120,9 +120,9 @@
|
||||
. = 0
|
||||
if(istype(T) && T.zone)
|
||||
#ifdef MULTIZAS
|
||||
var/to_check = cardinalz
|
||||
var/to_check = GLOB.cardinalz
|
||||
#else
|
||||
var/to_check = cardinal
|
||||
var/to_check = GLOB.cardinal
|
||||
#endif
|
||||
for(var/dir in to_check)
|
||||
var/turf/simulated/other = get_step(T, dir)
|
||||
@@ -205,7 +205,7 @@
|
||||
if(istype(unsim, /turf/simulated))
|
||||
|
||||
var/turf/simulated/sim = unsim
|
||||
sim.open_directions |= GLOB.reverse_dir[d] // CHOMPEdit
|
||||
sim.open_directions |= GLOB.reverse_dir[d]
|
||||
|
||||
if(TURF_HAS_VALID_ZONE(sim)) // CHOMPEdit
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// NEVER leave this on in your PR or the server will probably explode
|
||||
// #define ENABLE_BYOND_TRACY
|
||||
#define ENABLE_BYOND_TRACY
|
||||
/datum/super_early_init
|
||||
|
||||
/datum/super_early_init/New()
|
||||
|
||||
@@ -143,10 +143,10 @@
|
||||
#define WALL_CAN_OPEN 1
|
||||
#define WALL_OPENING 2
|
||||
|
||||
#define BOMBCAP_DVSTN_RADIUS (max_explosion_range/4)
|
||||
#define BOMBCAP_HEAVY_RADIUS (max_explosion_range/2)
|
||||
#define BOMBCAP_LIGHT_RADIUS max_explosion_range
|
||||
#define BOMBCAP_FLASH_RADIUS (max_explosion_range*1.5)
|
||||
#define BOMBCAP_DVSTN_RADIUS (GLOB.max_explosion_range/4)
|
||||
#define BOMBCAP_HEAVY_RADIUS (GLOB.max_explosion_range/2)
|
||||
#define BOMBCAP_LIGHT_RADIUS GLOB.max_explosion_range
|
||||
#define BOMBCAP_FLASH_RADIUS (GLOB.max_explosion_range*1.5)
|
||||
// NTNet module-configuration values. Do not change these. If you need to add another use larger number (5..6..7 etc)
|
||||
#define NTNET_SOFTWAREDOWNLOAD 1 // Downloads of software from NTNet
|
||||
#define NTNET_PEERTOPEER 2 // P2P transfers of files between devices
|
||||
|
||||
87
code/_global_vars/__unsorted.dm
Normal file
87
code/_global_vars/__unsorted.dm
Normal file
@@ -0,0 +1,87 @@
|
||||
// Items that ask to be called every cycle.
|
||||
GLOBAL_DATUM(data_core, /datum/datacore)
|
||||
|
||||
//I would upgrade all instances of global.machines to SSmachines.all_machines but it's used in so many places and a search returns so many matches for 'machines' that isn't a use of the global...
|
||||
GLOBAL_LIST_INIT(machines, SSmachines.all_machines)
|
||||
|
||||
GLOBAL_LIST_EMPTY(active_diseases)
|
||||
GLOBAL_LIST_EMPTY(hud_icon_reference)
|
||||
|
||||
GLOBAL_LIST_EMPTY(global_mutations) // List of hidden mutation things.
|
||||
|
||||
GLOBAL_DATUM_INIT(universe, /datum/universal_state, new)
|
||||
|
||||
GLOBAL_LIST(global_map)
|
||||
|
||||
// Noises made when hit while typing.
|
||||
GLOBAL_LIST_INIT(hit_appends, list("-OOF", "-ACK", "-UGH", "-HRNK", "-HURGH", "-GLORF"))
|
||||
|
||||
// var/station_name = "Northern Star"
|
||||
// var/const/station_orig = "Northern Star" //station_name can't be const due to event prefix/suffix
|
||||
// var/const/station_short = "Northern Star"
|
||||
// var/const/dock_name = "Vir Interstellar Spaceport"
|
||||
// var/const/boss_name = "Central Command"
|
||||
// var/const/boss_short = "CentCom"
|
||||
// var/const/company_name = "NanoTrasen"
|
||||
// var/const/company_short = "NT"
|
||||
// var/const/star_name = "Vir"
|
||||
// var/const/starsys_name = "Vir"
|
||||
GLOBAL_VAR_INIT(servernews_hash, "") //ChompADD - news hash gen
|
||||
GLOBAL_VAR_INIT(game_year, (text2num(time2text(world.realtime, "YYYY")) + 544)) // CHOMPEdit
|
||||
GLOBAL_VAR_INIT(round_progressing, TRUE)
|
||||
|
||||
GLOBAL_VAR_INIT(master_mode, "extended") // "extended"
|
||||
GLOBAL_VAR_INIT(secret_force_mode, "secret") // if this is anything but "secret", the secret rotation will forceably choose this mode.
|
||||
|
||||
GLOBAL_DATUM_INIT(mods, /datum/moduletypes, new())
|
||||
|
||||
GLOBAL_VAR_INIT(gravity_is_on, TRUE)
|
||||
|
||||
GLOBAL_VAR(join_motd)
|
||||
|
||||
// Metric datum, used to keep track of the round.
|
||||
GLOBAL_DATUM_INIT(metric, /datum/metric, new())
|
||||
|
||||
// For FTP requests. (i.e. downloading runtime logs.)
|
||||
// However it'd be ok to use for accessing attack logs and such too, which are even laggier.
|
||||
GLOBAL_VAR_INIT(fileaccess_timer, 0)
|
||||
GLOBAL_VAR(custom_event_msg)
|
||||
|
||||
|
||||
// Used by robots and robot preferences for regular modules.
|
||||
GLOBAL_LIST_INIT(robot_module_types, list(
|
||||
"Standard", "Engineering", /*"Surgeon",*/ "Crisis", "Miner",
|
||||
"Janitor", "Service", "Clown", "Clerical", "Security",
|
||||
"Research", "Command", "Exploration" //CHOMPedit: Enables Exploration borg.
|
||||
))
|
||||
// List of modules added during code red
|
||||
GLOBAL_LIST_INIT(emergency_module_types, list(
|
||||
"Combat"
|
||||
))
|
||||
// List of modules available to AI shells
|
||||
GLOBAL_LIST_INIT(shell_module_types, list(
|
||||
"Standard", "Engineering", "Surgeon", "Crisis", "Miner",
|
||||
"Janitor", "Service", "Clown", "Clerical", "Security",
|
||||
"Research", "Command", "Exploration" //CHOMPedit: Enables Exploration borg.
|
||||
))
|
||||
// List of whitelisted modules
|
||||
GLOBAL_LIST_INIT(whitelisted_module_types, list(
|
||||
"Lost"
|
||||
))
|
||||
|
||||
// Bomb cap!
|
||||
GLOBAL_VAR_INIT(max_explosion_range, 14)
|
||||
|
||||
// Announcer intercom, because too much stuff creates an intercom for one message then hard del()s it.
|
||||
GLOBAL_DATUM_INIT(global_announcer, /obj/item/radio/intercom/omni, new /obj/item/radio/intercom/omni(null))
|
||||
|
||||
GLOBAL_LIST_INIT(station_departments, list("Command", "Medical", "Engineering", "Research", "Security", "Cargo", "Exploration", "Civilian"))
|
||||
|
||||
//Icons for in-game HUD glasses. Why don't we just share these a little bit?
|
||||
GLOBAL_DATUM_INIT(ingame_hud, /icon, icon('icons/mob/hud.dmi'))
|
||||
GLOBAL_DATUM_INIT(ingame_hud_med, /icon, icon('icons/mob/hud_med.dmi'))
|
||||
GLOBAL_DATUM_INIT(buildmode_hud, /icon, icon('icons/misc/buildmode.dmi'))
|
||||
|
||||
//Keyed list for caching icons so you don't need to make them for records, IDs, etc all separately.
|
||||
//Could be useful for AI impersonation or something at some point?
|
||||
GLOBAL_LIST_EMPTY(cached_character_icons)
|
||||
@@ -6,3 +6,6 @@ GLOBAL_DATUM_INIT(revdata, /datum/getrev, new)
|
||||
|
||||
GLOBAL_VAR_INIT(game_version, "CHOMPStation") // CHOMPEdit TFF 24/12/19 - Chompers
|
||||
GLOBAL_VAR_INIT(changelog_hash, "")
|
||||
|
||||
// Debug2 is used in conjunction with a lot of admin verbs and therefore is actually legit.
|
||||
GLOBAL_VAR_INIT(Debug2, FALSE)
|
||||
|
||||
37
code/_global_vars/lists/flavor_misc.dm
Normal file
37
code/_global_vars/lists/flavor_misc.dm
Normal file
@@ -0,0 +1,37 @@
|
||||
GLOBAL_LIST_INIT(scarySounds, list(
|
||||
'sound/weapons/thudswoosh.ogg',
|
||||
'sound/weapons/Taser.ogg',
|
||||
'sound/weapons/armbomb.ogg',
|
||||
'sound/voice/hiss1.ogg',
|
||||
'sound/voice/hiss2.ogg',
|
||||
'sound/voice/hiss3.ogg',
|
||||
'sound/voice/hiss4.ogg',
|
||||
'sound/voice/hiss5.ogg',
|
||||
'sound/voice/hiss6.ogg',
|
||||
'sound/effects/Glassbr1.ogg',
|
||||
'sound/effects/Glassbr2.ogg',
|
||||
'sound/effects/Glassbr3.ogg',
|
||||
'sound/items/Welder.ogg',
|
||||
'sound/items/Welder2.ogg',
|
||||
'sound/machines/door/old_airlock.ogg',
|
||||
'sound/effects/clownstep1.ogg',
|
||||
'sound/effects/clownstep2.ogg',
|
||||
'sound/voice/teppi/roar.ogg',
|
||||
'sound/voice/moth/scream_moth.ogg',
|
||||
'sound/voice/nya.ogg',
|
||||
'sound/voice/succlet_shriek.ogg'
|
||||
))
|
||||
|
||||
GLOBAL_LIST_INIT(scawwySownds, list(
|
||||
'sound/voice/ScawwySownds/a scawey sownd.ogg',
|
||||
'sound/voice/ScawwySownds/is that you.ogg',
|
||||
'sound/voice/ScawwySownds/lookit this darkness wow.ogg',
|
||||
'sound/voice/ScawwySownds/maint preds.ogg',
|
||||
'sound/voice/ScawwySownds/spooky sounds.ogg',
|
||||
'sound/voice/ScawwySownds/sus.ogg',
|
||||
'sound/voice/ScawwySownds/this is scaewy.ogg',
|
||||
'sound/voice/ScawwySownds/what is that behind you.ogg',
|
||||
'sound/voice/ScawwySownds/what you doin over dere.ogg',
|
||||
'sound/voice/ScawwySownds/whats up with all the trash.ogg',
|
||||
'sound/voice/ScawwySownds/youre afraid of the dark arent you.ogg'
|
||||
))
|
||||
17
code/_global_vars/lists/logging.dm
Normal file
17
code/_global_vars/lists/logging.dm
Normal file
@@ -0,0 +1,17 @@
|
||||
GLOBAL_LIST_EMPTY(admin_log)
|
||||
GLOBAL_PROTECT(admin_log)
|
||||
|
||||
GLOBAL_LIST_EMPTY(lastsignalers) // Keeps last 100 signals here in format: "[src] used \ref[src] @ location [src.loc]: [freq]/[code]"
|
||||
GLOBAL_PROTECT(lastsignalers)
|
||||
|
||||
GLOBAL_LIST_EMPTY(combatlog)
|
||||
GLOBAL_PROTECT(combatlog)
|
||||
|
||||
GLOBAL_LIST_EMPTY(IClog)
|
||||
GLOBAL_PROTECT(IClog)
|
||||
|
||||
GLOBAL_LIST_EMPTY(OOClog)
|
||||
GLOBAL_PROTECT(OOClog)
|
||||
|
||||
GLOBAL_LIST_EMPTY(adminlog)
|
||||
GLOBAL_PROTECT(adminlog)
|
||||
@@ -30,3 +30,34 @@ GLOBAL_LIST_INIT(cww_dir, list( // cww_dir[dir] = counter-clockwise rotation of
|
||||
32, 40, 36, 44, 33, 41, 37, 45, 34, 42, 38, 46, 35, 43, 39, 47, // DOWN - Same as first line but +32
|
||||
48, 56, 52, 60, 49, 57, 53, 61, 50, 58, 54, 62, 51, 59, 55, 63 // UP+DOWN - Same as first line but +48
|
||||
))
|
||||
|
||||
GLOBAL_LIST_EMPTY(monkeystart)
|
||||
GLOBAL_LIST_EMPTY(wizardstart)
|
||||
GLOBAL_LIST_EMPTY(newplayer_start)
|
||||
|
||||
GLOBAL_LIST_EMPTY(latejoin)
|
||||
GLOBAL_LIST_EMPTY(latejoin_gateway)
|
||||
GLOBAL_LIST_EMPTY(latejoin_elevator)
|
||||
GLOBAL_LIST_EMPTY(latejoin_cryo)
|
||||
GLOBAL_LIST_EMPTY(latejoin_cyborg)
|
||||
|
||||
GLOBAL_LIST_EMPTY(prisonwarp) // Prisoners go to these
|
||||
GLOBAL_LIST_EMPTY(holdingfacility) // Captured people go here
|
||||
GLOBAL_LIST_EMPTY(xeno_spawn) // Aliens spawn at at these.
|
||||
GLOBAL_LIST_EMPTY(tdome1)
|
||||
GLOBAL_LIST_EMPTY(tdome2)
|
||||
GLOBAL_LIST_EMPTY(tdomeobserve)
|
||||
GLOBAL_LIST_EMPTY(tdomeadmin)
|
||||
GLOBAL_LIST_EMPTY(prisonsecuritywarp) // Prison security goes to these.
|
||||
GLOBAL_LIST_EMPTY(prisonwarped) // List of players already warped.
|
||||
GLOBAL_LIST_EMPTY(blobstart)
|
||||
GLOBAL_LIST_EMPTY(ninjastart)
|
||||
|
||||
GLOBAL_LIST_EMPTY(awaydestinations) // Away missions. A list of landmarks that the warpgate can take you to.
|
||||
|
||||
GLOBAL_LIST_EMPTY(vinestart)
|
||||
GLOBAL_LIST_EMPTY(verminstart)
|
||||
|
||||
GLOBAL_LIST_EMPTY(awayabductors) // List of scatter landmarks for Abductors in Gateways
|
||||
GLOBAL_LIST_EMPTY(eventdestinations) // List of scatter landmarks for VOREStation event portals
|
||||
GLOBAL_LIST_EMPTY(eventabductors) // List of scatter landmarks for VOREStation abductor portals
|
||||
|
||||
@@ -1,2 +1,32 @@
|
||||
GLOBAL_VAR(round_id)
|
||||
GLOBAL_PROTECT(round_id)
|
||||
|
||||
/// The directory in which ALL log files should be stored
|
||||
GLOBAL_VAR_INIT(log_directory, "data/logs/") //See world.dm for the full calculated path
|
||||
GLOBAL_PROTECT(log_directory)
|
||||
|
||||
GLOBAL_VAR(diary)
|
||||
GLOBAL_PROTECT(diary)
|
||||
|
||||
GLOBAL_VAR(error_log)
|
||||
GLOBAL_PROTECT(error_log)
|
||||
|
||||
GLOBAL_VAR(sql_error_log)
|
||||
GLOBAL_PROTECT(sql_error_log)
|
||||
|
||||
GLOBAL_VAR(query_debug_log)
|
||||
GLOBAL_PROTECT(query_debug_log)
|
||||
|
||||
GLOBAL_VAR(debug_log)
|
||||
GLOBAL_PROTECT(debug_log)
|
||||
|
||||
GLOBAL_VAR(href_logfile)
|
||||
GLOBAL_PROTECT(href_logfile)
|
||||
|
||||
/// All bomb related messages
|
||||
GLOBAL_LIST_EMPTY(bombers)
|
||||
GLOBAL_PROTECT(bombers)
|
||||
|
||||
/// Stores who uploaded laws to which silicon-based lifeform, and what the law was
|
||||
GLOBAL_LIST_EMPTY(lawchanges)
|
||||
GLOBAL_PROTECT(lawchanges)
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
*
|
||||
* However it'd be ok to use for accessing attack logs and such too, which are even laggier.
|
||||
*/
|
||||
GLOBAL_VAR_INIT(fileaccess_timer, 0)
|
||||
|
||||
/client/proc/browse_files(root_type=BROWSE_ROOT_ALL_LOGS, max_iterations=10, list/valid_extensions=list("txt","log","htm", "html", "gz", "json"))
|
||||
// wow why was this ever a parameter
|
||||
@@ -26,7 +25,7 @@ GLOBAL_VAR_INIT(fileaccess_timer, 0)
|
||||
if(BROWSE_ROOT_ALL_LOGS)
|
||||
root = "data/logs/"
|
||||
if(BROWSE_ROOT_CURRENT_LOGS)
|
||||
root = log_path
|
||||
root = GLOB.log_directory
|
||||
var/path = root
|
||||
|
||||
for(var/i in 1 to max_iterations)
|
||||
|
||||
@@ -382,7 +382,7 @@
|
||||
else
|
||||
return 0
|
||||
|
||||
/proc/get_cardinal_step_away(atom/start, atom/finish) //returns the position of a step from start away from finish, in one of the cardinal directions
|
||||
/proc/get_cardinal_step_away(atom/start, atom/finish) //returns the position of a step from start away from finish, in one of the GLOB.cardinal directions
|
||||
//returns only NORTH, SOUTH, EAST, or WEST
|
||||
var/dx = finish.x - start.x
|
||||
var/dy = finish.y - start.y
|
||||
@@ -550,7 +550,7 @@
|
||||
return mixedcolor
|
||||
|
||||
/**
|
||||
* Gets the highest and lowest pressures from the tiles in cardinal directions
|
||||
* Gets the highest and lowest pressures from the tiles in GLOB.cardinal directions
|
||||
* around us, then checks the difference.
|
||||
*/
|
||||
/proc/getOPressureDifferential(var/turf/loc)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
/* For logging round startup. */
|
||||
/proc/start_log(log)
|
||||
WRITE_LOG(log, "START: Starting up [log_path].")
|
||||
WRITE_LOG(log, "START: Starting up [GLOB.log_directory].")
|
||||
return log
|
||||
|
||||
/* Close open log handles. This should be called as late as possible, and no logging should hapen after. */
|
||||
@@ -27,29 +27,28 @@
|
||||
to_world_log("## TESTING: [msg]")
|
||||
|
||||
/proc/log_admin(text)
|
||||
admin_log.Add(text)
|
||||
GLOB.admin_log.Add(text)
|
||||
if (CONFIG_GET(flag/log_admin))
|
||||
WRITE_LOG(diary, "ADMIN: [text]")
|
||||
WRITE_LOG(GLOB.diary, "ADMIN: [text]")
|
||||
|
||||
/proc/log_admin_private(text)
|
||||
admin_log.Add(text)
|
||||
GLOB.admin_log.Add(text)
|
||||
if (CONFIG_GET(flag/log_admin))
|
||||
WRITE_LOG(diary, "ADMINPRIVATE: [text]")
|
||||
WRITE_LOG(GLOB.diary, "ADMINPRIVATE: [text]")
|
||||
|
||||
/proc/log_adminpm(text, client/source, client/dest)
|
||||
admin_log.Add(text)
|
||||
GLOB.admin_log.Add(text)
|
||||
if (CONFIG_GET(flag/log_admin))
|
||||
WRITE_LOG(diary, "ADMINPM: [key_name(source)]->[key_name(dest)]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "ADMINPM: [key_name(source)]->[key_name(dest)]: [html_decode(text)]")
|
||||
|
||||
/proc/log_pray(text, client/source)
|
||||
admin_log.Add(text)
|
||||
GLOB.admin_log.Add(text)
|
||||
if (CONFIG_GET(flag/log_admin))
|
||||
WRITE_LOG(diary, "PRAY: [key_name(source)]: [text]")
|
||||
WRITE_LOG(GLOB.diary, "PRAY: [key_name(source)]: [text]")
|
||||
|
||||
/proc/log_debug(text)
|
||||
//if (CONFIG_GET(flag/log_debug)) // CHOMPRemove
|
||||
// WRITE_LOG(debug_log, "DEBUG: [sanitize(text)]") // CHOMPRemove
|
||||
WRITE_LOG(debug_log, "DEBUG: [sanitize(text)]")
|
||||
if (CONFIG_GET(flag/log_debug))
|
||||
WRITE_LOG(GLOB.debug_log, "DEBUG: [sanitize(text)]")
|
||||
|
||||
for(var/client/C in GLOB.admins)
|
||||
if(C.prefs?.read_preference(/datum/preference/toggle/show_debug_logs))
|
||||
@@ -59,25 +58,25 @@
|
||||
|
||||
/proc/log_game(text)
|
||||
if (CONFIG_GET(flag/log_game))
|
||||
WRITE_LOG(diary, "GAME: [text]")
|
||||
WRITE_LOG(GLOB.diary, "GAME: [text]")
|
||||
|
||||
/proc/log_vote(text)
|
||||
if (CONFIG_GET(flag/log_vote))
|
||||
WRITE_LOG(diary, "VOTE: [text]")
|
||||
WRITE_LOG(GLOB.diary, "VOTE: [text]")
|
||||
|
||||
/proc/log_access_in(client/new_client)
|
||||
if (CONFIG_GET(flag/log_access))
|
||||
var/message = "[key_name(new_client)] - IP:[new_client.address] - CID:[new_client.computer_id] - BYOND v[new_client.byond_version]"
|
||||
WRITE_LOG(diary, "ACCESS IN: [message]") //VOREStation Edit
|
||||
WRITE_LOG(GLOB.diary, "ACCESS IN: [message]") //VOREStation Edit
|
||||
|
||||
/proc/log_access_out(mob/last_mob)
|
||||
if (CONFIG_GET(flag/log_access))
|
||||
var/message = "[key_name(last_mob)] - IP:[last_mob.lastKnownIP] - CID:Logged Out - BYOND Logged Out"
|
||||
WRITE_LOG(diary, "ACCESS OUT: [message]")
|
||||
WRITE_LOG(GLOB.diary, "ACCESS OUT: [message]")
|
||||
|
||||
/proc/log_say(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_say))
|
||||
WRITE_LOG(diary, "SAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "SAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
|
||||
//Log the message to in-game dialogue logs, as well. //CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
@@ -98,7 +97,7 @@
|
||||
|
||||
/proc/log_ooc(text, client/user)
|
||||
if (CONFIG_GET(flag/log_ooc))
|
||||
WRITE_LOG(diary, "OOC: [user.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "OOC: [user.simple_info_line()]: [html_decode(text)]")
|
||||
if(!SSdbcore.IsConnected())
|
||||
establish_db_connection()
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -114,7 +113,7 @@
|
||||
|
||||
/proc/log_aooc(text, client/user)
|
||||
if (CONFIG_GET(flag/log_ooc))
|
||||
WRITE_LOG(diary, "AOOC: [user.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "AOOC: [user.simple_info_line()]: [html_decode(text)]")
|
||||
if(!SSdbcore.IsConnected())
|
||||
establish_db_connection()
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -130,7 +129,7 @@
|
||||
|
||||
/proc/log_looc(text, client/user)
|
||||
if (CONFIG_GET(flag/log_ooc))
|
||||
WRITE_LOG(diary, "LOOC: [user.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "LOOC: [user.simple_info_line()]: [html_decode(text)]")
|
||||
if(!SSdbcore.IsConnected())
|
||||
establish_db_connection()
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -146,7 +145,7 @@
|
||||
|
||||
/proc/log_whisper(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_whisper))
|
||||
WRITE_LOG(diary, "WHISPER: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "WHISPER: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
|
||||
if(speaker.client)
|
||||
//speaker.dialogue_log += span_bold("([time_stamp()])") + " (" + span_bold("[speaker]/[speaker.client]") + ") " + span_underline("SAY:") + " - " + span_gray(span_italics("[text]"))
|
||||
@@ -165,7 +164,7 @@
|
||||
|
||||
/proc/log_emote(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_emote))
|
||||
WRITE_LOG(diary, "EMOTE: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "EMOTE: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
//CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
//speaker.dialogue_log += span_bold("([time_stamp()])") + " (" + span_bold("[speaker]/[speaker.client]") + ") " + span_underline("EMOTE:") + " - " + span_pink("[text]")
|
||||
@@ -185,23 +184,23 @@
|
||||
|
||||
/proc/log_attack(attacker, defender, message)
|
||||
if (CONFIG_GET(flag/log_attack))
|
||||
WRITE_LOG(diary, "ATTACK: [attacker] against [defender]: [message]")
|
||||
WRITE_LOG(GLOB.diary, "ATTACK: [attacker] against [defender]: [message]")
|
||||
|
||||
/proc/log_adminsay(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_adminchat))
|
||||
WRITE_LOG(diary, "ADMINSAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "ADMINSAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
|
||||
/proc/log_modsay(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_adminchat))
|
||||
WRITE_LOG(diary, "MODSAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "MODSAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
|
||||
/proc/log_eventsay(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_adminchat))
|
||||
WRITE_LOG(diary, "EVENTSAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "EVENTSAY: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
|
||||
/proc/log_ghostsay(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_say))
|
||||
WRITE_LOG(diary, "DEADCHAT: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "DEADCHAT: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
//CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -222,7 +221,7 @@
|
||||
|
||||
/proc/log_ghostemote(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_emote))
|
||||
WRITE_LOG(diary, "DEADEMOTE: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "DEADEMOTE: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
//CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -240,11 +239,11 @@
|
||||
|
||||
/proc/log_adminwarn(text)
|
||||
if (CONFIG_GET(flag/log_adminwarn))
|
||||
WRITE_LOG(diary, "ADMINWARN: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "ADMINWARN: [html_decode(text)]")
|
||||
|
||||
/proc/log_pda(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_pda))
|
||||
WRITE_LOG(diary, "PDA: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "PDA: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
//CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -265,26 +264,25 @@
|
||||
|
||||
/proc/log_to_dd(text)
|
||||
to_world_log(text) //this comes before the config check because it can't possibly runtime
|
||||
//if(CONFIG_GET(flag/log_world_output)) // CHOMPRemove
|
||||
// WRITE_LOG(diary, "DD_OUTPUT: [text]") // CHOMPRemove
|
||||
WRITE_LOG(diary, "DD_OUTPUT: [text]")
|
||||
if(CONFIG_GET(flag/log_world_output))
|
||||
WRITE_LOG(GLOB.diary, "DD_OUTPUT: [text]")
|
||||
|
||||
/proc/log_error(text)
|
||||
to_world_log(text)
|
||||
WRITE_LOG(error_log, "RUNTIME: [text]")
|
||||
WRITE_LOG(GLOB.error_log, "RUNTIME: [text]")
|
||||
|
||||
/proc/log_misc(text)
|
||||
WRITE_LOG(diary, "MISC: [text]")
|
||||
WRITE_LOG(GLOB.diary, "MISC: [text]")
|
||||
|
||||
/proc/log_sql(text)
|
||||
WRITE_LOG(sql_error_log, "SQL: [text]")
|
||||
WRITE_LOG(GLOB.sql_error_log, "SQL: [text]")
|
||||
|
||||
/proc/log_query_debug(text)
|
||||
WRITE_LOG(query_debug_log, "SQL: [text]")
|
||||
WRITE_LOG(GLOB.query_debug_log, "SQL: [text]")
|
||||
|
||||
/proc/log_topic(text)
|
||||
if(Debug2)
|
||||
WRITE_LOG(diary, "TOPIC: [text]")
|
||||
if(GLOB.Debug2)
|
||||
WRITE_LOG(GLOB.diary, "TOPIC: [text]")
|
||||
|
||||
/proc/log_unit_test(text)
|
||||
to_world_log("## UNIT_TEST: [text]")
|
||||
@@ -296,7 +294,7 @@
|
||||
#endif
|
||||
|
||||
/proc/log_asset(text)
|
||||
WRITE_LOG(diary, "ASSET: [text]")
|
||||
WRITE_LOG(GLOB.diary, "ASSET: [text]")
|
||||
|
||||
/proc/report_progress(var/progress_message)
|
||||
admin_notice(span_boldannounce("[progress_message]"), R_DEBUG)
|
||||
|
||||
@@ -7,5 +7,5 @@
|
||||
entry += " | DATA: "
|
||||
entry += data
|
||||
|
||||
WRITE_LOG(diary, entry)
|
||||
WRITE_LOG(GLOB.diary, entry)
|
||||
SEND_TEXT(world.log, text)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/proc/log_href(text)
|
||||
//WRITE_LOG(GLOB.world_href_log, "HREF: [text]")
|
||||
WRITE_LOG(href_logfile, "HREF: [text]")
|
||||
WRITE_LOG(GLOB.href_logfile, "HREF: [text]")
|
||||
|
||||
/**
|
||||
* Appends a tgui-related log entry. All arguments are optional.
|
||||
@@ -33,4 +33,4 @@
|
||||
if(message)
|
||||
entry += "\n[message]"
|
||||
//WRITE_LOG(GLOB.tgui_log, entry)
|
||||
WRITE_LOG(diary, entry)
|
||||
WRITE_LOG(GLOB.diary, entry)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/proc/log_nsay(text, inside, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_say))
|
||||
WRITE_LOG(diary, "NSAY (NIF:[inside]): [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "NSAY (NIF:[inside]): [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
//CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
/proc/log_nme(text, inside, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_emote))
|
||||
WRITE_LOG(diary, "NME (NIF:[inside]): [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "NME (NIF:[inside]): [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
//CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
if(!SSdbcore.IsConnected())
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
/proc/log_subtle(text, mob/speaker)
|
||||
if (CONFIG_GET(flag/log_emote))
|
||||
WRITE_LOG(diary, "SUBTLE: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
WRITE_LOG(GLOB.diary, "SUBTLE: [speaker.simple_info_line()]: [html_decode(text)]")
|
||||
//CHOMPEdit Begin
|
||||
if(speaker.client)
|
||||
if(!SSdbcore.IsConnected())
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
else return "unknown"
|
||||
|
||||
/proc/RoundHealth(health)
|
||||
var/list/icon_states = cached_icon_states(ingame_hud_med)
|
||||
var/list/icon_states = cached_icon_states(GLOB.ingame_hud_med)
|
||||
for(var/icon_state in icon_states)
|
||||
if(health >= text2num(icon_state))
|
||||
return icon_state
|
||||
@@ -367,11 +367,11 @@ Proc for attack log creation, because really why not
|
||||
/proc/cached_character_icon(var/mob/desired)
|
||||
var/cachekey = "\ref[desired][desired.real_name]"
|
||||
|
||||
if(cached_character_icons[cachekey])
|
||||
. = cached_character_icons[cachekey]
|
||||
if(GLOB.cached_character_icons[cachekey])
|
||||
. = GLOB.cached_character_icons[cachekey]
|
||||
else
|
||||
. = getCompoundIcon(desired)
|
||||
cached_character_icons[cachekey] = .
|
||||
GLOB.cached_character_icons[cachekey] = .
|
||||
|
||||
/proc/not_has_ooc_text(mob/user)
|
||||
if (CONFIG_GET(flag/allow_metadata) && (!user.client?.prefs?.read_preference(/datum/preference/text/living/ooc_notes) || length(user.client.prefs.read_preference(/datum/preference/text/living/ooc_notes)) < 15))
|
||||
|
||||
@@ -176,7 +176,7 @@ GLOBAL_VAR(syndicate_code_response) //Code response for traitors.
|
||||
var/locations[] = GLOB.teleportlocs.len ? GLOB.teleportlocs : drinks//if null, defaults to drinks instead.
|
||||
|
||||
var/names[] = list()
|
||||
for(var/datum/data/record/t in data_core.general)//Picks from crew manifest.
|
||||
for(var/datum/data/record/t in GLOB.data_core.general)//Picks from crew manifest.
|
||||
names += t.fields["name"]
|
||||
|
||||
var/maxwords = words//Extra var to check for duplicates.
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
* Misc
|
||||
*/
|
||||
|
||||
GLOBAL_LIST_INIT(alphabet_upper, list("A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"))
|
||||
|
||||
/*
|
||||
* SQL sanitization
|
||||
|
||||
@@ -303,7 +303,7 @@ Turf and target are seperate in case you want to teleport some distance from a t
|
||||
|
||||
if(oldname)
|
||||
//update the datacore records! This is goig to be a bit costly.
|
||||
for(var/list/L in list(data_core.general,data_core.medical,data_core.security,data_core.locked))
|
||||
for(var/list/L in list(GLOB.data_core.general, GLOB.data_core.medical, GLOB.data_core.security, GLOB.data_core.locked))
|
||||
for(var/datum/data/record/R in L)
|
||||
if(R.fields["name"] == oldname)
|
||||
R.fields["name"] = newname
|
||||
@@ -1179,8 +1179,8 @@ var/global/list/common_tools = list(
|
||||
if(surface)
|
||||
return surface
|
||||
|
||||
/proc/reverse_direction(var/dir)
|
||||
return global.reverse_dir[dir]
|
||||
/proc/reverse_direction(dir)
|
||||
return GLOB.reverse_dir[dir]
|
||||
|
||||
/*
|
||||
Checks if that loc and dir has a item on the wall
|
||||
|
||||
@@ -45,3 +45,6 @@
|
||||
#define PIXEL_MULTIPLIER WORLD_ICON_SIZE/32 //Needed for the R-UST port
|
||||
|
||||
#define JOINTEXT(X) jointext(X, null)
|
||||
|
||||
#define isbelly(A) istype(A, /obj/belly)
|
||||
#define iscapturecrystal(A) istype(A, /obj/item/capture_crystal)
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
#define isbelly(A) istype(A, /obj/belly)
|
||||
#define iscapturecrystal(A) istype(A, /obj/item/capture_crystal)
|
||||
@@ -40,7 +40,8 @@
|
||||
base.layer = DISPOSAL_LAYER
|
||||
base.plane = PLATING_PLANE
|
||||
base.appearance_flags = PIXEL_SCALE
|
||||
for(var/direction in cardinal)
|
||||
|
||||
for(var/direction in GLOB.cardinal)
|
||||
var/mutable_appearance/dir = new /mutable_appearance(base)
|
||||
dir.dir = direction
|
||||
dir.icon_state = "background_[direction]"
|
||||
|
||||
@@ -106,3 +106,7 @@
|
||||
|
||||
/datum/config_entry/string/alert_desc_delta
|
||||
default = "The station's self-destruct mechanism has been engaged. All crew are instructed to obey all instructions given by heads of staff. Any violations of these orders can be punished by death. This is not a drill."
|
||||
|
||||
// Amount of time that must pass between a player dying as a mouse and repawning as a mouse. In minutes.
|
||||
/datum/config_entry/number/mouse_respawn_time
|
||||
default = 2.5
|
||||
|
||||
@@ -136,7 +136,7 @@ var/global/datum/emergency_shuttle_controller/emergency_shuttle = new
|
||||
priority_announcement.Announce(using_map.shuttle_recall_message)
|
||||
|
||||
/datum/emergency_shuttle_controller/proc/can_call()
|
||||
if (!universe.OnShuttleCall(null))
|
||||
if (!GLOB.universe.OnShuttleCall(null))
|
||||
return 0
|
||||
if (deny_shuttle)
|
||||
return 0
|
||||
|
||||
@@ -78,7 +78,7 @@ SUBSYSTEM_DEF(atc)
|
||||
|
||||
/datum/controller/subsystem/atc/proc/msg(var/message,var/sender)
|
||||
ASSERT(message)
|
||||
global_announcer.autosay("[message]", sender ? sender : "[using_map.dock_name] Control")
|
||||
GLOB.global_announcer.autosay("[message]", sender ? sender : "[using_map.dock_name] Control")
|
||||
|
||||
/datum/controller/subsystem/atc/proc/is_squelched()
|
||||
return squelched
|
||||
|
||||
@@ -93,7 +93,7 @@ SUBSYSTEM_DEF(appreciation)
|
||||
|
||||
/datum/controller/subsystem/appreciation/proc/msg(var/message,var/sender)
|
||||
ASSERT(message)
|
||||
global_announcer.autosay("[message]", sender ? sender : "Cultural Awareness")
|
||||
GLOB.global_announcer.autosay("[message]", sender ? sender : "Cultural Awareness")
|
||||
|
||||
/datum/controller/subsystem/appreciation/proc/is_squelched()
|
||||
return squelched
|
||||
|
||||
@@ -126,7 +126,7 @@ SUBSYSTEM_DEF(atoms)
|
||||
/datum/controller/subsystem/atoms/Shutdown()
|
||||
var/initlog = InitLog()
|
||||
if(initlog)
|
||||
text2file(initlog, "[log_path]-initialize.log")
|
||||
text2file(initlog, "[GLOB.log_directory]-initialize.log")
|
||||
|
||||
#undef BAD_INIT_QDEL_BEFORE
|
||||
#undef BAD_INIT_DIDNT_INIT
|
||||
|
||||
@@ -42,7 +42,7 @@ SUBSYSTEM_DEF(game_master)
|
||||
adjust_staleness(1)
|
||||
adjust_danger(-1)
|
||||
|
||||
var/global_afk = metric.assess_all_living_mobs()
|
||||
var/global_afk = GLOB.metric.assess_all_living_mobs()
|
||||
global_afk = abs(global_afk - 100)
|
||||
global_afk = round(global_afk / 100, 0.1)
|
||||
adjust_staleness(global_afk) // Staleness increases faster if more people are less active.
|
||||
@@ -214,22 +214,22 @@ SUBSYSTEM_DEF(game_master)
|
||||
|
||||
dat += "<tr>"
|
||||
dat += "<td>All Living Mobs</td>"
|
||||
dat += "<td>[metric.assess_all_living_mobs()]%</td>"
|
||||
dat += "<td>[GLOB.metric.assess_all_living_mobs()]%</td>"
|
||||
dat += "</tr>"
|
||||
|
||||
dat += "<tr>"
|
||||
dat += "<td>All Ghosts</td>"
|
||||
dat += "<td>[metric.assess_all_dead_mobs()]%</td>"
|
||||
dat += "<td>[GLOB.metric.assess_all_dead_mobs()]%</td>"
|
||||
dat += "</tr>"
|
||||
|
||||
dat += "<tr>"
|
||||
dat += "<th colspan='2'>Departments</td>"
|
||||
dat += "</tr>"
|
||||
|
||||
for(var/D in metric.departments)
|
||||
for(var/D in GLOB.metric.departments)
|
||||
dat += "<tr>"
|
||||
dat += "<td>[D]</td>"
|
||||
dat += "<td>[metric.assess_department(D)]%</td>"
|
||||
dat += "<td>[GLOB.metric.assess_department(D)]%</td>"
|
||||
dat += "</tr>"
|
||||
|
||||
dat += "<tr>"
|
||||
@@ -239,7 +239,7 @@ SUBSYSTEM_DEF(game_master)
|
||||
for(var/mob/M as anything in player_list)
|
||||
dat += "<tr>"
|
||||
dat += "<td>[M] ([M.ckey])</td>"
|
||||
dat += "<td>[metric.assess_player_activity(M)]%</td>"
|
||||
dat += "<td>[GLOB.metric.assess_player_activity(M)]%</td>"
|
||||
dat += "</tr>"
|
||||
dat += "</table>"
|
||||
|
||||
|
||||
@@ -19,6 +19,6 @@ SUBSYSTEM_DEF(holomaps)
|
||||
return SS_INIT_SUCCESS
|
||||
|
||||
/datum/controller/subsystem/holomaps/stat_entry(msg)
|
||||
if (!Debug2)
|
||||
if (!GLOB.Debug2)
|
||||
return // Only show up in stat panel if debugging is enabled.
|
||||
return ..() //CHOMPEdit
|
||||
|
||||
@@ -41,7 +41,7 @@ SUBSYSTEM_DEF(inactivity)
|
||||
if(isAI(C.mob))
|
||||
var/mob/living/silicon/ai/A = C.mob
|
||||
GLOB.empty_playable_ai_cores += new /obj/structure/AIcore/deactivated(A.loc)
|
||||
global_announcer.autosay("[A] has been moved to intelligence storage.", "Artificial Intelligence Oversight")
|
||||
GLOB.global_announcer.autosay("[A] has been moved to intelligence storage.", "Artificial Intelligence Oversight")
|
||||
A.clear_client()
|
||||
information = " while an AI."
|
||||
|
||||
|
||||
@@ -168,7 +168,7 @@ SUBSYSTEM_DEF(mapping)
|
||||
// VOREStation Edit End: Re-enable this
|
||||
|
||||
/datum/controller/subsystem/mapping/stat_entry(msg)
|
||||
if (!Debug2)
|
||||
if (!GLOB.Debug2)
|
||||
return // Only show up in stat panel if debugging is enabled.
|
||||
return ..() //CHOMPEdit
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ SUBSYSTEM_DEF(motiontracker)
|
||||
if(!prob(hear_chance))
|
||||
return
|
||||
if(hear_chance <= 40)
|
||||
T = get_step(T,pick(cardinal))
|
||||
T = get_step(T,pick(GLOB.cardinal))
|
||||
if(!T) // incase...
|
||||
return
|
||||
// Echo time, we have a turf
|
||||
|
||||
@@ -7,7 +7,7 @@ SUBSYSTEM_DEF(overlays)
|
||||
stats = list()
|
||||
|
||||
/datum/controller/subsystem/overlays/Shutdown()
|
||||
WRITE_LOG("[log_path]-overlay.log", render_stats(stats))
|
||||
WRITE_LOG("[GLOB.log_directory]-overlay.log", render_stats(stats))
|
||||
|
||||
/datum/controller/subsystem/overlays/Recover()
|
||||
stats = SSoverlays.stats
|
||||
|
||||
@@ -64,7 +64,7 @@ SUBSYSTEM_DEF(skybox)
|
||||
speedspace_cache["EW_[i]"] = MA
|
||||
|
||||
//Over-the-edge images
|
||||
for (var/dir in alldirs)
|
||||
for (var/dir in GLOB.alldirs)
|
||||
var/mutable_appearance/MA = new(normal_space)
|
||||
var/matrix/M = matrix()
|
||||
var/horizontal = (dir & (WEST|EAST))
|
||||
|
||||
@@ -13,7 +13,7 @@ SUBSYSTEM_DEF(ticker)
|
||||
var/current_state = GAME_STATE_INIT // We aren't even at pregame yet // TODO replace with CURRENT_GAME_STATE
|
||||
|
||||
/* Relies upon the following globals (TODO move those in here) */
|
||||
// var/master_mode = "extended" //The underlying game mode (so "secret" or the voted mode).
|
||||
// var/GLOB.master_mode = "extended" //The underlying game mode (so "secret" or the voted mode).
|
||||
// Set by SSvote when VOTE_GAMEMODE finishes.
|
||||
// var/round_progressing = 1 //Whether the lobby clock is ticking down.
|
||||
|
||||
@@ -84,7 +84,7 @@ var/global/datum/controller/subsystem/ticker/ticker
|
||||
|
||||
// Called during GAME_STATE_PREGAME (RUNLEVEL_LOBBY)
|
||||
/datum/controller/subsystem/ticker/proc/pregame_tick()
|
||||
if(round_progressing && last_fire)
|
||||
if(GLOB.round_progressing && last_fire)
|
||||
pregame_timeleft -= (world.time - last_fire) / (1 SECOND)
|
||||
|
||||
if(start_immediately)
|
||||
@@ -122,23 +122,23 @@ var/global/datum/controller/subsystem/ticker/ticker
|
||||
// Returns 0 if failed to pick a mode, otherwise 1
|
||||
/datum/controller/subsystem/ticker/proc/setup_choose_gamemode()
|
||||
//Create and announce mode
|
||||
if(master_mode == "secret")
|
||||
if(GLOB.master_mode == "secret")
|
||||
src.hide_mode = TRUE
|
||||
|
||||
var/list/runnable_modes = config.get_runnable_modes()
|
||||
if((master_mode == "random") || (master_mode == "secret"))
|
||||
if((GLOB.master_mode == "random") || (GLOB.master_mode == "secret"))
|
||||
if(!runnable_modes.len)
|
||||
to_world(span_filter_system(span_bold("Unable to choose playable game mode.") + " Reverting to pregame lobby."))
|
||||
return 0
|
||||
if(secret_force_mode != "secret")
|
||||
src.mode = config.pick_mode(secret_force_mode)
|
||||
if(GLOB.secret_force_mode != "secret")
|
||||
src.mode = config.pick_mode(GLOB.secret_force_mode)
|
||||
if(!src.mode)
|
||||
var/list/weighted_modes = list()
|
||||
for(var/datum/game_mode/GM in runnable_modes)
|
||||
weighted_modes[GM.config_tag] = CONFIG_GET(keyed_list/probabilities)[GM.config_tag]
|
||||
src.mode = config.gamemode_cache[pickweight(weighted_modes)]
|
||||
else
|
||||
src.mode = config.pick_mode(master_mode)
|
||||
src.mode = config.pick_mode(GLOB.master_mode)
|
||||
|
||||
if(!src.mode)
|
||||
to_world(span_boldannounce("Serious error in mode setup! Reverting to pregame lobby.")) //Uses setup instead of set up due to computational context.
|
||||
@@ -427,7 +427,7 @@ var/global/datum/controller/subsystem/ticker/ticker
|
||||
|
||||
// If they're a carbon, they can get manifested
|
||||
if(J?.mob_type & JOB_CARBON)
|
||||
data_core.manifest_inject(new_char)
|
||||
GLOB.data_core.manifest_inject(new_char)
|
||||
|
||||
/datum/controller/subsystem/ticker/proc/collect_minds()
|
||||
for(var/mob/living/player in player_list)
|
||||
@@ -555,7 +555,7 @@ var/global/datum/controller/subsystem/ticker/ticker
|
||||
if(GAME_STATE_INIT)
|
||||
..()
|
||||
if(GAME_STATE_PREGAME) // RUNLEVEL_LOBBY
|
||||
msg = "START [round_progressing ? "[round(pregame_timeleft)]s" : "(PAUSED)"]"
|
||||
msg = "START [GLOB.round_progressing ? "[round(pregame_timeleft)]s" : "(PAUSED)"]"
|
||||
if(GAME_STATE_SETTING_UP) // RUNLEVEL_SETUP
|
||||
msg = "SETUP"
|
||||
if(GAME_STATE_PLAYING) // RUNLEVEL_GAME
|
||||
|
||||
@@ -83,11 +83,6 @@ SUBSYSTEM_DEF(title)
|
||||
file_path = SStitle.file_path
|
||||
previous_icon = SStitle.previous_icon
|
||||
|
||||
|
||||
//Following is related to jank required to get stuff to render for new players
|
||||
|
||||
GLOBAL_LIST_EMPTY(newplayer_start)
|
||||
|
||||
// Must be immediate because players will
|
||||
// join before SSatom initializes everything.
|
||||
INITIALIZE_IMMEDIATE(/obj/effect/landmark/start/new_player)
|
||||
|
||||
@@ -260,9 +260,9 @@ SUBSYSTEM_DEF(transcore)
|
||||
var/datum/transcore_db/db = SStranscore.db_by_mind_name(MR.mindname)
|
||||
var/datum/transhuman/body_record/BR = db.body_scans[MR.mindname]
|
||||
if(!BR)
|
||||
global_announcer.autosay("[MR.mindname] is past-due for a mind backup, but lacks a corresponding body record.", "TransCore Oversight", "Medical")
|
||||
GLOB.global_announcer.autosay("[MR.mindname] is past-due for a mind backup, but lacks a corresponding body record.", "TransCore Oversight", "Medical")
|
||||
return
|
||||
global_announcer.autosay("[MR.mindname] is past-due for a mind backup.", "TransCore Oversight", BR.synthetic ? "Science" : "Medical")
|
||||
GLOB.global_announcer.autosay("[MR.mindname] is past-due for a mind backup.", "TransCore Oversight", BR.synthetic ? "Science" : "Medical")
|
||||
|
||||
// Called from mind_record to add itself to the transcore.
|
||||
/datum/transcore_db/proc/add_backup(var/datum/transhuman/mind_record/MR)
|
||||
@@ -297,8 +297,8 @@ SUBSYSTEM_DEF(transcore)
|
||||
// Moves all mind records from the databaes into the disk and shuts down all backup canary processing.
|
||||
/datum/transcore_db/proc/core_dump(var/obj/item/disk/transcore/disk)
|
||||
ASSERT(disk)
|
||||
global_announcer.autosay("An emergency core dump has been initiated!", "TransCore Oversight", "Command")
|
||||
global_announcer.autosay("An emergency core dump has been initiated!", "TransCore Oversight", "Medical")
|
||||
GLOB.global_announcer.autosay("An emergency core dump has been initiated!", "TransCore Oversight", "Command")
|
||||
GLOB.global_announcer.autosay("An emergency core dump has been initiated!", "TransCore Oversight", "Medical")
|
||||
|
||||
disk.stored += backed_up
|
||||
backed_up.Cut()
|
||||
|
||||
@@ -98,10 +98,10 @@ SUBSYSTEM_DEF(vote)
|
||||
if(choices["Continue Playing"] >= greatest_votes)
|
||||
greatest_votes = choices["Continue Playing"]
|
||||
else if(mode == VOTE_GAMEMODE)
|
||||
if(master_mode in choices)
|
||||
choices[master_mode] += non_voters
|
||||
if(choices[master_mode] >= greatest_votes)
|
||||
greatest_votes = choices[master_mode]
|
||||
if(GLOB.master_mode in choices)
|
||||
choices[GLOB.master_mode] += non_voters
|
||||
if(choices[GLOB.master_mode] >= greatest_votes)
|
||||
greatest_votes = choices[GLOB.master_mode]
|
||||
else if(mode == VOTE_CREW_TRANSFER)
|
||||
var/factor = 0.5
|
||||
switch(world.time / (10 * 60)) // minutes
|
||||
@@ -162,12 +162,12 @@ SUBSYSTEM_DEF(vote)
|
||||
if(. == "Restart Round")
|
||||
restart = 1
|
||||
if(VOTE_GAMEMODE)
|
||||
if(master_mode != .)
|
||||
if(GLOB.master_mode != .)
|
||||
world.save_mode(.)
|
||||
if(ticker && ticker.mode)
|
||||
restart = 1
|
||||
else
|
||||
master_mode = .
|
||||
GLOB.master_mode = .
|
||||
if(VOTE_CREW_TRANSFER)
|
||||
if(. == "Initiate Crew Transfer")
|
||||
init_shift_change(null, 1)
|
||||
|
||||
@@ -30,7 +30,7 @@ SUBSYSTEM_DEF(xenoarch)
|
||||
digsite_spawning_turfs = SSxenoarch.digsite_spawning_turfs
|
||||
|
||||
/datum/controller/subsystem/xenoarch/stat_entry(msg)
|
||||
if (!Debug2)
|
||||
if (!GLOB.Debug2)
|
||||
return // Only show up in stat panel if debugging is enabled.
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -440,7 +440,7 @@
|
||||
/datum/component/overlay_lighting/proc/cast_directional_light()
|
||||
var/final_distance = cast_range
|
||||
|
||||
//Lower the distance by 1 if we're not looking at a cardinal direction, and we're not a short cast
|
||||
//Lower the distance by 1 if we're not looking at a GLOB.cardinal direction, and we're not a short cast
|
||||
if(final_distance > SHORT_CAST && !(ALL_CARDINALS & current_direction))
|
||||
final_distance -= 1
|
||||
var/turf/scanning = get_turf(current_holder)
|
||||
@@ -448,7 +448,7 @@
|
||||
. = 0
|
||||
for(var/i in 1 to final_distance)
|
||||
var/turf/next_turf = get_step(scanning, current_direction)
|
||||
if(isnull(next_turf) || IS_OPAQUE_TURF_DIR(next_turf, reverse_dir[current_direction]))
|
||||
if(isnull(next_turf) || IS_OPAQUE_TURF_DIR(next_turf, GLOB.reverse_dir[current_direction]))
|
||||
break
|
||||
scanning = next_turf
|
||||
.++
|
||||
@@ -460,7 +460,7 @@
|
||||
/datum/component/overlay_lighting/proc/place_directional_light(turf/target)
|
||||
var/final_distance = round(cast_range*2)
|
||||
|
||||
//Lower the distance by 1 if we're not looking at a cardinal direction, and we're not a short cast
|
||||
//Lower the distance by 1 if we're not looking at a GLOB.cardinal direction, and we're not a short cast
|
||||
if(final_distance > SHORT_CAST && !(ALL_CARDINALS & get_dir(GET_PARENT, target)))
|
||||
final_distance -= 1
|
||||
var/turf/scanning = get_turf(GET_PARENT)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
|
||||
/hook/startup/proc/createDatacore()
|
||||
data_core = new /datum/datacore()
|
||||
GLOB.data_core = new /datum/datacore()
|
||||
return 1
|
||||
|
||||
/datum/datacore
|
||||
@@ -40,12 +40,12 @@
|
||||
.manifest tr.alt td {[monochrome?"border-top-width: 2px":"background-color: [OOC?"#373737; color:white":"#DEF"]"]}
|
||||
</style></head>
|
||||
<table class="manifest" width='350px'>
|
||||
[snowflake?"<tr><th colspan=3 style = \"background-color: #026e6a\"><b>Online players:</b> [TGS_CLIENT_COUNT]</th></tr><tr><th colspan=3 style = \"background-color: #027a76\"><b>Crew members:</b> [data_core.general.len]</th></tr><tr class='head'>":""]
|
||||
[snowflake?"<tr><th colspan=3 style = \"background-color: #026e6a\"><b>Online players:</b> [TGS_CLIENT_COUNT]</th></tr><tr><th colspan=3 style = \"background-color: #027a76\"><b>Crew members:</b> [GLOB.data_core.general.len]</th></tr><tr class='head'>":""]
|
||||
<tr class='head'><th>Name</th><th>Rank</th><th>Activity</th></tr>
|
||||
"} //Also a chompstation edit with the snowflake stuff on line 43
|
||||
var/even = 0
|
||||
// sort mobs
|
||||
for(var/datum/data/record/t in data_core.general)
|
||||
for(var/datum/data/record/t in GLOB.data_core.general)
|
||||
var/name = t.fields["name"]
|
||||
var/rank = t.fields["rank"]
|
||||
var/real_rank = make_list_rank(t.fields["real_rank"])
|
||||
@@ -207,7 +207,7 @@ GLOBAL_LIST_EMPTY(PDA_Manifest)
|
||||
var/list/civ = list()
|
||||
var/list/bot = list()
|
||||
var/list/misc = list()
|
||||
for(var/datum/data/record/t in data_core.general)
|
||||
for(var/datum/data/record/t in GLOB.data_core.general)
|
||||
var/name = sanitize(t.fields["name"])
|
||||
var/rank = sanitize(t.fields["rank"])
|
||||
var/real_rank = make_list_rank(t.fields["real_rank"])
|
||||
@@ -307,7 +307,7 @@ GLOBAL_LIST_EMPTY(PDA_Manifest)
|
||||
var/datum/data/record/foundrecord
|
||||
var/real_title = assignment
|
||||
|
||||
for(var/datum/data/record/t in data_core.general)
|
||||
for(var/datum/data/record/t in GLOB.data_core.general)
|
||||
if (t)
|
||||
if(t.fields["name"] == name)
|
||||
foundrecord = t
|
||||
@@ -540,13 +540,13 @@ GLOBAL_LIST_EMPTY(PDA_Manifest)
|
||||
GLOB.PDA_Manifest.Cut()
|
||||
|
||||
/proc/find_general_record(field, value)
|
||||
return find_record(field, value, data_core.general)
|
||||
return find_record(field, value, GLOB.data_core.general)
|
||||
|
||||
/proc/find_medical_record(field, value)
|
||||
return find_record(field, value, data_core.medical)
|
||||
return find_record(field, value, GLOB.data_core.medical)
|
||||
|
||||
/proc/find_security_record(field, value)
|
||||
return find_record(field, value, data_core.security)
|
||||
return find_record(field, value, GLOB.data_core.security)
|
||||
|
||||
/proc/find_record(field, value, list/L)
|
||||
for(var/datum/data/record/R in L)
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
DD.start_cure_timer()
|
||||
viruses += DD
|
||||
DD.affected_mob = src
|
||||
active_diseases += DD
|
||||
GLOB.active_diseases += DD
|
||||
|
||||
var/list/skipped = list("affected_mob", "holder", "carrier", "stage", "type", "parent_type", "vars", "transformed")
|
||||
if(respect_carrier)
|
||||
|
||||
@@ -46,7 +46,7 @@ GLOBAL_LIST_INIT(diseases, subtypesof(/datum/disease))
|
||||
|
||||
/datum/disease/Destroy()
|
||||
affected_mob = null
|
||||
active_diseases.Remove(src)
|
||||
GLOB.active_diseases.Remove(src)
|
||||
if(processing)
|
||||
End()
|
||||
return ..()
|
||||
|
||||
@@ -376,7 +376,7 @@ GLOBAL_LIST_INIT(advance_cures, list(
|
||||
D.AssignName(new_name)
|
||||
D.Refresh()
|
||||
|
||||
for(var/datum/disease/advance/AD in active_diseases)
|
||||
for(var/datum/disease/advance/AD in GLOB.active_diseases)
|
||||
AD.Refresh()
|
||||
|
||||
H = tgui_input_list(usr, "Choose infectee", "Infectees", human_mob_list)
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
/datum/game_master/default/choose_event()
|
||||
log_game_master("Now starting event decision.")
|
||||
|
||||
var/list/most_active_departments = metric.assess_all_departments(3, list(last_department_used))
|
||||
var/list/most_active_departments = GLOB.metric.assess_all_departments(3, list(last_department_used))
|
||||
var/list/best_events = decide_best_events(most_active_departments)
|
||||
|
||||
if(LAZYLEN(best_events))
|
||||
|
||||
@@ -26,21 +26,16 @@
|
||||
// Mostly used for data_core records, but unfortuantely used some other places too. But mostly here, so lets make a good effort.
|
||||
// TODO - Some machines/computers might be holding references to us. Lets look into that, but at least for now lets make sure that the manifest is cleaned up.
|
||||
/datum/data/record/Destroy(var/force)
|
||||
if(data_core.locked.Find(src))
|
||||
if(GLOB.data_core.locked.Find(src))
|
||||
if(!force)
|
||||
stack_trace("Someone tried to qdel a record that was in data_core.locked [log_info_line(src)]")
|
||||
stack_trace("Someone tried to qdel a record that was in GLOB.data_core.locked [log_info_line(src)]")
|
||||
return QDEL_HINT_LETMELIVE
|
||||
data_core.locked -= src
|
||||
data_core.medical -= src
|
||||
data_core.general -= src
|
||||
data_core.security -= src
|
||||
GLOB.data_core.locked -= src
|
||||
GLOB.data_core.medical -= src
|
||||
GLOB.data_core.general -= src
|
||||
GLOB.data_core.security -= src
|
||||
. = ..()
|
||||
|
||||
/datum/data/text
|
||||
name = "text"
|
||||
var/data = null
|
||||
|
||||
|
||||
|
||||
/datum/debug
|
||||
var/list/debuglist
|
||||
|
||||
@@ -21,13 +21,13 @@ var/list/modules = list( // global associative list
|
||||
|
||||
var/type = O.type // the type of the creating object
|
||||
|
||||
var/mneed = mods.inmodlist(type) // find if this type has modules defined
|
||||
var/mneed = GLOB.mods.inmodlist(type) // find if this type has modules defined
|
||||
|
||||
if(!mneed) // not found in module list?
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
var/needed = mods.getbitmask(type) // get a bitmask for the number of modules in this object
|
||||
var/needed = GLOB.mods.getbitmask(type) // get a bitmask for the number of modules in this object
|
||||
status = needed
|
||||
installed = needed
|
||||
|
||||
|
||||
@@ -41,11 +41,11 @@
|
||||
var/obj/item/card/id/I = user.GetIdCard()
|
||||
var/datum/data/record/random_general_record
|
||||
var/datum/data/record/random_medical_record
|
||||
if(data_core.general.len)
|
||||
random_general_record = pick(data_core.general)
|
||||
if(GLOB.data_core.general.len)
|
||||
random_general_record = pick(GLOB.data_core.general)
|
||||
random_medical_record = find_medical_record("id", random_general_record.fields["id"])
|
||||
|
||||
var/datum/data/record/general = data_core.CreateGeneralRecord(user)
|
||||
var/datum/data/record/general = GLOB.data_core.CreateGeneralRecord(user)
|
||||
if(I)
|
||||
general.fields["age"] = I.age
|
||||
general.fields["rank"] = I.assignment
|
||||
@@ -66,8 +66,8 @@
|
||||
general.fields["sex"] = capitalize(user.gender)
|
||||
|
||||
general.fields["species"] = user.get_species()
|
||||
var/datum/data/record/medical = data_core.CreateMedicalRecord(general.fields["name"], general.fields["id"])
|
||||
data_core.CreateSecurityRecord(general.fields["name"], general.fields["id"])
|
||||
var/datum/data/record/medical = GLOB.data_core.CreateMedicalRecord(general.fields["name"], general.fields["id"])
|
||||
GLOB.data_core.CreateSecurityRecord(general.fields["name"], general.fields["id"])
|
||||
|
||||
if(!random_general_record)
|
||||
general.fields["citizenship"] = random_general_record.fields["citizenship"]
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
/obj/structure/signpost/attack_hand(mob/user as mob)
|
||||
if(tgui_alert(user, "Travel back to ss13?","Return?",list("Yes","No")) == "Yes")
|
||||
if(user.z != src.z) return
|
||||
user.forceMove(get_turf(pick(latejoin)))
|
||||
user.forceMove(get_turf(pick(GLOB.latejoin)))
|
||||
|
||||
/obj/structure/signpost_fake
|
||||
icon = 'icons/obj/stationobjs.dmi'
|
||||
|
||||
@@ -86,13 +86,13 @@
|
||||
to_chat(M, command)
|
||||
|
||||
/datum/announcement/priority/Message(var/message as text, var/message_title as text, var/list/zlevels)
|
||||
global_announcer.autosay(span_alert("[message_title]:") + " [message]", announcer ? announcer : ANNOUNCER_NAME, channel = "Common", zlevels = zlevels)
|
||||
GLOB.global_announcer.autosay(span_alert("[message_title]:") + " [message]", announcer ? announcer : ANNOUNCER_NAME, channel = "Common", zlevels = zlevels)
|
||||
|
||||
/datum/announcement/priority/command/Message(var/message as text, var/message_title as text, var/list/zlevels)
|
||||
global_announcer.autosay(span_alert("[command_name()] - [message_title]:") + " [message]", ANNOUNCER_NAME, channel = "Common", zlevels = zlevels)
|
||||
GLOB.global_announcer.autosay(span_alert("[command_name()] - [message_title]:") + " [message]", ANNOUNCER_NAME, channel = "Common", zlevels = zlevels)
|
||||
|
||||
/datum/announcement/priority/security/Message(var/message as text, var/message_title as text, var/list/zlevels)
|
||||
global_announcer.autosay(span_alert("[message_title]:") + " [message]", ANNOUNCER_NAME, channel = "Common", zlevels = zlevels)
|
||||
GLOB.global_announcer.autosay(span_alert("[message_title]:") + " [message]", ANNOUNCER_NAME, channel = "Common", zlevels = zlevels)
|
||||
|
||||
/datum/announcement/proc/NewsCast(var/message as text, var/message_title as text)
|
||||
if(!newscast)
|
||||
@@ -142,4 +142,4 @@
|
||||
AnnounceArrivalSimple(character.real_name, rank, join_message, channel, zlevels)
|
||||
|
||||
/proc/AnnounceArrivalSimple(var/name, var/rank = "visitor", var/join_message = "will arrive at the station shortly", var/channel = "Common", var/list/zlevels)
|
||||
global_announcer.autosay("[name], [rank], [join_message].", "Arrivals Announcement Computer", channel, zlevels)
|
||||
GLOB.global_announcer.autosay("[name], [rank], [join_message].", "Arrivals Announcement Computer", channel, zlevels)
|
||||
|
||||
@@ -67,7 +67,7 @@ var/datum/antagonist/borer/borers
|
||||
|
||||
/datum/antagonist/borer/proc/get_vents()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in machines)
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in GLOB.machines)
|
||||
if(!temp_vent.welded && temp_vent.network && (temp_vent.loc.z in using_map.station_levels))
|
||||
if(temp_vent.network.normal_members.len > 50)
|
||||
vents += temp_vent
|
||||
|
||||
@@ -31,7 +31,7 @@ var/datum/antagonist/xenos/xenomorphs
|
||||
|
||||
/datum/antagonist/xenos/proc/get_vents()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in machines)
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in GLOB.machines)
|
||||
if(!temp_vent.welded && temp_vent.network && (temp_vent.loc.z in using_map.station_levels))
|
||||
if(temp_vent.network.normal_members.len > 50)
|
||||
vents += temp_vent
|
||||
|
||||
@@ -94,10 +94,10 @@
|
||||
if(CONFIG_GET(flag/protect_roles_from_antagonist))
|
||||
restricted_jobs |= protected_jobs
|
||||
if(antaghud_indicator)
|
||||
if(!hud_icon_reference)
|
||||
hud_icon_reference = list()
|
||||
if(role_text) hud_icon_reference[role_text] = antaghud_indicator
|
||||
if(faction_role_text) hud_icon_reference[faction_role_text] = antaghud_indicator
|
||||
if(!GLOB.hud_icon_reference)
|
||||
GLOB.hud_icon_reference = list()
|
||||
if(role_text) GLOB.hud_icon_reference[role_text] = antaghud_indicator
|
||||
if(faction_role_text) GLOB.hud_icon_reference[faction_role_text] = antaghud_indicator
|
||||
|
||||
/datum/antagonist/proc/tick()
|
||||
return 1
|
||||
|
||||
@@ -509,12 +509,12 @@
|
||||
R.reagents.splash(src, 1)
|
||||
|
||||
/atom/proc/get_global_map_pos()
|
||||
if(!islist(global_map) || isemptylist(global_map)) return
|
||||
if(!islist(GLOB.global_map) || isemptylist(GLOB.global_map)) return
|
||||
var/cur_x = null
|
||||
var/cur_y = null
|
||||
var/list/y_arr = null
|
||||
for(cur_x=1,cur_x<=global_map.len,cur_x++)
|
||||
y_arr = global_map[cur_x]
|
||||
for(cur_x = 1, cur_x <= GLOB.global_map.len, cur_x++)
|
||||
y_arr = GLOB.global_map[cur_x]
|
||||
cur_y = y_arr.Find(src.z)
|
||||
if(cur_y)
|
||||
break
|
||||
|
||||
@@ -107,7 +107,7 @@
|
||||
if(loc != newloc)
|
||||
if(!direct)
|
||||
direct = get_dir(oldloc, newloc)
|
||||
if (IS_CARDINAL(direct)) //Cardinal move
|
||||
if (IS_CARDINAL(direct)) //GLOB.cardinal move
|
||||
// Track our failure if any in this value
|
||||
. = TRUE
|
||||
|
||||
@@ -167,7 +167,7 @@
|
||||
else if(. && newloc)
|
||||
. = doMove(newloc)
|
||||
|
||||
//Diagonal move, split it into cardinal moves
|
||||
//Diagonal move, split it into GLOB.cardinal moves
|
||||
else
|
||||
moving_diagonally = FIRST_DIAG_STEP
|
||||
var/first_step_dir
|
||||
|
||||
@@ -521,7 +521,6 @@ GLOBAL_LIST_EMPTY_TYPED(dna_genes_bad, /datum/gene/trait)
|
||||
ResetSE()
|
||||
|
||||
unique_enzymes = md5(character.real_name)
|
||||
reg_dna[unique_enzymes] = character.real_name
|
||||
|
||||
#undef DNA_OFF_LOWERBOUND
|
||||
#undef DNA_OFF_UPPERBOUND
|
||||
|
||||
@@ -227,7 +227,7 @@
|
||||
WC.forceMove(get_turf(src))
|
||||
occupant = null
|
||||
// Disconnect from our terminal
|
||||
for(var/dirfind in cardinal)
|
||||
for(var/dirfind in GLOB.cardinal)
|
||||
var/obj/machinery/computer/scan_consolenew/console = locate(/obj/machinery/computer/scan_consolenew, get_step(src, dirfind))
|
||||
if(console && console.connected == src)
|
||||
console.connected = null
|
||||
@@ -368,7 +368,7 @@
|
||||
R.mydna.dna.ResetSE()
|
||||
buffers[i+1]=R
|
||||
// Traitgenes don't alter direction of computer as this scans for neighbour
|
||||
for(var/dirfind in cardinal)
|
||||
for(var/dirfind in GLOB.cardinal)
|
||||
connected = locate(/obj/machinery/dna_scannernew, get_step(src, dirfind))
|
||||
if(connected)
|
||||
break
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
to_chat(user, span_critical("The blade hisses, forcing itself from your manipulators. \The [src] will only allow mortals to wield it against foes, not kin."))
|
||||
|
||||
user.drop_from_inventory(src, src.loc)
|
||||
throw_at(get_edge_target_turf(src, pick(alldirs)), rand(1,3), throw_speed)
|
||||
throw_at(get_edge_target_turf(src, pick(GLOB.alldirs)), rand(1,3), throw_speed)
|
||||
|
||||
var/spooky = pick('sound/hallucinations/growl1.ogg', 'sound/hallucinations/growl2.ogg', 'sound/hallucinations/growl3.ogg', 'sound/hallucinations/wail.ogg')
|
||||
playsound(src, spooky, 50, 1)
|
||||
|
||||
@@ -73,7 +73,7 @@ In short:
|
||||
if(!T.holy && prob(1))
|
||||
new /obj/effect/gateway/active/cult(T)
|
||||
|
||||
for (var/obj/machinery/firealarm/alm in machines)
|
||||
for (var/obj/machinery/firealarm/alm in GLOB.machines)
|
||||
if (!(alm.stat & BROKEN))
|
||||
alm.ex_act(2)
|
||||
|
||||
|
||||
@@ -101,7 +101,7 @@ var/global/list/narsie_list = list()
|
||||
if(!move_self)
|
||||
return 0
|
||||
|
||||
var/movement_dir = pick(alldirs - last_failed_movement)
|
||||
var/movement_dir = pick(GLOB.alldirs - last_failed_movement)
|
||||
|
||||
if(force_move)
|
||||
movement_dir = force_move
|
||||
@@ -119,7 +119,7 @@ var/global/list/narsie_list = list()
|
||||
if(!move_self)
|
||||
return 0
|
||||
|
||||
var/movement_dir = pick(alldirs - last_failed_movement)
|
||||
var/movement_dir = pick(GLOB.alldirs - last_failed_movement)
|
||||
|
||||
if(force_move)
|
||||
movement_dir = force_move
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
|
||||
/proc/SetUniversalState(var/newstate,var/on_exit=1, var/on_enter=1)
|
||||
if(on_exit)
|
||||
universe.OnExit()
|
||||
universe = new newstate
|
||||
GLOB.universe.OnExit()
|
||||
GLOB.universe = new newstate
|
||||
if(on_enter)
|
||||
universe.OnEnter()
|
||||
GLOB.universe.OnEnter()
|
||||
|
||||
@@ -72,7 +72,7 @@ GLOBAL_VAR_INIT(universe_has_ended, 0)
|
||||
"}
|
||||
priority_announcement.Announce(txt,"SUPERMATTER CASCADE DETECTED")
|
||||
|
||||
for(var/obj/machinery/computer/shuttle_control/C in machines)
|
||||
for(var/obj/machinery/computer/shuttle_control/C in GLOB.machines)
|
||||
if(istype(C, /obj/machinery/computer/shuttle_control/research) || istype(C, /obj/machinery/computer/shuttle_control/mining))
|
||||
C.req_access = list()
|
||||
C.req_one_access = list()
|
||||
@@ -103,7 +103,7 @@ GLOBAL_VAR_INIT(universe_has_ended, 0)
|
||||
OnTurfChange(T)
|
||||
*/
|
||||
/datum/universal_state/supermatter_cascade/proc/MiscSet()
|
||||
for (var/obj/machinery/firealarm/alm in machines)
|
||||
for (var/obj/machinery/firealarm/alm in GLOB.machines)
|
||||
if (!(alm.stat & BROKEN))
|
||||
alm.ex_act(2)
|
||||
|
||||
|
||||
@@ -110,7 +110,7 @@ GLOBAL_VAR_INIT(hadevent, 0)
|
||||
//command_alert("Unidentified lifesigns detected coming aboard [station_name()]. Secure any exterior access, including ducting and ventilation.", "Lifesign Alert")
|
||||
//world << sound('sound/AI/aliens.ogg')
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in machines)
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in GLOB.machines)
|
||||
if(!temp_vent.welded && temp_vent.network && (temp_vent.loc.z in using_map.station_levels))
|
||||
if(temp_vent.network.normal_members.len > 50) // Stops Aliens getting stuck in small networks. See: Security, Virology
|
||||
vents += temp_vent
|
||||
@@ -136,7 +136,7 @@ GLOBAL_VAR_INIT(hadevent, 0)
|
||||
/proc/high_radiation_event()
|
||||
|
||||
/* // Haha, this is way too laggy. I'll keep the prison break though.
|
||||
for(var/obj/machinery/light/L in machines)
|
||||
for(var/obj/machinery/light/L in GLOB.machines)
|
||||
if(isNotStationLevel(L.z)) continue
|
||||
L.flicker(50)
|
||||
|
||||
@@ -348,7 +348,7 @@ Would like to add a law like "Law x is _______" where x = a number, and _____ is
|
||||
M.add_ion_law("THE STATION IS [who2pref] [who2]")
|
||||
/* //VOREStation Edit
|
||||
if(botEmagChance)
|
||||
for(var/mob/living/bot/bot in machines)
|
||||
for(var/mob/living/bot/bot in GLOB.machines)
|
||||
if(prob(botEmagChance))
|
||||
bot.emag_act(1)
|
||||
*/ //VOREStation Edit
|
||||
@@ -377,7 +377,7 @@ Would like to add a law like "Law x is _______" where x = a number, and _____ is
|
||||
to_world("Finished processing SMES. Processed: [smesnum]")
|
||||
spawn(0)
|
||||
to_world("Started processing AIRLOCKS")
|
||||
for (var/obj/machinery/door/airlock/D in machines)
|
||||
for (var/obj/machinery/door/airlock/D in GLOB.machines)
|
||||
if(D.z in station_levels)
|
||||
//if(length(D.req_access) > 0 && !(12 in D.req_access)) //not counting general access and maintenance airlocks
|
||||
airlocknum++
|
||||
@@ -386,7 +386,7 @@ Would like to add a law like "Law x is _______" where x = a number, and _____ is
|
||||
to_world("Finished processing AIRLOCKS. Processed: [airlocknum]")
|
||||
spawn(0)
|
||||
to_world("Started processing FIREDOORS")
|
||||
for (var/obj/machinery/door/firedoor/D in machines)
|
||||
for (var/obj/machinery/door/firedoor/D in GLOB.machines)
|
||||
if(D.z in station_levels)
|
||||
firedoornum++;
|
||||
spawn(0)
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
//MOVEMENT
|
||||
if(prob(50))
|
||||
anchored = FALSE
|
||||
step(src, pick(alldirs))
|
||||
step(src, pick(GLOB.alldirs))
|
||||
anchored = TRUE
|
||||
controller()
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ In my current plan for it, 'solid' will be defined as anything with density == 1
|
||||
var/starty = 0
|
||||
var/endy = 0
|
||||
var/endx = 0
|
||||
var/startside = pick(cardinal)
|
||||
var/startside = pick(GLOB.cardinal)
|
||||
|
||||
switch(startside)
|
||||
if(NORTH)
|
||||
|
||||
@@ -24,7 +24,7 @@ The "dust" will damage the hull of the station causin minor hull breaches.
|
||||
numbers = rand(15,25)
|
||||
dust_type = /obj/effect/space_dust/super
|
||||
|
||||
var/startside = pick(cardinal)
|
||||
var/startside = pick(GLOB.cardinal)
|
||||
for(var/i = 0 to numbers)
|
||||
var/startx = 0
|
||||
var/starty = 0
|
||||
|
||||
@@ -134,7 +134,7 @@ GLOBAL_LIST_EMPTY(additional_antag_types)
|
||||
antag_summary += "[antag.role_text_plural]"
|
||||
i++
|
||||
antag_summary += "."
|
||||
if(antag_templates.len > 1 && master_mode != "secret")
|
||||
if(antag_templates.len > 1 && GLOB.master_mode != "secret")
|
||||
to_world(span_filter_system("[antag_summary]"))
|
||||
else
|
||||
message_admins("[antag_summary]")
|
||||
@@ -147,7 +147,7 @@ GLOBAL_LIST_EMPTY(additional_antag_types)
|
||||
if((player.client)&&(player.ready))
|
||||
playerC++
|
||||
|
||||
if(master_mode=="secret")
|
||||
if(GLOB.master_mode=="secret")
|
||||
if(playerC < CONFIG_GET(keyed_list/player_requirements_secret)[config_tag])
|
||||
return 0
|
||||
else
|
||||
@@ -583,7 +583,7 @@ GLOBAL_LIST_EMPTY(additional_antag_types)
|
||||
to_chat(usr, span_warning("Something is terribly wrong; there is no gametype."))
|
||||
return
|
||||
|
||||
if(master_mode != "secret")
|
||||
if(GLOB.master_mode != "secret")
|
||||
to_chat(usr, span_boldnotice("The roundtype is [capitalize(ticker.mode.name)]"))
|
||||
if(ticker.mode.round_description)
|
||||
to_chat(usr, span_notice(span_italics("[ticker.mode.round_description]")))
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
|
||||
/datum/malf_hardware/strong_turrets/install()
|
||||
..()
|
||||
for(var/obj/machinery/porta_turret/T in machines)
|
||||
for(var/obj/machinery/porta_turret/T in GLOB.machines)
|
||||
T.maxhealth = round(initial(T.maxhealth) * 1.4)
|
||||
T.shot_delay = round(initial(T.shot_delay) / 2)
|
||||
T.auto_repair = 1
|
||||
|
||||
@@ -129,7 +129,7 @@
|
||||
user.hacking = 0
|
||||
|
||||
|
||||
/datum/game_mode/malfunction/verb/machine_overload(obj/machinery/M in machines)
|
||||
/datum/game_mode/malfunction/verb/machine_overload(obj/machinery/M in GLOB.machines)
|
||||
set name = "Machine Overload"
|
||||
set desc = "400 CPU - Causes cyclic short-circuit in machine, resulting in weak explosion after some time."
|
||||
set category = "Software"
|
||||
|
||||
@@ -44,7 +44,7 @@ GLOBAL_VAR_INIT(meteor_wave_delay, 625) //minimum wait between waves in tenths o
|
||||
|
||||
/proc/spawn_meteor(var/list/meteortypes, var/startSide, var/startLevel)
|
||||
if(isnull(startSide))
|
||||
startSide = pick(cardinal)
|
||||
startSide = pick(GLOB.cardinal)
|
||||
if(isnull(startLevel))
|
||||
startLevel = pick(using_map.station_levels - using_map.sealed_levels)
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
|
||||
/obj/item/pinpointer/examine(mob/user)
|
||||
. = ..()
|
||||
for(var/obj/machinery/nuclearbomb/bomb in machines)
|
||||
for(var/obj/machinery/nuclearbomb/bomb in GLOB.machines)
|
||||
if(bomb.timing)
|
||||
. += "Extreme danger. Arming signal detected. Time remaining: [bomb.timeleft]"
|
||||
|
||||
@@ -287,7 +287,7 @@
|
||||
return PROCESS_KILL
|
||||
|
||||
if(!our_shuttle)
|
||||
for(var/obj/machinery/computer/shuttle_control/S in machines)
|
||||
for(var/obj/machinery/computer/shuttle_control/S in GLOB.machines)
|
||||
if(S.shuttle_tag == shuttle_comp_id) // Shuttle tags are used so that it will work if the computer path changes, as it does on the southern cross map.
|
||||
our_shuttle = S
|
||||
break
|
||||
|
||||
@@ -852,7 +852,7 @@ GLOBAL_LIST_EMPTY(all_objectives)
|
||||
explanation_text = "Summon Nar-Sie via the use of the appropriate rune (Hell join self). It will only work if nine cultists stand on and around it. The convert rune is join blood self."
|
||||
|
||||
/datum/objective/cult/eldergod/check_completion()
|
||||
return (locate(/obj/singularity/narsie/large) in machines)
|
||||
return (locate(/obj/singularity/narsie/large) in GLOB.machines)
|
||||
|
||||
/datum/objective/cult/sacrifice
|
||||
explanation_text = "Conduct a ritual sacrifice for the glory of Nar-Sie."
|
||||
|
||||
@@ -19,7 +19,7 @@ mob
|
||||
var/datum/hSB/sandbox = null
|
||||
proc
|
||||
CanBuild()
|
||||
if(master_mode == "sandbox")
|
||||
if(GLOB.master_mode == "sandbox")
|
||||
sandbox = new/datum/hSB
|
||||
sandbox.owner = src.ckey
|
||||
if(src.client.holder)
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
if(istype(hit_atom, /turf/simulated) && within_range(hit_atom))
|
||||
var/turf/simulated/T = hit_atom
|
||||
|
||||
for(var/direction in alldirs + null) // null is for the center tile.
|
||||
for(var/direction in GLOB.alldirs + null) // null is for the center tile.
|
||||
spawn(1)
|
||||
var/turf/desired_turf = get_step(T,direction)
|
||||
if(desired_turf) // This shouldn't fail but...
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
B.deity_name = H.mind.my_religion.deity
|
||||
I.assignment = H.mind.my_religion.title
|
||||
I.name = text("[I.registered_name]'s ID Card ([I.assignment])")
|
||||
data_core.manifest_modify(I.registered_name, I.assignment, I.rank)
|
||||
GLOB.data_core.manifest_modify(I.registered_name, I.assignment, I.rank)
|
||||
|
||||
/datum/religion
|
||||
var/religion = "Unitarianism"
|
||||
|
||||
@@ -29,7 +29,7 @@ var/global/datum/controller/occupations/job_master
|
||||
|
||||
|
||||
/datum/controller/occupations/proc/Debug(var/text)
|
||||
if(!Debug2) return 0
|
||||
if(!GLOB.Debug2) return 0
|
||||
job_debug.Add(text)
|
||||
return 1
|
||||
|
||||
@@ -976,11 +976,11 @@ var/global/datum/controller/occupations/job_master
|
||||
to_chat(C, span_warning("Your chosen spawnpoint ([spawnpos.display_name]) is unavailable for your chosen job. Please correct your spawn point choice."))
|
||||
return
|
||||
to_chat(C, span_filter_warning("Your chosen spawnpoint ([spawnpos.display_name]) is unavailable for your chosen job. Spawning you at the Arrivals shuttle instead."))
|
||||
var/spawning = pick(latejoin)
|
||||
var/spawning = pick(GLOB.latejoin)
|
||||
.["turf"] = get_turf(spawning)
|
||||
.["msg"] = "will arrive at the station shortly"
|
||||
else if(!fail_deadly)
|
||||
var/spawning = pick(latejoin)
|
||||
var/spawning = pick(GLOB.latejoin)
|
||||
.["turf"] = get_turf(spawning)
|
||||
.["msg"] = "has arrived on the station"
|
||||
|
||||
|
||||
@@ -103,7 +103,7 @@ GLOBAL_LIST_EMPTY(alien_whitelist)
|
||||
return 0
|
||||
|
||||
//Module is not even whitelisted
|
||||
if(!(module in whitelisted_module_types))
|
||||
if(!(module in GLOB.whitelisted_module_types))
|
||||
return 1
|
||||
|
||||
//If we have a loaded file, search it
|
||||
|
||||
@@ -24,7 +24,7 @@ var/makejson = 1 //temp
|
||||
else if(ticker.hide_mode)
|
||||
mode = "SECRET"
|
||||
else
|
||||
mode = master_mode
|
||||
mode = GLOB.master_mode
|
||||
var/playerscount = 0
|
||||
var/players = ""
|
||||
var/admins = "no"
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
if(O.anchored)
|
||||
return 0 //mob is anchored???
|
||||
if(get_dist(user, src) > 1 || get_dist(user, O) > 1)
|
||||
return 0 //doesn't use adjacent() to allow for non-cardinal (fuck my life)
|
||||
return 0 //doesn't use adjacent() to allow for non-GLOB.cardinal (fuck my life)
|
||||
if(!ishuman(user) && !isrobot(user))
|
||||
return 0 //not a borg or human
|
||||
if(panel_open)
|
||||
|
||||
@@ -173,7 +173,7 @@
|
||||
LAZYADD(A.all_arfgs, src)
|
||||
areas_added = list(A)
|
||||
|
||||
for(var/direction in cardinal)
|
||||
for(var/direction in GLOB.cardinal)
|
||||
A = get_area(get_step(src,direction))
|
||||
if(istype(A) && !(A in areas_added))
|
||||
LAZYADD(A.all_arfgs, src)
|
||||
|
||||
@@ -87,8 +87,8 @@
|
||||
|
||||
/obj/machinery/computer/card/tgui_static_data(mob/user)
|
||||
var/list/data = ..()
|
||||
if(data_core)
|
||||
data_core.get_manifest_list()
|
||||
if(GLOB.data_core)
|
||||
GLOB.data_core.get_manifest_list()
|
||||
data["manifest"] = GLOB.PDA_Manifest
|
||||
return data
|
||||
|
||||
@@ -156,7 +156,7 @@
|
||||
switch(action)
|
||||
if("modify")
|
||||
if(modify)
|
||||
data_core.manifest_modify(modify.registered_name, modify.assignment, modify.rank)
|
||||
GLOB.data_core.manifest_modify(modify.registered_name, modify.assignment, modify.rank)
|
||||
modify.name = "[modify.registered_name]'s ID Card ([modify.assignment])"
|
||||
if(ishuman(ui.user))
|
||||
modify.forceMove(get_turf(src))
|
||||
@@ -258,7 +258,7 @@
|
||||
P.name = text("crew manifest ([])", stationtime2text())
|
||||
P.info = {"<h4>Crew Manifest</h4>
|
||||
<br>
|
||||
[data_core ? data_core.get_manifest(0) : ""]
|
||||
[GLOB.data_core ? GLOB.data_core.get_manifest(0) : ""]
|
||||
"}
|
||||
else if(modify)
|
||||
P.name = "access report"
|
||||
|
||||
@@ -125,15 +125,15 @@
|
||||
if(authenticated)
|
||||
switch(screen)
|
||||
if(MED_DATA_R_LIST)
|
||||
if(!isnull(data_core.general))
|
||||
if(!isnull(GLOB.data_core.general))
|
||||
var/list/records = list()
|
||||
data["records"] = records
|
||||
for(var/datum/data/record/R in sortRecord(data_core.general))
|
||||
for(var/datum/data/record/R in sortRecord(GLOB.data_core.general))
|
||||
records[++records.len] = list("ref" = "\ref[R]", "id" = R.fields["id"], "name" = R.fields["name"])
|
||||
if(MED_DATA_RECORD)
|
||||
var/list/general = list()
|
||||
data["general"] = general
|
||||
if(istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
if(istype(active1, /datum/data/record) && GLOB.data_core.general.Find(active1))
|
||||
var/list/fields = list()
|
||||
general["fields"] = fields
|
||||
fields[++fields.len] = FIELD("Name", active1.fields["name"], null)
|
||||
@@ -155,7 +155,7 @@
|
||||
|
||||
var/list/medical = list()
|
||||
data["medical"] = medical
|
||||
if(istype(active2, /datum/data/record) && data_core.medical.Find(active2))
|
||||
if(istype(active2, /datum/data/record) && GLOB.data_core.medical.Find(active2))
|
||||
var/list/fields = list()
|
||||
medical["fields"] = fields
|
||||
fields[++fields.len] = MED_FIELD("Gender identity", active2.fields["id_gender"], "id_gender", TRUE)
|
||||
@@ -172,10 +172,10 @@
|
||||
medical["empty"] = 1
|
||||
if(MED_DATA_V_DATA)
|
||||
data["virus"] = list()
|
||||
for(var/datum/disease/D in active_diseases)
|
||||
for(var/datum/disease/D in GLOB.active_diseases)
|
||||
if(!D.discovered)
|
||||
continue
|
||||
var/datum/data/record/v = active_diseases[D]
|
||||
var/datum/data/record/v = GLOB.active_diseases[D]
|
||||
data["virus"] += list(list("name" = v.fields["name"], "D" = "\ref[v]"))
|
||||
if(MED_DATA_MEDBOT)
|
||||
data["medbots"] = list()
|
||||
@@ -206,9 +206,9 @@
|
||||
if(..())
|
||||
return TRUE
|
||||
|
||||
if(!data_core.general.Find(active1))
|
||||
if(!GLOB.data_core.general.Find(active1))
|
||||
active1 = null
|
||||
if(!data_core.medical.Find(active2))
|
||||
if(!GLOB.data_core.medical.Find(active2))
|
||||
active2 = null
|
||||
|
||||
. = TRUE
|
||||
@@ -276,7 +276,7 @@
|
||||
return FALSE
|
||||
tgui_modal_message(src, "virus", "", null, v.fields["tgui_description"])
|
||||
if("del_all")
|
||||
for(var/datum/data/record/R in data_core.medical)
|
||||
for(var/datum/data/record/R in GLOB.data_core.medical)
|
||||
qdel(R)
|
||||
set_temp("All medical records deleted.")
|
||||
if("del_r")
|
||||
@@ -285,12 +285,12 @@
|
||||
qdel(active2)
|
||||
if("d_rec")
|
||||
var/datum/data/record/general_record = locate(params["d_rec"] || "")
|
||||
if(!data_core.general.Find(general_record))
|
||||
if(!GLOB.data_core.general.Find(general_record))
|
||||
set_temp("Record not found.", "danger")
|
||||
return
|
||||
|
||||
var/datum/data/record/medical_record
|
||||
for(var/datum/data/record/M in data_core.medical)
|
||||
for(var/datum/data/record/M in GLOB.data_core.medical)
|
||||
if(M.fields["name"] == general_record.fields["name"] && M.fields["id"] == general_record.fields["id"])
|
||||
medical_record = M
|
||||
break
|
||||
@@ -326,7 +326,7 @@
|
||||
R.fields["cdi"] = "None"
|
||||
R.fields["cdi_d"] = "No diseases have been diagnosed at the moment."
|
||||
R.fields["notes"] = "No notes."
|
||||
data_core.medical += R
|
||||
GLOB.data_core.medical += R
|
||||
active2 = R
|
||||
screen = MED_DATA_RECORD
|
||||
set_temp("Medical record created.", "success")
|
||||
@@ -346,14 +346,14 @@
|
||||
if(!length(t1))
|
||||
return
|
||||
|
||||
for(var/datum/data/record/R in data_core.medical)
|
||||
for(var/datum/data/record/R in GLOB.data_core.medical)
|
||||
if(t1 == lowertext(R.fields["name"]) || t1 == lowertext(R.fields["id"]) || t1 == lowertext(R.fields["b_dna"]))
|
||||
active2 = R
|
||||
break
|
||||
if(!active2)
|
||||
set_temp("Medical record not found. You must enter the person's exact name, ID or DNA.", "danger")
|
||||
return
|
||||
for(var/datum/data/record/E in data_core.general)
|
||||
for(var/datum/data/record/E in GLOB.data_core.general)
|
||||
if(E.fields["name"] == active2.fields["name"] && E.fields["id"] == active2.fields["id"])
|
||||
active1 = E
|
||||
break
|
||||
@@ -432,7 +432,7 @@
|
||||
/obj/machinery/computer/med_data/proc/print_finish()
|
||||
var/obj/item/paper/P = new(loc)
|
||||
P.info = "<center>" + span_bold("Medical Record") + "</center><br>"
|
||||
if(istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
if(istype(active1, /datum/data/record) && GLOB.data_core.general.Find(active1))
|
||||
P.info += {"Name: [active1.fields["name"]] ID: [active1.fields["id"]]
|
||||
<br>\nSex: [active1.fields["sex"]]
|
||||
<br>\nSpecies: [active1.fields["species"]]
|
||||
@@ -442,7 +442,7 @@
|
||||
<br>\nMental Status: [active1.fields["m_stat"]]<br>"}
|
||||
else
|
||||
P.info += span_bold("General Record Lost!") + "<br>"
|
||||
if(istype(active2, /datum/data/record) && data_core.medical.Find(active2))
|
||||
if(istype(active2, /datum/data/record) && GLOB.data_core.medical.Find(active2))
|
||||
P.info += {"<br>\n<center><b>Medical Data</b></center>
|
||||
<br>\nGender Identity: [active2.fields["id_gender"]]
|
||||
<br>\nBlood Type: [active2.fields["b_type"]]
|
||||
@@ -486,7 +486,7 @@
|
||||
..(severity)
|
||||
return
|
||||
|
||||
for(var/datum/data/record/R in data_core.medical)
|
||||
for(var/datum/data/record/R in GLOB.data_core.medical)
|
||||
if(prob(10/severity))
|
||||
switch(rand(1,6))
|
||||
if(1)
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
return INITIALIZE_HINT_LATELOAD
|
||||
|
||||
/obj/machinery/computer/pod/LateInitialize()
|
||||
for(var/obj/machinery/mass_driver/M in machines)
|
||||
for(var/obj/machinery/mass_driver/M in GLOB.machines)
|
||||
if(M.id == id)
|
||||
connected = M
|
||||
break
|
||||
@@ -30,19 +30,19 @@
|
||||
to_chat(viewers(null, null),"Cannot locate mass driver connector. Cancelling firing sequence!")
|
||||
return
|
||||
|
||||
for(var/obj/machinery/door/blast/M in machines)
|
||||
for(var/obj/machinery/door/blast/M in GLOB.machines)
|
||||
if(M.id == id)
|
||||
M.open()
|
||||
|
||||
sleep(20)
|
||||
|
||||
for(var/obj/machinery/mass_driver/M in machines)
|
||||
for(var/obj/machinery/mass_driver/M in GLOB.machines)
|
||||
if(M.id == id)
|
||||
M.power = connected.power
|
||||
M.drive()
|
||||
|
||||
sleep(50)
|
||||
for(var/obj/machinery/door/blast/M in machines)
|
||||
for(var/obj/machinery/door/blast/M in GLOB.machines)
|
||||
if(M.id == id)
|
||||
M.close()
|
||||
return
|
||||
@@ -168,7 +168,7 @@
|
||||
if(href_list["alarm"])
|
||||
alarm()
|
||||
if(href_list["drive"])
|
||||
for(var/obj/machinery/mass_driver/M in machines)
|
||||
for(var/obj/machinery/mass_driver/M in GLOB.machines)
|
||||
if(M.id == id)
|
||||
M.power = connected.power
|
||||
M.drive()
|
||||
@@ -180,7 +180,7 @@
|
||||
time += tp
|
||||
time = min(max(round(time), 0), 120)
|
||||
if(href_list["door"])
|
||||
for(var/obj/machinery/door/blast/M in machines)
|
||||
for(var/obj/machinery/door/blast/M in GLOB.machines)
|
||||
if(M.id == id)
|
||||
if(M.density)
|
||||
M.open()
|
||||
|
||||
@@ -113,13 +113,13 @@
|
||||
if(authenticated)
|
||||
switch(screen)
|
||||
if(SEC_DATA_R_LIST)
|
||||
if(!isnull(data_core.general))
|
||||
if(!isnull(GLOB.data_core.general))
|
||||
var/list/records = list()
|
||||
data["records"] = records
|
||||
for(var/datum/data/record/R in sortRecord(data_core.general))
|
||||
for(var/datum/data/record/R in sortRecord(GLOB.data_core.general))
|
||||
var/color = null
|
||||
var/criminal = "None"
|
||||
for(var/datum/data/record/M in data_core.security)
|
||||
for(var/datum/data/record/M in GLOB.data_core.security)
|
||||
if(M.fields["name"] == R.fields["name"] && M.fields["id"] == R.fields["id"])
|
||||
switch(M.fields["criminal"])
|
||||
if("*Arrest*")
|
||||
@@ -142,7 +142,7 @@
|
||||
if(SEC_DATA_RECORD)
|
||||
var/list/general = list()
|
||||
data["general"] = general
|
||||
if(istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
if(istype(active1, /datum/data/record) && GLOB.data_core.general.Find(active1))
|
||||
var/list/fields = list()
|
||||
general["fields"] = fields
|
||||
fields[++fields.len] = FIELD("Name", active1.fields["name"], "name")
|
||||
@@ -166,7 +166,7 @@
|
||||
|
||||
var/list/security = list()
|
||||
data["security"] = security
|
||||
if(istype(active2, /datum/data/record) && data_core.security.Find(active2))
|
||||
if(istype(active2, /datum/data/record) && GLOB.data_core.security.Find(active2))
|
||||
var/list/fields = list()
|
||||
security["fields"] = fields
|
||||
fields[++fields.len] = FIELD("Criminal Status", active2.fields["criminal"], "criminal")
|
||||
@@ -189,9 +189,9 @@
|
||||
if(..())
|
||||
return TRUE
|
||||
|
||||
if(!data_core.general.Find(active1))
|
||||
if(!GLOB.data_core.general.Find(active1))
|
||||
active1 = null
|
||||
if(!data_core.security.Find(active2))
|
||||
if(!GLOB.data_core.security.Find(active2))
|
||||
active2 = null
|
||||
|
||||
. = TRUE
|
||||
@@ -254,7 +254,7 @@
|
||||
active1 = null
|
||||
active2 = null
|
||||
if("del_all")
|
||||
for(var/datum/data/record/R in data_core.security)
|
||||
for(var/datum/data/record/R in GLOB.data_core.security)
|
||||
qdel(R)
|
||||
set_temp("All security records deleted.")
|
||||
if("del_r")
|
||||
@@ -264,7 +264,7 @@
|
||||
if("del_r_2")
|
||||
set_temp("All records for [active1.fields["name"]] deleted.")
|
||||
if(active1)
|
||||
for(var/datum/data/record/R in data_core.medical)
|
||||
for(var/datum/data/record/R in GLOB.data_core.medical)
|
||||
if((R.fields["name"] == active1.fields["name"] || R.fields["id"] == active1.fields["id"]))
|
||||
qdel(R)
|
||||
qdel(active1)
|
||||
@@ -282,12 +282,12 @@
|
||||
active2.fields["notes"] = new_notes
|
||||
if("d_rec")
|
||||
var/datum/data/record/general_record = locate(params["d_rec"] || "")
|
||||
if(!data_core.general.Find(general_record))
|
||||
if(!GLOB.data_core.general.Find(general_record))
|
||||
set_temp("Record not found.", "danger")
|
||||
return
|
||||
|
||||
var/datum/data/record/security_record
|
||||
for(var/datum/data/record/M in data_core.security)
|
||||
for(var/datum/data/record/M in GLOB.data_core.security)
|
||||
if(M.fields["name"] == general_record.fields["name"] && M.fields["id"] == general_record.fields["id"])
|
||||
security_record = M
|
||||
break
|
||||
@@ -309,7 +309,7 @@
|
||||
R.fields["ma_crim_d"] = "No major crime convictions."
|
||||
R.fields["notes"] = "No notes."
|
||||
R.fields["notes"] = "No notes."
|
||||
data_core.security += R
|
||||
GLOB.data_core.security += R
|
||||
active2 = R
|
||||
screen = SEC_DATA_RECORD
|
||||
set_temp("Security record created.", "success")
|
||||
@@ -329,14 +329,14 @@
|
||||
if(!length(t1))
|
||||
return
|
||||
|
||||
for(var/datum/data/record/R in data_core.general)
|
||||
for(var/datum/data/record/R in GLOB.data_core.general)
|
||||
if(t1 == lowertext(R.fields["name"]) || t1 == lowertext(R.fields["id"]) || t1 == lowertext(R.fields["fingerprint"]))
|
||||
active1 = R
|
||||
break
|
||||
if(!active1)
|
||||
set_temp("Security record not found. You must enter the person's exact name, ID, or fingerprint.", "danger")
|
||||
return
|
||||
for(var/datum/data/record/E in data_core.security)
|
||||
for(var/datum/data/record/E in GLOB.data_core.security)
|
||||
if(E.fields["name"] == active1.fields["name"] && E.fields["id"] == active1.fields["id"])
|
||||
active2 = E
|
||||
break
|
||||
@@ -433,7 +433,7 @@
|
||||
/obj/machinery/computer/secure_data/proc/print_finish()
|
||||
var/obj/item/paper/P = new(loc)
|
||||
P.info = "<center>" + span_bold("Security Record") + "</center><br>"
|
||||
if(istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
if(istype(active1, /datum/data/record) && GLOB.data_core.general.Find(active1))
|
||||
P.info += {"Name: [active1.fields["name"]] ID: [active1.fields["id"]]
|
||||
<br>\nSex: [active1.fields["sex"]]
|
||||
<br>\nSpecies: [active1.fields["species"]]
|
||||
@@ -443,7 +443,7 @@
|
||||
<br>\nMental Status: [active1.fields["m_stat"]]<br>"}
|
||||
else
|
||||
P.info += span_bold("General Record Lost!") + "<br>"
|
||||
if(istype(active2, /datum/data/record) && data_core.security.Find(active2))
|
||||
if(istype(active2, /datum/data/record) && GLOB.data_core.security.Find(active2))
|
||||
P.info += {"<br>\n<center><b>Security Data</b></center>
|
||||
<br>\nCriminal Status: [active2.fields["criminal"]]<br>\n
|
||||
<br>\nMinor Crimes: [active2.fields["mi_crim"]]
|
||||
@@ -494,7 +494,7 @@
|
||||
..(severity)
|
||||
return
|
||||
|
||||
for(var/datum/data/record/R in data_core.security)
|
||||
for(var/datum/data/record/R in GLOB.data_core.security)
|
||||
if(prob(10/severity))
|
||||
switch(rand(1,6))
|
||||
if(1)
|
||||
|
||||
@@ -98,10 +98,10 @@
|
||||
if(authenticated)
|
||||
switch(screen)
|
||||
if(GENERAL_RECORD_LIST)
|
||||
if(!isnull(data_core.general))
|
||||
if(!isnull(GLOB.data_core.general))
|
||||
var/list/records = list()
|
||||
data["records"] = records
|
||||
for(var/datum/data/record/R in sortRecord(data_core.general))
|
||||
for(var/datum/data/record/R in sortRecord(GLOB.data_core.general))
|
||||
records[++records.len] = list(
|
||||
"ref" = "\ref[R]",
|
||||
"id" = R.fields["id"],
|
||||
@@ -110,7 +110,7 @@
|
||||
if(GENERAL_RECORD_DATA)
|
||||
var/list/general = list()
|
||||
data["general"] = general
|
||||
if(istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
if(istype(active1, /datum/data/record) && GLOB.data_core.general.Find(active1))
|
||||
var/list/fields = list()
|
||||
general["fields"] = fields
|
||||
fields[++fields.len] = FIELD("Name", active1.fields["name"], "name")
|
||||
@@ -149,7 +149,7 @@
|
||||
|
||||
add_fingerprint(ui.user)
|
||||
|
||||
if(!data_core.general.Find(active1))
|
||||
if(!GLOB.data_core.general.Find(active1))
|
||||
active1 = null
|
||||
|
||||
. = TRUE
|
||||
@@ -211,7 +211,7 @@
|
||||
if("del_all")
|
||||
if(GLOB.PDA_Manifest)
|
||||
GLOB.PDA_Manifest.Cut()
|
||||
for(var/datum/data/record/R in data_core.general)
|
||||
for(var/datum/data/record/R in GLOB.data_core.general)
|
||||
qdel(R)
|
||||
set_temp("All employment records deleted.")
|
||||
if("sync_r")
|
||||
@@ -228,14 +228,14 @@
|
||||
if(GLOB.PDA_Manifest)
|
||||
GLOB.PDA_Manifest.Cut()
|
||||
if(active1)
|
||||
for(var/datum/data/record/R in data_core.medical)
|
||||
for(var/datum/data/record/R in GLOB.data_core.medical)
|
||||
if ((R.fields["name"] == active1.fields["name"] || R.fields["id"] == active1.fields["id"]))
|
||||
qdel(R)
|
||||
set_temp("Employment record deleted.")
|
||||
QDEL_NULL(active1)
|
||||
if("d_rec")
|
||||
var/datum/data/record/general_record = locate(params["d_rec"] || "")
|
||||
if(!data_core.general.Find(general_record))
|
||||
if(!GLOB.data_core.general.Find(general_record))
|
||||
set_temp("Record not found.", "danger")
|
||||
return
|
||||
|
||||
@@ -244,7 +244,7 @@
|
||||
if("new")
|
||||
if(GLOB.PDA_Manifest)
|
||||
GLOB.PDA_Manifest.Cut()
|
||||
active1 = data_core.CreateGeneralRecord()
|
||||
active1 = GLOB.data_core.CreateGeneralRecord()
|
||||
screen = GENERAL_RECORD_DATA
|
||||
set_temp("Employment record created.", "success")
|
||||
if("del_c")
|
||||
@@ -328,7 +328,7 @@
|
||||
/obj/machinery/computer/skills/proc/print_finish()
|
||||
var/obj/item/paper/P = new(loc)
|
||||
P.info = "<center>" + span_bold("Medical Record") + "</center><br>"
|
||||
if(istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
if(istype(active1, /datum/data/record) && GLOB.data_core.general.Find(active1))
|
||||
P.info += {"Name: [active1.fields["name"]] ID: [active1.fields["id"]]
|
||||
<br>\nSex: [active1.fields["sex"]]
|
||||
<br>\nSpecies: [active1.fields["species"]]
|
||||
@@ -371,7 +371,7 @@
|
||||
..(severity)
|
||||
return
|
||||
|
||||
for(var/datum/data/record/R in data_core.security)
|
||||
for(var/datum/data/record/R in GLOB.data_core.security)
|
||||
if(prob(10/severity))
|
||||
switch(rand(1,6))
|
||||
if(1)
|
||||
|
||||
@@ -92,7 +92,7 @@ var/specops_shuttle_timeleft = 0
|
||||
|
||||
specops_shuttle_at_station = 0
|
||||
|
||||
for(var/obj/machinery/computer/specops_shuttle/S in machines)
|
||||
for(var/obj/machinery/computer/specops_shuttle/S in GLOB.machines)
|
||||
S.specops_shuttle_timereset = world.time + SPECOPS_RETURN_DELAY
|
||||
|
||||
qdel(announcer)
|
||||
@@ -233,7 +233,7 @@ var/specops_shuttle_timeleft = 0
|
||||
var/mob/M = locate(/mob) in T
|
||||
to_chat(M, span_notice("You have arrived to [station_name()]. Commence operation!"))
|
||||
|
||||
for(var/obj/machinery/computer/specops_shuttle/S in machines)
|
||||
for(var/obj/machinery/computer/specops_shuttle/S in GLOB.machines)
|
||||
S.specops_shuttle_timereset = world.time + SPECOPS_RETURN_DELAY
|
||||
|
||||
qdel(announcer)
|
||||
@@ -241,7 +241,7 @@ var/specops_shuttle_timeleft = 0
|
||||
/proc/specops_can_move()
|
||||
if(specops_shuttle_moving_to_station || specops_shuttle_moving_to_centcom)
|
||||
return 0
|
||||
for(var/obj/machinery/computer/specops_shuttle/S in machines)
|
||||
for(var/obj/machinery/computer/specops_shuttle/S in GLOB.machines)
|
||||
if(world.timeofday <= S.specops_shuttle_timereset)
|
||||
return 0
|
||||
return 1
|
||||
|
||||
@@ -162,14 +162,14 @@
|
||||
|
||||
/obj/machinery/computer/timeclock/proc/isOpenOnDutyJob(var/mob/user, var/department, var/datum/job/job)
|
||||
return job \
|
||||
&& job.is_position_available() \
|
||||
&& !job.whitelist_only \
|
||||
&& !jobban_isbanned(user,job.title) \
|
||||
&& job.player_old_enough(user.client) \
|
||||
&& job.player_has_enough_playtime(user.client) \
|
||||
&& job.pto_type == department \
|
||||
&& !job.disallow_jobhop \
|
||||
&& job.timeoff_factor > 0
|
||||
&& job.is_position_available() \
|
||||
&& !job.whitelist_only \
|
||||
&& !jobban_isbanned(user,job.title) \
|
||||
&& job.player_old_enough(user.client) \
|
||||
&& job.player_has_enough_playtime(user.client) \
|
||||
&& job.pto_type == department \
|
||||
&& !job.disallow_jobhop \
|
||||
&& job.timeoff_factor > 0
|
||||
|
||||
/obj/machinery/computer/timeclock/proc/makeOnDuty(var/newrank, var/newassignment, var/mob/user)
|
||||
var/datum/job/oldjob = job_master.GetJob(card.rank)
|
||||
@@ -193,7 +193,7 @@
|
||||
card.rank = newjob.title
|
||||
card.assignment = newassignment
|
||||
card.name = text("[card.registered_name]'s ID Card ([card.assignment])")
|
||||
data_core.manifest_modify(card.registered_name, card.assignment, card.rank)
|
||||
GLOB.data_core.manifest_modify(card.registered_name, card.assignment, card.rank)
|
||||
card.last_job_switch = world.time
|
||||
callHook("reassign_employee", list(card))
|
||||
newjob.current_positions++
|
||||
@@ -219,7 +219,7 @@
|
||||
card.rank = ptojob.title
|
||||
card.assignment = ptojob.title
|
||||
card.name = text("[card.registered_name]'s ID Card ([card.assignment])")
|
||||
data_core.manifest_modify(card.registered_name, card.assignment, card.rank)
|
||||
GLOB.data_core.manifest_modify(card.registered_name, card.assignment, card.rank)
|
||||
card.last_job_switch = world.time
|
||||
callHook("reassign_employee", list(card))
|
||||
var/mob/living/carbon/human/H = user
|
||||
|
||||
@@ -180,7 +180,7 @@
|
||||
// assume linked_db since called by interact()
|
||||
var/crew = ""
|
||||
var/list/L = list()
|
||||
for (var/datum/data/record/t in data_core.general)
|
||||
for (var/datum/data/record/t in GLOB.data_core.general)
|
||||
var/R = t.fields["name"] + " - " + t.fields["rank"]
|
||||
L += R
|
||||
for(var/R in sortList(L))
|
||||
@@ -278,7 +278,7 @@
|
||||
var/obj/item/paper/P = new /obj/item/paper( computer.loc )
|
||||
P.info = span_bold("Crew Manifest:") + "<BR>"
|
||||
var/list/L = list()
|
||||
for (var/datum/data/record/t in data_core.general)
|
||||
for (var/datum/data/record/t in GLOB.data_core.general)
|
||||
var/R = t.fields["name"] + " - " + t.fields["rank"]
|
||||
L += R
|
||||
for(var/R in sortList(L))
|
||||
|
||||
@@ -448,7 +448,7 @@
|
||||
preserve = 1
|
||||
|
||||
if(istype(W,/obj/item/implant/health))
|
||||
for(var/obj/machinery/computer/cloning/com in machines)
|
||||
for(var/obj/machinery/computer/cloning/com in GLOB.machines)
|
||||
for(var/datum/dna2/record/R in com.records)
|
||||
if(locate(R.implant) == W)
|
||||
qdel(R)
|
||||
@@ -504,26 +504,26 @@
|
||||
|
||||
if(GLOB.PDA_Manifest.len)
|
||||
GLOB.PDA_Manifest.Cut()
|
||||
for(var/datum/data/record/R in data_core.medical)
|
||||
for(var/datum/data/record/R in GLOB.data_core.medical)
|
||||
if((R.fields["name"] == to_despawn.real_name))
|
||||
qdel(R)
|
||||
for(var/datum/data/record/T in data_core.security)
|
||||
for(var/datum/data/record/T in GLOB.data_core.security)
|
||||
if((T.fields["name"] == to_despawn.real_name))
|
||||
qdel(T)
|
||||
for(var/datum/data/record/G in data_core.general)
|
||||
for(var/datum/data/record/G in GLOB.data_core.general)
|
||||
if((G.fields["name"] == to_despawn.real_name))
|
||||
qdel(G)
|
||||
|
||||
// Also check the hidden version of each datacore, if they're an offmap role.
|
||||
var/datum/job/J = SSjob.get_job(job)
|
||||
if(J?.offmap_spawn)
|
||||
for(var/datum/data/record/R in data_core.hidden_general)
|
||||
for(var/datum/data/record/R in GLOB.data_core.hidden_general)
|
||||
if((R.fields["name"] == to_despawn.real_name))
|
||||
qdel(R)
|
||||
for(var/datum/data/record/T in data_core.hidden_security)
|
||||
for(var/datum/data/record/T in GLOB.data_core.hidden_security)
|
||||
if((T.fields["name"] == to_despawn.real_name))
|
||||
qdel(T)
|
||||
for(var/datum/data/record/G in data_core.hidden_medical)
|
||||
for(var/datum/data/record/G in GLOB.data_core.hidden_medical)
|
||||
if((G.fields["name"] == to_despawn.real_name))
|
||||
qdel(G)
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user