void OnEnable() { if (PrefabUtility.GetCorrespondingObjectFromSource(target) == null && PrefabUtility.GetPrefabInstanceHandle(target) != null) { return; } linearFeature = (Asset.World.LinearFeature)target; lastCenter = ToV2(linearFeature.transform.localPosition); SceneView.duringSceneGui += OnScene; }
private void OnDisable() { linearFeature = null; }