Skip to content

Commit

Permalink
Merge pull request #9266 from markdibarry/default_details
Browse files Browse the repository at this point in the history
Add links for overriding default export value in C#
  • Loading branch information
AThousandShips committed Apr 22, 2024
2 parents 4053dbc + 7aa096e commit 29a8e10
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tutorials/scripting/c_sharp/c_sharp_exports.rst
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,10 @@ Properties with a backing field use the default value of the backing field.
value for ``int``, ``0``. However, when running the scene or inspecting a
node with an attached tool script, ``_number`` will be ``2``, and
``NumberWithBackingField`` will return ``5``. This difference may cause
confusing behavior. To avoid this, don't use complex properties.
confusing behavior. To avoid this, don't use complex properties. Alternatively,
if the default value can be explicitly specified, it can be overridden with the
:ref:`_PropertyCanRevert() <class_Object_private_method__property_can_revert>` and
:ref:`_PropertyGetRevert() <class_Object_private_method__property_get_revert>` methods.

Any type of ``Resource`` or ``Node`` can be exported. The property editor shows
a user-friendly assignment dialog for these types. This can be used instead of
Expand Down

0 comments on commit 29a8e10

Please sign in to comment.