Scoring help !

hello all

First I apologize for my bad English

Secondly I would like to know how I can do that when you collect 100 coins instead of displaying “Coins: 100” … I want to show me something like “beginner”. If I collected 200 coins “advanced” … 300 “experienced”

Here is my script

using UnityEngine;
using System.Collections;

public class CoinsTotalShow : MonoBehaviour {

	private int coins = 0;
	public Texture2D coinIconTexture;

	// Use this for initialization
	void Start () {
		coins = PlayerPrefs.GetInt("Coins", coins);
	
	}


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

	void FixedUpdate (){
		PlayerPrefs.SetInt("Coins",coins);
	}

	void DisplayCoinsCount()
	{
		Rect coinIconRect = new Rect(10, 10, 32, 32);
		GUI.DrawTexture(coinIconRect, coinIconTexture);                         
		
		GUIStyle style = new GUIStyle();
		style.fontSize = 30;
		style.fontStyle = FontStyle.Bold;
		style.normal.textColor = Color.yellow;
		
		Rect labelRect = new Rect(coinIconRect.xMax, coinIconRect.y, 60, 32);
		GUI.Label(labelRect, coins.ToString(), style);
	}

	void OnGUI()
	{
		DisplayCoinsCount();

	}
}

Edit: If you haven’t used if() statements before then here is a video. Learning all the concepts on that page will help you solve the majority of problems in scripting.

Edit2: I’ve made the code closer to what you want. But please watch the videos as this is a very rudimentary programming problem.

I’m unsure of the specifics of what you want but this should get you started:

string skillLevel = coins.ToString() + " ";
    
if(coins >= 300){
    skillLevel += "Experienced";
}
else if(coins >= 200){
    skillLevel += "Advanced";
}
else if(coins >= 100){
    skillLevel += "Beginner";
}

Rect labelRect = new Rect(coinIconRect.xMax, coinIconRect.y, 60, 32)
GUI.Label(labelRect, skillLevel, style);

Modify the if() logic however you need.