mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-21 03:55:05 +01:00
Improved logging (#13208)
* Death is logged. hiveminds and robot talk is logged * Added channels to the say log * Shuttle logging * Spell targets logging
This commit is contained in:
@@ -109,7 +109,7 @@ GLOBAL_LIST(labor_sheet_values)
|
||||
if(!alone_in_area(get_area(src), usr))
|
||||
to_chat(usr, "<span class='warning'>Prisoners are only allowed to be released while alone.</span>")
|
||||
else
|
||||
switch(SSshuttle.moveShuttle("laborcamp", "laborcamp_home", TRUE))
|
||||
switch(SSshuttle.moveShuttle("laborcamp", "laborcamp_home", TRUE, usr))
|
||||
if(1)
|
||||
to_chat(usr, "<span class='notice'>Shuttle not found.</span>")
|
||||
if(2)
|
||||
@@ -121,6 +121,7 @@ GLOBAL_LIST(labor_sheet_values)
|
||||
var/message = "[inserted_id.registered_name] has returned to the station. Minerals and Prisoner ID card ready for retrieval."
|
||||
announcer.autosay(message, "Labor Camp Controller", "Security")
|
||||
to_chat(usr, "<span class='notice'>Shuttle received message and will be sent shortly.</span>")
|
||||
usr.create_log(MISC_LOG, "used [src] to call the laborcamp shuttle")
|
||||
|
||||
return TRUE
|
||||
|
||||
|
||||
@@ -98,7 +98,9 @@
|
||||
if(!check_can_speak(speaker))
|
||||
return FALSE
|
||||
|
||||
log_say("([name]-HIVE) [message]", speaker)
|
||||
var/log_message = "([name]-HIVE) [message]"
|
||||
log_say(log_message, speaker)
|
||||
speaker.create_log(SAY_LOG, log_message)
|
||||
|
||||
if(!speaker_mask)
|
||||
speaker_mask = speaker.name
|
||||
@@ -605,7 +607,10 @@
|
||||
if(!message)
|
||||
return
|
||||
|
||||
log_say("(ROBOT) [message]", speaker)
|
||||
var/log_message = "(ROBOT) [message]"
|
||||
log_say(log_message, speaker)
|
||||
speaker.create_log(SAY_LOG, log_message)
|
||||
|
||||
var/message_start = "<i><span class='game say'>[name], <span class='name'>[speaker.name]</span>"
|
||||
var/message_body = "<span class='message'>[speaker.say_quote(message)],</i><span class='robot'>\"[message]\"</span></span></span>"
|
||||
|
||||
|
||||
@@ -81,6 +81,7 @@
|
||||
update_canmove()
|
||||
|
||||
timeofdeath = world.time
|
||||
create_log(ATTACK_LOG, "died[gibbed ? " (Gibbed)": ""]")
|
||||
|
||||
GLOB.living_mob_list -= src
|
||||
GLOB.dead_mob_list += src
|
||||
|
||||
@@ -177,6 +177,12 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
if(handle_message_mode(message_mode, message_pieces, verb, used_radios))
|
||||
return 1
|
||||
|
||||
// Log of what we've said, plain message, no spans or junk
|
||||
// handle_message_mode should have logged this already if it handled it
|
||||
var/log_message = "[message_mode ? "([message_mode])" : ""] '[message]'"
|
||||
say_log += log_message
|
||||
create_log(SAY_LOG, log_message) // TODO after #13047: Include the channel
|
||||
log_say(log_message, src)
|
||||
|
||||
var/list/handle_v = handle_speech_sound()
|
||||
var/sound/speech_sound = handle_v[1]
|
||||
@@ -274,10 +280,6 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
if(O) //It's possible that it could be deleted in the meantime.
|
||||
O.hear_talk(src, message_pieces, verb)
|
||||
|
||||
//Log of what we've said, plain message, no spans or junk
|
||||
say_log += message
|
||||
create_log(SAY_LOG, message) // TODO after #13047: Include the channel
|
||||
log_say(message, src)
|
||||
return 1
|
||||
|
||||
/obj/effect/speech_bubble
|
||||
|
||||
@@ -91,7 +91,7 @@
|
||||
else
|
||||
devour(L)
|
||||
|
||||
/mob/living/simple_animal/hostile/megafauna/onShuttleMove()
|
||||
/mob/living/simple_animal/hostile/megafauna/onShuttleMove(turf/oldT, turf/T1, rotation, mob/caller)
|
||||
var/turf/oldloc = loc
|
||||
. = ..()
|
||||
if(!.)
|
||||
@@ -100,7 +100,7 @@
|
||||
message_admins("Megafauna [src] \
|
||||
([ADMIN_FLW(src,"FLW")]) \
|
||||
moved via shuttle from ([oldloc.x], [oldloc.y], [oldloc.z]) to \
|
||||
([newloc.x], [newloc.y], [newloc.z])")
|
||||
([newloc.x], [newloc.y], [newloc.z])[caller ? " called by [ADMIN_LOOKUP(caller)]" : ""]")
|
||||
|
||||
/mob/living/simple_animal/hostile/megafauna/proc/devour(mob/living/L)
|
||||
if(!L)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Shuttle on-movement //
|
||||
/atom/movable/proc/onShuttleMove(turf/oldT, turf/T1, rotation)
|
||||
/atom/movable/proc/onShuttleMove(turf/oldT, turf/T1, rotation, mob/caller)
|
||||
var/turf/newT = get_turf(src)
|
||||
if(newT.z != oldT.z)
|
||||
onTransitZ(oldT.z, newT.z)
|
||||
|
||||
@@ -218,6 +218,8 @@
|
||||
var/travelDir = 0 //direction the shuttle would travel in
|
||||
var/rebuildable = 0 //can build new shuttle consoles for this one
|
||||
|
||||
var/mob/last_caller // Who called the shuttle the last time
|
||||
|
||||
var/obj/docking_port/stationary/destination
|
||||
var/obj/docking_port/stationary/previous
|
||||
|
||||
@@ -496,7 +498,7 @@
|
||||
areaInstance.moving = TRUE
|
||||
//move mobile to new location
|
||||
for(var/atom/movable/AM in T0)
|
||||
AM.onShuttleMove(T0, T1, rotation)
|
||||
AM.onShuttleMove(T0, T1, rotation, last_caller)
|
||||
|
||||
if(rotation)
|
||||
T1.shuttleRotate(rotation)
|
||||
@@ -809,9 +811,10 @@
|
||||
// Seriously, though, NEVER trust a Topic with something like this. Ever.
|
||||
message_admins("move HREF ([src] attempted to move to: [href_list["move"]]) exploit attempted by [key_name_admin(usr)] on [src] (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)")
|
||||
return
|
||||
switch(SSshuttle.moveShuttle(shuttleId, href_list["move"], 1))
|
||||
switch(SSshuttle.moveShuttle(shuttleId, href_list["move"], 1, usr))
|
||||
if(0)
|
||||
atom_say("Shuttle departing! Please stand away from the doors.")
|
||||
usr.create_log(MISC_LOG, "used [src] to call the [shuttleId] shuttle")
|
||||
if(1)
|
||||
to_chat(usr, "<span class='warning'>Invalid shuttle requested.</span>")
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user