mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2025-12-30 12:03:11 +00:00
Merge pull request #10959 from PsiOmegaDelta/150831-GetThatTurf
Ports LummoxJr's get_turf()
This commit is contained in:
@@ -1053,12 +1053,10 @@ proc/get_mob_with_client_list()
|
||||
|
||||
//gets the turf the atom is located in (or itself, if it is a turf).
|
||||
//returns null if the atom is not in a turf.
|
||||
/proc/get_turf(atom/location)
|
||||
while(location)
|
||||
if(isturf(location))
|
||||
return location
|
||||
location = location.loc
|
||||
return null
|
||||
/proc/get_turf(atom/A)
|
||||
if(!istype(A)) return
|
||||
for(A, A && !isturf(A), A=A.loc);
|
||||
return A
|
||||
|
||||
/proc/get(atom/loc, type)
|
||||
while(loc)
|
||||
|
||||
Reference in New Issue
Block a user