StellarXipher/Assets/Puzzles/Untangle/Scripts/Connection.cs
EthanPisani 3b12b691cf
Some checks failed
Build project / Build for (StandaloneWindows64, 6000.0.37f1) (push) Has been cancelled
Build project / Publish to itch.io (StandaloneLinux64) (push) Has been cancelled
Build project / Publish to itch.io (StandaloneWindows64) (push) Has been cancelled
Build project / Build for (StandaloneLinux64, 6000.0.37f1) (push) Has been cancelled
add most of untangle game
2025-04-20 19:28:52 -04:00

19 lines
406 B
C#

using UnityEngine;
[System.Serializable]
public class Connection
{
public Point a, b;
public LineRenderer line;
public void UpdateLine()
{
line.SetPosition(0, a.transform.position);
line.SetPosition(1, b.transform.position);
}
public bool SharesPointWith(Connection other)
{
return a == other.a || a == other.b || b == other.a || b == other.b;
}
}