So what kind of mongrel object is GUISkin.CustomStyles anyway?
In the inspector, it acts like an array of GUIStyles, and I can successfully refer to a custom style element by saying:
var mySkin : GUISkin;
var theStyle : GUIStyle = mySkin.customStyles[1];
BUT
mySkin.customStyles.length
throws the following error:
Assets/Editor/CustomSkinInfo.cs(17) error: UnityEngine.GUIStyle[ ]' does not contain a definition for length’
I want to know this because I was writing a little editor script that would list all the Custom Styles by name and index number so it would be easier to twirl down the specific one I want.
But there doesn’t seem to be a way to recover how many styles there are.