Finished region off and region on draw code, fixed several bugs in angle calculation