Moved algorithm for REJECT building to map/reject.cpp/h

I'm tired of moving this presently unused code around, so its now in
it's own source files. It will be updated and brought into use very
soon, however.