Mostly finished the output stuff