Add optional 'default' argument to get_meta()
This commit is contained in:
parent
9433c1d70c
commit
3eb7fc4bfd
3 changed files with 12 additions and 4 deletions
|
|
@ -366,8 +366,10 @@
|
|||
<method name="get_meta" qualifiers="const">
|
||||
<return type="Variant" />
|
||||
<argument index="0" name="name" type="StringName" />
|
||||
<argument index="1" name="default" type="Variant" default="null" />
|
||||
<description>
|
||||
Returns the object's metadata entry for the given [code]name[/code].
|
||||
Throws error if the entry does not exist, unless [code]default[/code] is not [code]null[/code] (in which case the default value will be returned).
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_meta_list" qualifiers="const">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue