Files
fulpstation/code/__HELPERS/ref.dm
SomethingFish 6280f5cca0 November TGU (#846)
* this just fixes the dme its still pretty unfinished

* fixes bloodsuckers (and some silence stuff)

* fixed costumes and beefman its time to TEST

* fixes some stuff

* ITS DONE (?)

* it wasnt done.

* THE THINGS ARE FIXED RAAAAAAAAAAAAAH

* me when i have to FIX MAPS

* jk actually fixes the maps this time i promise

* i think this probably fixes the screenshots maybe

* it should work now (i hope)

* i think this dependency is helpful

* how

* please fix some of the errors

* fucked up the dio stand pathing

* tgedit for the simple animal freeze test

* lets see if this works

* fixed the merge conflict

* i think thats it?

* there are. a few new unit tests.

* THE NEW UNIT TESTS BROKE EVERYTHING

* fixes all this dumb shit

soooooy quien soyyyy no preciso identifiiiicación

* prison radio be gone

* brings back helio sec (lol)

* mobs aren't used anywhere anymore kill them

* fixes screenshots

* NOTHING BUT SCRAP

* whoops haha silly me

rewrites a few keys to fix corruption

* gives felinids brain damage (SPEEDMERGE)

* welcome to fulpstation

Co-authored-by: SgtHunk <68669754+SgtHunk@users.noreply.github.com>
2022-11-25 00:51:07 -03:00

16 lines
630 B
Plaintext

/**
* \ref behaviour got changed in 512 so this is necesary to replicate old behaviour.
* If it ever becomes necesary to get a more performant REF(), this lies here in wait
* #define REF(thing) (thing && isdatum(thing) && (thing:datum_flags & DF_USE_TAG) && thing:tag ? "[thing:tag]" : text_ref(thing))
**/
/proc/REF(input)
if(isdatum(input))
var/datum/thing = input
if(thing.datum_flags & DF_USE_TAG)
if(!thing.tag)
stack_trace("A ref was requested of an object with DF_USE_TAG set but no tag: [thing]")
thing.datum_flags &= ~DF_USE_TAG
else
return "\[[url_encode(thing.tag)]\]"
return text_ref(input)