Started templatizing shit, but having problems