Exemplo n.º 1
0
        void OnEnable()
        {
            TunnelingVignette tunnelingVignette = (TunnelingVignette)target;

            previewFOVDegrees = tunnelingVignette.CurrentFOV;
            previewAlpha      = tunnelingVignette.Alpha;
        }
Exemplo n.º 2
0
        public override void OnInspectorGUI()
        {
            TunnelingVignette tunnelingVignette = (TunnelingVignette)target;

            DrawDefaultInspector();

            previewFOVDegrees = EditorGUILayout.Slider("Preview FOV (Degrees)", previewFOVDegrees, 5.0f, 180.0f);
            tunnelingVignette.SetPreviewFOV(previewFOVDegrees);

            previewAlpha = EditorGUILayout.Slider("Preview Alpha", previewAlpha, 0.0f, 1.0f);
            tunnelingVignette.SetPreviewAlpha(previewAlpha);
        }