diff --git a/com.unity.ml-agents.extensions/Runtime/Input/InputActuatorComponent.cs b/com.unity.ml-agents.extensions/Runtime/Input/InputActuatorComponent.cs index fc7d2f4cf0..c3fed4974c 100644 --- a/com.unity.ml-agents.extensions/Runtime/Input/InputActuatorComponent.cs +++ b/com.unity.ml-agents.extensions/Runtime/Input/InputActuatorComponent.cs @@ -20,6 +20,7 @@ namespace Unity.MLAgents.Extensions.Input /// s. /// [RequireComponent(typeof(PlayerInput), typeof(IInputActionAssetProvider))] + [AddComponentMenu("ML Agents/Input Actuator", (int)MenuGroup.Actuators)] public class InputActuatorComponent : ActuatorComponent { InputActionAsset m_InputAsset; @@ -234,7 +235,7 @@ internal static InputControlScheme CreateControlScheme(InputControl device, } var inputControlScheme = new InputControlScheme( - mlAgentsControlSchemeName, + mlAgentsControlSchemeName, deviceRequirements); return inputControlScheme; @@ -261,14 +262,13 @@ internal static void RegisterLayoutBuilder(InputActionMap defaultMap, string lay var builder = new InputControlLayout.Builder() .WithName(layoutName) .WithFormat(mlAgentsLayoutFormat); - for(var i = 0; i < defaultMap.actions.Count; i++) + for (var i = 0; i < defaultMap.actions.Count; i++) { var action = defaultMap.actions[i]; builder.AddControl(action.name) .WithLayout(action.expectedControlType); } return builder.Build(); - }, layoutName); } } diff --git a/com.unity.ml-agents.extensions/Runtime/Match3/Match3ActuatorComponent.cs b/com.unity.ml-agents.extensions/Runtime/Match3/Match3ActuatorComponent.cs index a336b5efbd..4f17e2964f 100644 --- a/com.unity.ml-agents.extensions/Runtime/Match3/Match3ActuatorComponent.cs +++ b/com.unity.ml-agents.extensions/Runtime/Match3/Match3ActuatorComponent.cs @@ -7,6 +7,7 @@ namespace Unity.MLAgents.Extensions.Match3 /// /// Actuator component for a Match3 game. Generates a Match3Actuator at runtime. /// + [AddComponentMenu("ML Agents/Match 3 Actuator", (int)MenuGroup.Actuators)] public class Match3ActuatorComponent : ActuatorComponent { /// diff --git a/com.unity.ml-agents.extensions/Runtime/Match3/Match3SensorComponent.cs b/com.unity.ml-agents.extensions/Runtime/Match3/Match3SensorComponent.cs index bdc24a7c9c..0467d5025b 100644 --- a/com.unity.ml-agents.extensions/Runtime/Match3/Match3SensorComponent.cs +++ b/com.unity.ml-agents.extensions/Runtime/Match3/Match3SensorComponent.cs @@ -1,10 +1,12 @@ using Unity.MLAgents.Sensors; +using UnityEngine; namespace Unity.MLAgents.Extensions.Match3 { /// /// Sensor component for a Match3 game. /// + [AddComponentMenu("ML Agents/Match 3 Sensor", (int)MenuGroup.Sensors)] public class Match3SensorComponent : SensorComponent { /// diff --git a/com.unity.ml-agents.extensions/Runtime/Sensors/GridSensor.cs b/com.unity.ml-agents.extensions/Runtime/Sensors/GridSensor.cs index 01324de74b..583b45d58e 100644 --- a/com.unity.ml-agents.extensions/Runtime/Sensors/GridSensor.cs +++ b/com.unity.ml-agents.extensions/Runtime/Sensors/GridSensor.cs @@ -9,6 +9,7 @@ namespace Unity.MLAgents.Extensions.Sensors /// /// Grid-based sensor. /// + [AddComponentMenu("ML Agents/Grid Sensor", (int)MenuGroup.Sensors)] public class GridSensor : SensorComponent, ISensor, IBuiltInSensor { /// @@ -480,7 +481,6 @@ public BuiltInSensorType GetBuiltInSensorType() return BuiltInSensorType.GridSensor; } - /// /// GetCompressedObservation - Calls Perceive then puts the data stored on the perception buffer /// onto the m_perceptionTexture2D to be converted to a byte array and returned diff --git a/com.unity.ml-agents/Runtime/Constants.cs b/com.unity.ml-agents/Runtime/Constants.cs index 816d88ed6d..4be9eba042 100644 --- a/com.unity.ml-agents/Runtime/Constants.cs +++ b/com.unity.ml-agents/Runtime/Constants.cs @@ -6,6 +6,7 @@ namespace Unity.MLAgents internal enum MenuGroup { Default = 0, - Sensors = 50 + Sensors = 50, + Actuators = 100 } }