new code we wrote on sunday, need to re-merge it with phase 15 and after