Skip to content

Commit

Permalink
Set mobile touch count in terminal inspector
Browse files Browse the repository at this point in the history
  • Loading branch information
omid3098 committed Jul 23, 2017
1 parent 6aa15c6 commit 9db54e8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
Binary file modified Assets/OpenTerminal/Sample/Scene/SampleScene.unity
Binary file not shown.
2 changes: 2 additions & 0 deletions Assets/OpenTerminal/Scripts/Terminal.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,13 @@ public class Terminal : MonoBehaviour
private TerminalInputHandler inputHandler;
private TerminalGUI terminalGui;
public TouchScreenKeyboard touchScreenKeyboard;
public int mobileTouchCount = 4;

void Awake()
{
instance = this;
if (config == null) config = Resources.Load<TerminalConfig>("Config/ZSH");
if (mobileTouchCount <= 0) mobileTouchCount = 4;
autoCompIndex = 0;
autoCompList = new List<string>();
terminalMethods = new TerminalMethods();
Expand Down
2 changes: 1 addition & 1 deletion Assets/OpenTerminal/Scripts/TerminalInputHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ private bool MobileInput()
terminal.touchScreenKeyboard = null;
}
}
if (Input.touchCount == 4)
if (Input.touchCount == terminal.mobileTouchCount)
{
ellapsedTime += Time.deltaTime;
}
Expand Down

0 comments on commit 9db54e8

Please sign in to comment.