Fully finished re-writing the resource loading process.