added startup and story logic to webapp