fixed all compiler errors. testing at a later point.