Fixed all bugs, almost done.