fixed all bugs, now to make a gui