Skip to content

Commit 03b4c6f

Browse files
committed
Further updates to improve the documentation page score
1 parent d05ace0 commit 03b4c6f

File tree

1 file changed

+18
-0
lines changed
  • Packages/com.unity.inputsystem/InputSystem/Plugins/PlayerInput

1 file changed

+18
-0
lines changed

Packages/com.unity.inputsystem/InputSystem/Plugins/PlayerInput/PlayerInput.cs

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1987,6 +1987,21 @@ private void SwitchControlSchemeInternal(ref InputControlScheme controlScheme, p
19871987
/// Represents an event invoked in response to actions being triggered.
19881988
///
19891989
/// Contains the ID and name of the <see cref="InputAction"/> being triggered and the associated <see cref="UnityAction"/> to handle the action response.
1990+
///
1991+
/// The list of action events is specified in <see cref="PlayerInput"/> Editor UI based on the selected <see cref="InputActionAsset"/>.
1992+
/// The individual action callbacks are then specified in a <see cref="MonoBehaviour"/>.
1993+
///
1994+
/// <example>
1995+
/// <code>
1996+
/// public class MyPlayerScript : MonoBehaviour
1997+
/// {
1998+
/// void OnFireEvent(InputAction.CallbackContext context)
1999+
/// {
2000+
/// // Handle fire event
2001+
/// }
2002+
/// }
2003+
/// </code>
2004+
/// </example>
19902005
/// </remarks>
19912006
/// <seealso cref="PlayerInput.actionEvents"/>
19922007
[Serializable]
@@ -2011,6 +2026,7 @@ public class ActionEvent : UnityEvent<InputAction.CallbackContext>
20112026
/// <remarks>
20122027
/// The event will not have an associated action.
20132028
/// </remarks>
2029+
/// <seealso cref="PlayerInput.actionEvents"/>
20142030
public ActionEvent()
20152031
{
20162032
}
@@ -2024,6 +2040,7 @@ public ActionEvent()
20242040
/// <param name="action">The action to associate with the event. The action must be part of an action asset.</param>
20252041
/// <exception cref="ArgumentNullException">The action is <c>null</c>.</exception>
20262042
/// <exception cref="ArgumentException">The action is not part of an action asset.</exception>
2043+
/// <seealso cref="PlayerInput.actionEvents"/>
20272044
public ActionEvent(InputAction action)
20282045
{
20292046
if (action == null)
@@ -2045,6 +2062,7 @@ public ActionEvent(InputAction action)
20452062
/// </remarks>
20462063
/// <param name="actionGUID">Action GUID</param>
20472064
/// <param name="name">Name of the action</param>
2065+
/// <seealso cref="PlayerInput.actionEvents"/>
20482066
public ActionEvent(Guid actionGUID, string name = null)
20492067
{
20502068
m_ActionId = actionGUID.ToString();

0 commit comments

Comments
 (0)