Got things basically working