When online GUI.Label (or text area etc) shows overlapping text

You can see my small script below. It simply resets the players position when they fall below a certain height and adds one to their death count and also the team’s death count.

using UnityEngine;
using System.Collections;

public class Scoring : MonoBehaviour
	public float lowestFallDistance = -10;
	private int deathCount;
	public static int teamDeathCount;
	private string deathCountString;
	public static string teamDeathCountString;
	private int screenWidth;

    void Start()
        deathCount = 0;
		teamDeathCount = 0;
		deathCountString = deathCount.ToString();
		teamDeathCountString = teamDeathCount.ToString();
		screenWidth = Screen.width;

    void Update()
		if(this.transform.position.y < lowestFallDistance)

	void OnGUI()
		GUI.Label(new Rect(5, 5, 30, 20),deathCountString);
		GUI.Label(new Rect(screenWidth - 35, 5, 30, 20),teamDeathCountString);
	void Reset(){
		this.transform.position = new Vector3(0,2,0);
		networkView.RPC("PlusTeam", RPCMode.AllBuffered, "");
		deathCountString = deathCount.ToString();
	void PlusTeam(string empty) {
		teamDeathCountString = teamDeathCount.ToString();

The team’s death count in the top right only shows once, and just as I intend it to, but the player’s individual death count in the top left is always zero with the actual count displayed on top.

This only happens when I play online. If I play single player and die it just shows the correct score without a zero underneath. I really don’t see what I’ve done wrong so any help would be greatly appreciated.

Not sure if this will fix it but it will reduce the amount of lines in your code instead of storing an individual string parallel to the integer why not when you need to display the counters as a string call the .toString() function.

GUI.Label(new Rect(5, 5, 30, 20),deathCount.ToString());

Just went through some previous questions and seen this unanswered.

I had the script on more than one object so it showed it once for each object it was on. Sharing in case anyone else makes the same mistake I did.