Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f5499a7
commit 0eeb26b
Showing
8 changed files
with
7,230 additions
and
431 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
using System.Collections; | ||
using System.Collections.Generic; | ||
using UnityEngine; | ||
using UnityEngine.UI; | ||
|
||
public class ParrotLearnCommand : MonoBehaviour | ||
{ | ||
public RFPlayerConnection rfplayer; | ||
public TMPro.TMP_Dropdown command; | ||
public TMPro.TMP_InputField id; | ||
public TMPro.TMP_InputField reminder; | ||
// Start is called before the first frame update | ||
void Start() | ||
{ | ||
GetComponent<Button>().onClick.AddListener(() => | ||
{ | ||
var cmd = "PARROTLEARN ID " + id.text + " " + command.options[command.value].text; | ||
cmd += string.IsNullOrWhiteSpace(reminder.text) ? "" : " [" + reminder.text + "]"; | ||
rfplayer.SendCommand(cmd); | ||
}); | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.