Skip to content

Commit 37ca3a8

Browse files
committed
Add support for optional parameters
1 parent 48f7814 commit 37ca3a8

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

Diff for: functions/Cursor/showCursor.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ shared: &shared
1616
type: 'bool'
1717
description: |
1818
A boolean value determining whether to disable controls whilst the cursor is showing. *true* implies controls are disabled, *false* implies controls remain enabled.
19+
default: 'true'
1920
returns:
2021
description: |
2122
Returns *true* if the player's cursor was shown or hidden successfully, *false* otherwise.

Diff for: schemas/function.yaml

+9
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,15 @@ $defs:
100100
description:
101101
type: string
102102
description: Describe the usage, contraints and other useful information about the parameter.
103+
default:
104+
type: string
105+
description: |
106+
The default value for this parameter, if none was given in the call to the function.
107+
This property automatically implicitly marks this parameter as optional.
108+
optional:
109+
type: boolean
110+
default: false
111+
description: If set to true, this parameter will be marked as optional.
103112

104113
returns:
105114
type: object

0 commit comments

Comments
 (0)