modify NPuzzle