added more base functions and started ai