mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Merge pull request #1929 from CHOMPStationBot/upstream-merge-10286
[MIRROR] Adds subsystem crash logging to SSprocess and SSmobs
This commit is contained in:
@@ -1656,3 +1656,36 @@ GLOBAL_REAL_VAR(list/stack_trace_storage)
|
||||
/proc/CallAsync(datum/source, proctype, list/arguments)
|
||||
set waitfor = FALSE
|
||||
return call(source, proctype)(arglist(arguments))
|
||||
|
||||
/proc/describeThis(var/datum/D)
|
||||
if(istype(D))
|
||||
var/msg = "[D.type] - [D]"
|
||||
if(isatom(D))
|
||||
var/atom/A = D
|
||||
if(!A.z)
|
||||
msg += " - Coords unavailable (in contents?)"
|
||||
if(ismovable(A))
|
||||
var/turf/T = get_turf(A)
|
||||
if(T)
|
||||
msg += " - Parent turf: [T.x],[T.y],[T.z]"
|
||||
else
|
||||
msg += " - In nullspace"
|
||||
else
|
||||
msg += " - In nullspace"
|
||||
else
|
||||
msg += "- [A.x],[A.y],[A.z]"
|
||||
return msg
|
||||
else if(isnull(D))
|
||||
return "NULL"
|
||||
else if(istext(D))
|
||||
return "TEXT: [D]"
|
||||
else if(isnum(D))
|
||||
return "NUM: [D]"
|
||||
else if(ispath(D))
|
||||
return "PATH: [D]"
|
||||
else if(islist(D))
|
||||
return "LIST: [D]"
|
||||
else if(isclient(D))
|
||||
return "CLIENT: [D]"
|
||||
else
|
||||
return "Unknown data type: [D]"
|
||||
|
||||
Reference in New Issue
Block a user