core functions completed. almost.