All rules finished, but the datastructure need to be redesigned