Making GUItext ignore the rotation of its parent?

I have GUItext parented to an object, (I know I shouldn’t do this, but it’s extremely convenient for what I’m doing.) but it’s moving around the screen when I rotate the object. How do I let the GUItext ignore the rotation of the object it’s parented to? I can’t clamp the GUItext’s coordinates, because I already have another script attached to it that let’s it move around the screen.

1 Answer

1

The simplest way to do this is to not parent it, but rather make it follow the other object in whatever way is necessary, using a trivial script like:

var target : Transform;
var offset = Vector3(0,0,-1);

function Update()
{
    transform.position = target.position + offset;
}