DO-31 Feat: 이전에 표시했던 금수 마크 제거 함수 추가
This commit is contained in:
parent
ea1c64023d
commit
2e97528c75
@ -117,7 +117,7 @@ public class GameLogic : MonoBehaviour
|
||||
private void UpdateForbiddenMoves()
|
||||
{
|
||||
// TODO: 이전 금수 표시 제거
|
||||
|
||||
ClearForbiddenMarks();
|
||||
|
||||
// 흑돌 차례에만 금수 규칙 적용
|
||||
if (currentTurn == Enums.PlayerType.PlayerA)
|
||||
@ -137,5 +137,18 @@ public class GameLogic : MonoBehaviour
|
||||
}
|
||||
}
|
||||
|
||||
// 이전에 표시된 금수 마크 제거
|
||||
private void ClearForbiddenMarks()
|
||||
{
|
||||
foreach (var forbiddenMove in _forbiddenMoves)
|
||||
{
|
||||
Vector2Int pos = forbiddenMove.position;
|
||||
if (_board[pos.x, pos.y] == Enums.PlayerType.None)
|
||||
{
|
||||
SetStoneNewState(Enums.StoneState.None, pos.x, pos.y);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user