Loading Assets/Scripts/Domain/CustomInput.cs +1 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ namespace Domain { _readers.Add(typeof(TjReader), new TjReader(_history)); _readers.Add(typeof(LlReader), new LlReader(_history)); _readers.Add(typeof(SsReader), new SsReader(_history)); _readers.Add(typeof(AObertaReader), new AObertaReader(_history)); } public void UpdateInput() { Loading Assets/Scripts/Domain/Input/AObertaReader.cs 0 → 100644 +8 −0 Original line number Diff line number Diff line using System.Collections.Generic; using System.Linq; namespace Domain.Input { public class AObertaReader : SequentialInputReader { public AObertaReader(KeyHistory history) : base(history, new List<int>{ 0xBA, 0x41 }) { } } } No newline at end of file Assets/Scripts/Domain/Input/AObertaReader.cs.meta 0 → 100644 +3 −0 Original line number Diff line number Diff line fileFormatVersion: 2 guid: d9af0ad3cdac447e803e2d16325ec74f timeCreated: 1713278245 No newline at end of file Assets/Scripts/Domain/KeyHistory.cs +3 −3 Original line number Diff line number Diff line Loading @@ -5,9 +5,9 @@ namespace Domain { public class KeyHistory { private readonly LimitedSizeList<int> _lastPresses = new(10); private readonly int[] _customKeys = { 191, 51, 222, 186 }; private readonly bool[] _isPressed = new bool[26 + 5]; private readonly bool[] _wasPressed = new bool[26 + 5]; private readonly int[] _customKeys = { 191, 51, 222, 186, 0xBA }; private readonly bool[] _isPressed = new bool[26 + 6]; private readonly bool[] _wasPressed = new bool[26 + 6]; public void KeyPressed(int key) => _lastPresses.Add(key); Loading Assets/Scripts/View/UI/ExpressionInput.cs +2 −0 Original line number Diff line number Diff line Loading @@ -47,6 +47,8 @@ namespace View.UI { _click.Execute(); if (_customInput.KeyDown(typeof(TxReader))) _click.Execute(); if(_customInput.KeyDown(typeof(AObertaReader))) _click.Execute(); } public void UpdateView(int score) { Loading Loading
Assets/Scripts/Domain/CustomInput.cs +1 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ namespace Domain { _readers.Add(typeof(TjReader), new TjReader(_history)); _readers.Add(typeof(LlReader), new LlReader(_history)); _readers.Add(typeof(SsReader), new SsReader(_history)); _readers.Add(typeof(AObertaReader), new AObertaReader(_history)); } public void UpdateInput() { Loading
Assets/Scripts/Domain/Input/AObertaReader.cs 0 → 100644 +8 −0 Original line number Diff line number Diff line using System.Collections.Generic; using System.Linq; namespace Domain.Input { public class AObertaReader : SequentialInputReader { public AObertaReader(KeyHistory history) : base(history, new List<int>{ 0xBA, 0x41 }) { } } } No newline at end of file
Assets/Scripts/Domain/Input/AObertaReader.cs.meta 0 → 100644 +3 −0 Original line number Diff line number Diff line fileFormatVersion: 2 guid: d9af0ad3cdac447e803e2d16325ec74f timeCreated: 1713278245 No newline at end of file
Assets/Scripts/Domain/KeyHistory.cs +3 −3 Original line number Diff line number Diff line Loading @@ -5,9 +5,9 @@ namespace Domain { public class KeyHistory { private readonly LimitedSizeList<int> _lastPresses = new(10); private readonly int[] _customKeys = { 191, 51, 222, 186 }; private readonly bool[] _isPressed = new bool[26 + 5]; private readonly bool[] _wasPressed = new bool[26 + 5]; private readonly int[] _customKeys = { 191, 51, 222, 186, 0xBA }; private readonly bool[] _isPressed = new bool[26 + 6]; private readonly bool[] _wasPressed = new bool[26 + 6]; public void KeyPressed(int key) => _lastPresses.Add(key); Loading
Assets/Scripts/View/UI/ExpressionInput.cs +2 −0 Original line number Diff line number Diff line Loading @@ -47,6 +47,8 @@ namespace View.UI { _click.Execute(); if (_customInput.KeyDown(typeof(TxReader))) _click.Execute(); if(_customInput.KeyDown(typeof(AObertaReader))) _click.Execute(); } public void UpdateView(int score) { Loading