adjustable point limit

At the moment for my kill confirmed style script that each player has their own variant off there is a fixed point limit of 10 points that the player must achieve what I want to do is add a point limit float variable that I can adjust in the menu scene with a slider or buttons How would I achieve this?

here is the script:

public class tokenscoring : MonoBehaviour {



	public Text MyText;
	private int score;
// add adjustable point limit variable here

	// Use this for initialization
	void Start () {

		MyText.text = "";

	}


	// Update is called once per frame
	void Update () {

		MyText.text = "" + score;

	}


	void OnCollisionEnter (Collision col)
	{
		if (col.gameObject.tag == "point") {
			score = score +1;
		}
//change this to whatever the max point limit is
		if (score >= 10) {
			SceneManager.LoadScene(7);
		}
	}


}

The easiest is use Unity Canvas Slider. Its a UI tool. You can set the minimum and maximum float value for the slider within the inspector.

Here the manual:
https://docs.unity3d.com/Manual/script-Slider.html

So everytime the slider value change you update the float value.