Why does this object instantly kill it self

public class DestroyScore : MonoBehaviour {
public int Score;
public GameObject Ball;
public bool alive ;

	// Use this for initialization
	void Start () {
        Score = 0;
        alive = true;
    }
	
	// Update is called once per frame
	void Update () {
        if (alive == false) ;
        {
            DestroyObject(gameObject);
        }
            
	}
    void OnTriggerEnter(Collider other)
    {
        alive = false;
        Score = + 1 ;
    }
}

When i start the game the object instantly is destroyed, im pretty sure the Alive status is true at the start so im not sure why its being instantly destroyed.

I believe the error is the semicolon at the end of the if statement line.
This will tell the compiler that its the end of the if statement and treat the destroy call as just another bit of code outside of it.

Remove the semi-colon and it will start working as intended.

Edit: finally got a moment to test this theory, and it is just the semi-colon, removing that stops the object destroying immediately.

Try the code without “void OnTriggerEnter(Collider other) …” if the problem is over you know what the problem is.