Just some random additions as I debug and improve things.