GUI.label overlapping text


I am having a problem with my GUI.Label. I am trying to get it to display variables in my code for debugging etc. but when the variable changes it overlaps with the previous and i end up with a mess (see screenshot)


I have looked for solutions online but not found something solid enough to fix this problem. Has anyone ever come across this. Here is my GUI function, as short as it is.

	void OnGUI()
		GUI.Label(new Rect(15, 15, 150, 30), "isJump = " + leftThumbValueX);

If you Subclass a script then clearly those scripts OnGUI will also be called, calling through to the base. Answer - avoid using inheritance in your game logic if you can - it leads to problems like this - try to use a component/composition architecture. If you use inheritance then expect the base class functions to be called.

If you want to hide the underlying scripts OnGUI in a subclass then just do:

void OnGUI() {} 

In the subclass.