Changedm some stuff and added (broken) seralisation