Files
gmtk-2021/Assets/DirectionPaddle.cs
2021-06-12 14:18:38 +02:00

19 lines
454 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class DirectionPaddle : MonoBehaviour
{
public void Switch()
{
gameObject.SetActive(!gameObject.activeSelf);
}
public void InteractNode()
{
this.GetComponent<Collider>().enabled = !this.GetComponent<Collider>().enabled;
this.GetComponent<MeshRenderer>().enabled = !this.GetComponent<MeshRenderer>().enabled;
}
}