protected override void OnEnable() { //base.OnEnable(); _layoutKenBurns = (LayoutKenBurns)target; _zoomType = serializedObject.FindProperty("_zoomType"); _displayDuration = serializedObject.FindProperty("_displayDuration"); _transitionDuration = serializedObject.FindProperty("_transitionDuration"); }
// Start is called before the first frame update void Start() { if (LayoutSwap == null) { LayoutSwap = GetComponentInChildren <LayoutSwap>(); } if (LayoutKenBurns == null) { LayoutKenBurns = GetComponentInChildren <LayoutKenBurns>(); } if (LayoutAssetFlow == null) { LayoutAssetFlow = GameObject.FindObjectOfType <LayoutAssetFlow>(); } if (LayoutAssetFlow != null) { if (LayoutAssetFlow.AssetFlowType == AssetFlowEnum.Loop) { AsseFlowSlider.minValue = 0; AsseFlowSlider.maxValue = 1; } else if (LayoutAssetFlow.AssetFlowType == AssetFlowEnum.Clamp) { AsseFlowSlider.minValue = -1; AsseFlowSlider.maxValue = 1; } } if (LayoutHelix == null) { LayoutHelix = FindObjectOfType <LayoutHelix>(); } if (LayoutCarousel == null) { LayoutCarousel = FindObjectOfType <LayoutCarousel>(); } }