tgstation/-tg-station — pull request #6513 by Menshin (2014-12-22 00:43:13+00:00)
Title: Maploader instanciation fix

The preloader used by the maploader was passed as second argument to the atom _New()_, effectively erasing any second argument passed by default to the instanciated object.
That would result in a runtime when, for example, checking for inexisting __preloader.loc_ (done by Solars Panels).

I did the best i could, without pointers or proper function overloading, to make the preloader independant of New() :

* The _preloader_ is now a global object, destroyed after succesful variable loading
* the _preloader_ stores and check the path of the instanciated atom (to prevent being trigger by further atoms created in the initial atom New())
* the _is_type_ has been replaced by checking if there's a _preloader_ then if the type is corresponding (string compare).

The whole thing is working fine : i'm able to mapload boxstation without an error (or just one, unrelated, caused the HoP windoor having a field set to "null" instead of null).

__Remark :__ the whole system obviously work because no atom is creating an atom of same type on instanciation.
I've taken that as an axiom and we should keep that in mind when creating new types, if we want to keep it compatible with the maploader.

I'm not submitting that to downstream (_Bay_ and _/vg_) yet, as i've no comment on this.
I'll do so when everything as been deemed fine.