diff --git a/Assets/Scripts/ArenaPiece.cs b/Assets/Scripts/ArenaPiece.cs index 26a2825..0085b84 100644 --- a/Assets/Scripts/ArenaPiece.cs +++ b/Assets/Scripts/ArenaPiece.cs @@ -157,6 +157,9 @@ public bool IsFull() choosenCombo.chosenOther.isUsed = true; choosenCombo.chosenMine.isUsed = true; + choosenCombo.chosenMine.myMatch = choosenCombo.chosenOther; + choosenCombo.chosenOther.myMatch = choosenCombo.chosenMine; + Transform trn = TransformPiece(choosenCombo.chosenMine, choosenCombo.chosenOther, other, pieceDistance); diff --git a/Assets/Scripts/Connector.cs b/Assets/Scripts/Connector.cs index a7ea375..ccd63f3 100644 --- a/Assets/Scripts/Connector.cs +++ b/Assets/Scripts/Connector.cs @@ -18,7 +18,8 @@ public class Connector : MonoBehaviour, IComparable [SerializeField] public ConnectorColor color; public Vector3 heading => transform.forward; - + [ReadOnly] + public Connector myMatch = null; [HideInInspector] public bool isUsed = false; public int pins = 0;