Spent the past days working on this when I was not at work