提交
This commit is contained in:
@@ -126,10 +126,10 @@ namespace Rewired.Demos {
|
||||
|
||||
// Delete placeholders
|
||||
foreach(Transform t in actionGroupTransform) {
|
||||
Destroy(t.gameObject);
|
||||
Object.Destroy(t.gameObject);
|
||||
}
|
||||
foreach(Transform t in fieldGroupTransform) {
|
||||
Destroy(t.gameObject);
|
||||
Object.Destroy(t.gameObject);
|
||||
}
|
||||
|
||||
// Create Action fields and input field buttons
|
||||
@@ -150,13 +150,13 @@ namespace Rewired.Demos {
|
||||
|
||||
private void CreateUIRow(InputAction action, AxisRange actionRange, string label) {
|
||||
// Create the Action label
|
||||
GameObject labelGo = Instantiate<GameObject>(textPrefab);
|
||||
GameObject labelGo = Object.Instantiate<GameObject>(textPrefab);
|
||||
labelGo.transform.SetParent(actionGroupTransform);
|
||||
labelGo.transform.SetAsLastSibling();
|
||||
labelGo.GetComponent<Text>().text = label;
|
||||
|
||||
// Create the input field button
|
||||
GameObject buttonGo = Instantiate<GameObject>(buttonPrefab);
|
||||
GameObject buttonGo = Object.Instantiate<GameObject>(buttonPrefab);
|
||||
buttonGo.transform.SetParent(fieldGroupTransform);
|
||||
buttonGo.transform.SetAsLastSibling();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user