made map into nodes

more efficiency in searching