More updates. Still debugging code inside.