I am currently trying to make a collectible when all coins have passed then you would get an extra life there. Maybe someone knows how I should go fix?
below I have a small example was added.
//// example /////
void OnGUI()
{
string split = Application.loadedLevelName.Split(“_”[0]);
if(levelwon)
{
Logic logic = GameObject.Find("Logic").GetComponent("Logic") as Logic;
if(logic.GetBasherScore(9)== true)
{
GUI.DrawTexture(new Rect(Screen.width/2-280,20,80,80), trophy);
}
for(int i=1; i<7; i++)
{
if(logic.GetBasherScore(i)== true)
{
GUI.DrawTexture(new Rect(bbposx[i-1],bbposy[i-1],40,40), bbmunten[i-1]);
}
}