added almost all of the visual interaction