TG Sync 12/15/17

s

s
This commit is contained in:
kevinz000
2017-12-15 03:28:09 -08:00
parent b6b0ab69e3
commit 253c819bc1
762 changed files with 13429 additions and 14872 deletions
+44 -17
View File
@@ -2,6 +2,9 @@
INITIALIZE_IMMEDIATE(/mob/dead)
/mob/dead
sight = SEE_TURFS | SEE_MOBS | SEE_OBJS | SEE_SELF
/mob/dead/Initialize()
if(initialized)
stack_trace("Warning: [src]([type]) initialized multiple times!")
@@ -11,8 +14,9 @@ INITIALIZE_IMMEDIATE(/mob/dead)
prepare_huds()
if(CONFIG_GET(string/cross_server_address))
if(length(CONFIG_GET(keyed_string_list/cross_server)))
verbs += /mob/dead/proc/server_hop
set_focus(src)
return INITIALIZE_HINT_NORMAL
/mob/dead/dust() //ghosts can't be vaporised.
@@ -24,6 +28,9 @@ INITIALIZE_IMMEDIATE(/mob/dead)
/mob/dead/ConveyorMove() //lol
return
/mob/dead/forceMove(atom/destination)
loc = destination
/mob/dead/Stat()
..()
@@ -42,26 +49,46 @@ INITIALIZE_IMMEDIATE(/mob/dead)
else
stat(null, "Time To Start: SOON")
stat(null, "Players: [SSticker.totalPlayers]")
if(client.holder)
stat(null, "Players Ready: [SSticker.totalPlayersReady]")
/mob/dead/proc/server_hop()
set category = "OOC"
set name = "Server Hop!"
set desc= "Jump to the other server"
if(notransform)
return
var/csa = CONFIG_GET(string/cross_server_address)
if(csa)
verbs -= /mob/dead/proc/server_hop
to_chat(src, "<span class='notice'>Server Hop has been disabled.</span>")
var/list/csa = CONFIG_GET(keyed_string_list/cross_server)
var/pick
switch(csa.len)
if(0)
verbs -= /mob/dead/proc/server_hop
to_chat(src, "<span class='notice'>Server Hop has been disabled.</span>")
if(1)
pick = csa[0]
else
pick = input(src, "Pick a server to jump to", "Server Hop") as null|anything in csa
if(!pick)
return
if (alert(src, "Jump to server running at [csa]?", "Server Hop", "Yes", "No") != "Yes")
return 0
if (client && csa)
to_chat(src, "<span class='notice'>Sending you to [csa].</span>")
new /obj/screen/splash(client)
notransform = TRUE
sleep(29) //let the animation play
notransform = FALSE
winset(src, null, "command=.options") //other wise the user never knows if byond is downloading resources
client << link(csa + "?server_hop=[key]")
else
to_chat(src, "<span class='error'>There is no other server configured!</span>")
var/addr = csa[pick]
if(alert(src, "Jump to server [pick] ([addr])?", "Server Hop", "Yes", "No") != "Yes")
return
var/client/C = client
to_chat(C, "<span class='notice'>Sending you to [pick].</span>")
new /obj/screen/splash(C)
notransform = TRUE
sleep(29) //let the animation play
notransform = FALSE
if(!C)
return
winset(src, null, "command=.options") //other wise the user never knows if byond is downloading resources
C << link("[addr]?server_hop=[key]")
+4 -26
View File
@@ -21,9 +21,9 @@
S.Fade(TRUE)
if(length(GLOB.newplayer_start))
loc = pick(GLOB.newplayer_start)
forceMove(pick(GLOB.newplayer_start))
else
loc = locate(1,1,1)
forceMove(locate(1,1,1))
ComponentInitialize()
@@ -73,26 +73,6 @@
popup.open(0)
return
/mob/dead/new_player/Stat()
..()
if(statpanel("Lobby"))
stat("Game Mode:", (SSticker.hide_mode) ? "Secret" : "[GLOB.master_mode]")
stat("Map:", SSmapping.config.map_name)
if(SSticker.current_state == GAME_STATE_PREGAME)
var/time_remaining = SSticker.GetTimeLeft()
if(time_remaining > 0)
stat("Time To Start:", "[round(time_remaining/10)]s")
else if(time_remaining == -10)
stat("Time To Start:", "DELAYED")
else
stat("Time To Start:", "SOON")
stat("Players:", "[SSticker.totalPlayers]")
if(client.holder)
stat("Players Ready:", "[SSticker.totalPlayersReady]")
/mob/dead/new_player/Topic(href, href_list[])
if(src != usr)
@@ -282,7 +262,7 @@
var/obj/effect/landmark/observer_start/O = locate(/obj/effect/landmark/observer_start) in GLOB.landmarks_list
to_chat(src, "<span class='notice'>Now teleporting.</span>")
if (O)
observer.loc = O.loc
observer.forceMove(O.loc)
else
to_chat(src, "<span class='notice'>Teleporting failed. Ahelp an admin please</span>")
stack_trace("There's no freaking observer landmark available on this map or you're making observers before the map is initialised")
@@ -317,15 +297,13 @@
return 0
if(job.required_playtime_remaining(client))
return 0
if(CONFIG_GET(flag/enforce_human_authority) && !client.prefs.pref_species.qualifies_for_rank(rank, client.prefs.features))
return 0
return 1
/mob/dead/new_player/proc/AttemptLateSpawn(rank)
if(!IsJobAvailable(rank))
alert(src, "[rank] is not available. Please try another.")
return 0
return FALSE
if(SSticker.late_join_disabled)
alert(src, "An administrator has disabled late join spawning.")
@@ -1,4 +1,5 @@
//The mob should have a gender you want before running this proc. Will run fine without H
//The mob should have a gender you want before running this proc. Will run fine without H
/datum/preferences/proc/random_character(gender_override)
if(gender_override)
gender = gender_override
@@ -19,7 +20,7 @@
features = random_features()
age = rand(AGE_MIN,AGE_MAX)
/datum/preferences/proc/update_preview_icon(nude = 0)
/datum/preferences/proc/update_preview_icon()
// Silicons only need a very basic preview since there is no customization for them.
if(job_engsec_high)
switch(job_engsec_high)
@@ -56,7 +57,7 @@
previewJob = job
break
if(previewJob && !nude)
if(previewJob)
mannequin.job = previewJob.title
previewJob.equip(mannequin, TRUE)
COMPILE_OVERLAYS(mannequin)
+8 -9
View File
@@ -13,7 +13,6 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
density = FALSE
canmove = 0
anchored = TRUE // don't get pushed around
sight = SEE_TURFS | SEE_MOBS | SEE_OBJS | SEE_SELF
see_invisible = SEE_INVISIBLE_OBSERVER
see_in_dark = 100
invisibility = INVISIBILITY_OBSERVER
@@ -109,7 +108,7 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
else
T = locate(round(world.maxx/2), round(world.maxy/2), ZLEVEL_STATION_PRIMARY) //middle of the station
loc = T
forceMove(T)
if(!name) //To prevent nameless ghosts
name = random_unique_name(gender)
@@ -136,13 +135,13 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
/mob/dead/observer/narsie_act()
var/old_color = color
color = "#960000"
animate(src, color = old_color, time = 10, flags_1 = ANIMATION_PARALLEL)
animate(src, color = old_color, time = 10, flags = ANIMATION_PARALLEL)
addtimer(CALLBACK(src, /atom/proc/update_atom_colour), 10)
/mob/dead/observer/ratvar_act()
var/old_color = color
color = "#FAE48C"
animate(src, color = old_color, time = 10, flags_1 = ANIMATION_PARALLEL)
animate(src, color = old_color, time = 10, flags = ANIMATION_PARALLEL)
addtimer(CALLBACK(src, /atom/proc/update_atom_colour), 10)
/mob/dead/observer/Destroy()
@@ -288,10 +287,10 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/oldloc = loc
if(NewLoc)
loc = NewLoc
forceMove(NewLoc)
update_parallax_contents()
else
loc = get_turf(src) //Get out of closets and such as a ghost
forceMove(get_turf(src)) //Get out of closets and such as a ghost
if((direct & NORTH) && y < world.maxy)
y++
else if((direct & SOUTH) && y > 1)
@@ -371,7 +370,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
if(!L || !L.len)
to_chat(usr, "No area available.")
usr.loc = pick(L)
usr.forceMove(pick(L))
update_parallax_contents()
/mob/dead/observer/verb/follow()
@@ -445,7 +444,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/turf/T = get_turf(M) //Turf of the destination mob
if(T && isturf(T)) //Make sure the turf exists, then move the source to that destination.
A.loc = T
A.forceMove(T)
A.update_parallax_contents()
else
to_chat(A, "This mob is not located in the game world.")
@@ -767,8 +766,8 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
//Istype so we filter out points of interest that are not mobs
if(client && mob_eye && istype(mob_eye))
client.eye = mob_eye
client.screen = list()
if(mob_eye.hud_used)
client.screen = list()
LAZYINITLIST(mob_eye.observers)
mob_eye.observers |= src
mob_eye.hud_used.show_hud(mob_eye.hud_used.hud_version, src)
+24 -24
View File
@@ -1,25 +1,25 @@
/mob/dead/observer/say(message)
message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
if (!message)
return
/mob/dead/observer/say(message)
message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
if (!message)
return
log_talk(src,"Ghost/[src.key] : [message]", LOGSAY)
. = src.say_dead(message)
/mob/dead/observer/Hear(message, atom/movable/speaker, message_language, raw_message, radio_freq, list/spans, message_mode)
var/atom/movable/to_follow = speaker
if(radio_freq)
var/atom/movable/virtualspeaker/V = speaker
if(isAI(V.source))
var/mob/living/silicon/ai/S = V.source
to_follow = S.eyeobj
else
to_follow = V.source
var/link = FOLLOW_LINK(src, to_follow)
// Recompose the message, because it's scrambled by default
message = compose_message(speaker, message_language, raw_message, radio_freq, spans, message_mode)
to_chat(src, "[link] [message]")
. = src.say_dead(message)
/mob/dead/observer/Hear(message, atom/movable/speaker, message_language, raw_message, radio_freq, list/spans, message_mode)
var/atom/movable/to_follow = speaker
if(radio_freq)
var/atom/movable/virtualspeaker/V = speaker
if(isAI(V.source))
var/mob/living/silicon/ai/S = V.source
to_follow = S.eyeobj
else
to_follow = V.source
var/link = FOLLOW_LINK(src, to_follow)
// Recompose the message, because it's scrambled by default
message = compose_message(speaker, message_language, raw_message, radio_freq, spans, message_mode)
to_chat(src, "[link] [message]")