comment pass
This commit is contained in:
@@ -16,8 +16,12 @@ namespace EscapeRoomEngine.Desert.Runtime.Puzzle_B
|
||||
public List<int> stateIndices;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The main component for the hexagon module.
|
||||
/// </summary>
|
||||
public class PuzzleB : StatePuzzle
|
||||
{
|
||||
[Tooltip("How many seconds the buttons should be disabled until another input is accepted.")]
|
||||
[SerializeField] [Min(0)]
|
||||
private float buttonCooldown;
|
||||
[ValidateInput("CorrectRotatorCount")]
|
||||
@@ -86,6 +90,9 @@ namespace EscapeRoomEngine.Desert.Runtime.Puzzle_B
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Switch all rotators specified by a given action.
|
||||
/// </summary>
|
||||
private void Switch(ButtonAction action)
|
||||
{
|
||||
for (var i = 0; i < action.stateIndices.Count; i++)
|
||||
@@ -99,7 +106,7 @@ namespace EscapeRoomEngine.Desert.Runtime.Puzzle_B
|
||||
}
|
||||
}
|
||||
|
||||
[UsedImplicitly]
|
||||
[UsedImplicitly] // used for field validation
|
||||
private bool CorrectRotatorCount(List<Rotator> list) => list != null && list.Count == stateCount;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user