Still working on weird behavior, minor fixes.