Question:
Can you place an animated gif inside of GUILayout? If so, How?
Explanation:
Using the Unity documentation here, I have seen that the GUILayout Label supports Images.
Label(image: Texture, params options: GUILayoutOption[]): void;
OR
Label(image: Texture, style: GUIStyle, params options: GUILayoutOption[]): void;
Would you need to use code like this?:
public var pictureArray:Texture[];
private var picture:Texture;
private var delay:int = 0;
private var count:int = 0;
function OnGUI ()
{
delay++;
if(delay % 20 == 0)
{
count++;
if(count == pictureArray.Length)
count = 0;
picture = pictureArray[count];
delay = 0;
}
}
If so, in which parameters of the label would this belong in?