ScrollItem.cs 532 B

123456789101112131415161718192021222324252627
  1. using System;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4. using TMPro;
  5. using UnityEngine;
  6. public class ScrollItem : MonoBehaviour
  7. {
  8. private TextMeshProUGUI _textMeshPro;
  9. private void Awake()
  10. {
  11. _textMeshPro = gameObject.GetComponentInChildren<TextMeshProUGUI>();
  12. _textMeshPro.text = name.Replace("Item", "");
  13. }
  14. // Start is called before the first frame update
  15. void Start()
  16. {
  17. }
  18. // Update is called once per frame
  19. void Update()
  20. {
  21. }
  22. }