change the game rule and fix some bugs