Hello all,
I am trying to get my GUI Texture to scale around a pivot. Unfortunatly I cannot find any code examples in C#. I have tried a quick test using the mouse button as a trigger, but I get the error stating that my Expression denotes a ‘type’, where a ‘variable’, ‘value’ or method group was expected. But I do have a float value in there. Can someone please help me figure out what I am doing wrong.
Thanks
using UnityEngine;
using System.Collections;
public class GUIHealth : MonoBehaviour {
void OnGUI () {
if (Input.GetButton("Fire1")) {
GUIUtility.ScaleAroundPivot (Vector2(-10f, -10f), Vector2(128f,128f));
}
}
}