Added graph controller and moved some stuff around