Moving globals into a struct (currently also global :) )