Hello, new to programming and I’m trying to figure out how to load a win screen after the player has collected four pickups. It’s not generating any errors, but it won’t load the win scene after I pick up the four items.
Are we able to post our entire code on here? Or is that against a rule (sorry, new to the forum as well).
Currently I have a private int for the count and a void OnTriggerEnter. If the trigger has the player tag, then it increases the count by one. Next is “if (playSound)” (there’s a public AudioClip for it above the void), and then it checks if the count is greater than or equal to four. If it is, it goes on to the loadlevel script (something given to me).
Any help would be much appreciated, thanks.