protected virtual void SetHorizontal(DSC_Dialogue_TextGroupController hTextGroupController) { var eVertical = AlignVerticalType.Middle; var eAlignType = hTextGroupController.GetTextAlign(m_nIndex); if (eAlignType == TextAlignmentOptions.TopLeft || eAlignType == TextAlignmentOptions.Top || eAlignType == TextAlignmentOptions.TopRight) { eVertical = AlignVerticalType.Top; } else if (eAlignType == TextAlignmentOptions.BottomLeft || eAlignType == TextAlignmentOptions.Bottom || eAlignType == TextAlignmentOptions.BottomRight) { eVertical = AlignVerticalType.Bottom; } SetTextAlign(hTextGroupController, GetAlignType(m_eHorizontal, eVertical)); }
protected virtual void SetTextAlign(DSC_Dialogue_TextGroupController hTextGroupController, TextAlignmentOptions eAlign) { switch (m_eTextType) { case TextType.Dialogue: hTextGroupController.SetDialogueTextAlign(eAlign); break; case TextType.Talker: hTextGroupController.SetTalkerTextAlign(eAlign); break; case TextType.Text: hTextGroupController.SetTextAlign(m_nIndex, eAlign); break; } }
protected virtual void SetVertical(DSC_Dialogue_TextGroupController hTextGroupController) { var eHorizontal = AlignHorizontalType.Center; var eAlignType = hTextGroupController.GetTextAlign(m_nIndex); if (eAlignType == TextAlignmentOptions.TopLeft || eAlignType == TextAlignmentOptions.Left || eAlignType == TextAlignmentOptions.BottomLeft) { eHorizontal = AlignHorizontalType.Left; } else if (eAlignType == TextAlignmentOptions.TopRight || eAlignType == TextAlignmentOptions.Right || eAlignType == TextAlignmentOptions.BottomRight) { eHorizontal = AlignHorizontalType.Right; } SetTextAlign(hTextGroupController, GetAlignType(eHorizontal, m_eVertical)); }
protected void SetTalkerColor(DSC_Dialogue_TextGroupController hTextGroupController) { hTextGroupController.SetTalkerTextColor(m_hColor); }
protected void ResetDialogueColor(DSC_Dialogue_TextGroupController hTextGroupController) { hTextGroupController.ResetDialogueTextColorToDefault(); }
protected void ResetTextColor(DSC_Dialogue_TextGroupController hTextGroupController) { hTextGroupController.ResetTextColorToDefault(m_nIndex); }
protected void SetTextColor(DSC_Dialogue_TextGroupController hTextGroupController) { hTextGroupController.SetTextColor(m_nIndex, m_hColor); }
protected virtual void SetBoth(DSC_Dialogue_TextGroupController hTextGroupController) { SetTextAlign(hTextGroupController, GetAlignType(m_eHorizontal, m_eVertical)); }