Example #1
0
    void OnGUI()
    {
        DemoGUIHelpers.setupGUIButtons();


        GUILayout.Label("Click anywhere to move the cube via a SmoothedVector3");
        GUILayout.Space(30);
        GUILayout.Label("Click the buttons below the slider to use\na SmoothedFloat to change the slider value");

        GUILayout.BeginHorizontal();

        if (GUILayout.Button("Set To Value to 10"))
        {
            _smoothedFloat.setToValue(10f);
        }


        if (GUILayout.Button("Set To Value to -10"))
        {
            _smoothedFloat.setToValue(-10f);
        }

        GUILayout.EndHorizontal();

        GUILayout.HorizontalSlider(_smoothedFloat.value, -10f, 10f, GUILayout.Width(250));


        DemoGUIHelpers.easeTypesGUI();
    }