Updated loader, split asset into own lib

The main executable has very few dependencies now.