Major fucking kerfing work, but it still fails :(

Maybe need to refactor the entire thing to make it work....