AddConstructionPoint in V6

cmdSampleTest.cpp (1.9 KB)
The attached file is my test file.
This sample run in Rhino v5, it can auto detect point by use “AddConstructionPoint”.
But it run in Rhino v6, it can’t auto detect point by use “AddConstructionPoint”.

Could somebody help me to solve this problem?

The behavior is a result of this change:

Construction points are now snapped to only when osnaps are enabled to make the snapping always be in sync with other osnaps.

To enable osnaps you can add these two lines to the beginning of the command:
bool bOsnapsEnabled = RhinoApp().AppSettings().EnableOsnaps();

…and then revert the setting at the end of the command:

Thank you very much.
Now It work fine ^ ^