Pick-up five objects, beginner help??

how to make win with pick up 5 object and in camera “you win” and press enter loadlevel

sorry bad english need help someone

Add trigger colliders to each pick-up and then in the OnTriggerEnter() function use a static variable to increment value. Example:

void OnTriggerEnter(Collider col) {

    if (col.gameObject.tag == "Player") {
   
         MyPlayer.myValue += 1; 

    }
}

Then in your MyPlayer class put something like this:

public static int myValue = 0; 

void Update() {

if (myValue == 5) {

    // insert code to show a win message

}

}