summaryrefslogtreecommitdiff
path: root/Assets/Scripts/DEBUG_GrabbingDisplay.cs
blob: 0bb1cf51a132f582f982e8a8a66ec7bb3b8c9505 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
using System;
using TMPro;
using UnityEngine;

[RequireComponent(typeof(TMP_Text))]
public class DebugGrabbingDisplay : MonoBehaviour
{
    public PlayerControl playerControl;
    
    private TMP_Text _text;

    private void Awake()
    {
        _text = GetComponent<TMP_Text>();
    }

    private void Update()
    {
        _text.text = playerControl.grabbing ? "Grabbing" : "Not Grabbing";
    }
}