Templating

Bunch o' changes