コード例 #1
0
ファイル: PopupTextStorage.cs プロジェクト: TorLinn/pTap
    public void ShowText(PopupTextType _textType)
    {
        var temp = popupTexts.Find(someText => someText.popupTextType == _textType);

        if (temp != null)
        {
            CurrentPopupText = temp;
            NewPopuTextAction?.Invoke();
        }
    }
コード例 #2
0
    public void CreateText(Vector2 position, string text, PopupTextType type, bool crit, PopupTextDirection direction)
    {
        PopupText popupText = Instantiate(popupTextPrefab, popupTextTransform);

        popupText.transform.position = position;
        popupText.Text      = text;
        popupText.Type      = type;
        popupText.Crit      = crit;
        popupText.Direction = direction;

        popupText.Move();
    }