Write kill code a bit differently
Keep x and y coordinates in points connected more in line math
Move angle between point math to line.js