private KeywordTooltip GetTooltip() { KeywordTooltip keywordTooltip = (m_tooltipPool.Count <= 0) ? Object.Instantiate <KeywordTooltip>(m_tooltipTemplate, this.get_transform()) : m_tooltipPool.Pop(); keywordTooltip.get_gameObject().SetActive(true); return(keywordTooltip); }
public void Initialize(ITooltipDataProvider dataProvider) { RemoveAllTooltip(); IFightValueProvider valueProvider = dataProvider.GetValueProvider(); KeywordReference[] keywordReferences = dataProvider.keywordReferences; if (keywordReferences == null) { return; } for (int num = keywordReferences.Length - 1; num >= 0; num--) { KeywordReference keywordReference = keywordReferences[num]; if (keywordReference.IsValidFor(RuntimeData.currentKeywordContext)) { ITooltipDataProvider tooltipDataProvider = TooltipDataProviderFactory.Create(keywordReference, valueProvider); if (tooltipDataProvider != null) { KeywordTooltip tooltip = GetTooltip(); tooltip.Initialize(tooltipDataProvider); m_activeTooltips.Add(tooltip); } } } }
private void ReleaseTooltip(KeywordTooltip keywordTooltip) { keywordTooltip.get_gameObject().SetActive(false); m_tooltipPool.Push(keywordTooltip); }
public unsafe void LateUpdate() { //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: Unknown result type (might be due to invalid IL or missing references) //IL_00e1: Unknown result type (might be due to invalid IL or missing references) //IL_00e6: Unknown result type (might be due to invalid IL or missing references) //IL_00f3: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0101: Unknown result type (might be due to invalid IL or missing references) //IL_010e: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) //IL_0146: Unknown result type (might be due to invalid IL or missing references) if (m_opening) { m_opening = false; int num = 0; int num2 = 0; switch (m_verticalAlignment) { case VerticalAlignment.Up: num = 1; num2 = 1; break; case VerticalAlignment.Down: num = 0; num2 = 0; break; default: throw new ArgumentOutOfRangeException("m_verticalAlignment", m_verticalAlignment, null); } float num3 = 0f; float num4 = 0f; float num5 = (m_verticalAlignment != 0) ? 1 : (-1); for (int i = 0; i < m_activeTooltips.Count; i++) { float num6 = m_nextOpeningDelay * (float)i + m_openingDelay; KeywordTooltip tooltip = m_activeTooltips[i]; RectTransform component = tooltip.GetComponent <RectTransform>(); LayoutRebuilder.ForceRebuildLayoutImmediate(component); Rect rect = component.get_rect(); float height = rect.get_height(); Vector2 pivot = component.get_pivot(); pivot.y = num; component.set_pivot(pivot); Vector2 val = component.get_anchorMin(); val.y = num2; component.set_anchorMin(val); val = component.get_anchorMax(); val.y = num2; component.set_anchorMax(val); component.set_anchoredPosition(new Vector2(0f, num4)); tooltip.alpha = 0f; m_openingTweens.Add(TweenSettingsExtensions.SetDelay <Tweener>(DOTweenModuleUI.DOAnchorPos(component, new Vector2(0f, num3), m_openingDuration, false), num6)); _003C_003Ec__DisplayClass23_0 _003C_003Ec__DisplayClass23_; m_openingTweens.Add(TweenSettingsExtensions.SetDelay <TweenerCore <float, float, FloatOptions> >(DOTween.To(new DOGetter <float>((object)_003C_003Ec__DisplayClass23_, (IntPtr)(void *) /*OpCode not supported: LdFtn*/), new DOSetter <float>((object)_003C_003Ec__DisplayClass23_, (IntPtr)(void *) /*OpCode not supported: LdFtn*/), 1f, m_openingDuration), num6)); num4 = num3; num3 += num5 * (height + m_spacing); } } }