all base functionality coded