x3 almost done, needs debug