reorganized some rules and fixed tp scroll bug