mirror of
https://github.com/godotengine/godot-docs-l10n.git
synced 2026-01-04 10:09:56 +03:00
147 lines
7.8 KiB
Plaintext
147 lines
7.8 KiB
Plaintext
# SOME DESCRIPTIVE TITLE.
|
|
# Copyright (C) 2014-2020, Juan Linietsky, Ariel Manzur and the Godot community (CC-BY 3.0)
|
|
# This file is distributed under the same license as the Godot Engine package.
|
|
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
|
#
|
|
#, fuzzy
|
|
msgid ""
|
|
msgstr ""
|
|
"Project-Id-Version: Godot Engine latest\n"
|
|
"Report-Msgid-Bugs-To: \n"
|
|
"POT-Creation-Date: 2020-07-30 19:14+0200\n"
|
|
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
|
"MIME-Version: 1.0\n"
|
|
"Content-Type: text/plain; charset=UTF-8\n"
|
|
"Content-Transfer-Encoding: 8bit\n"
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:4
|
|
msgid "GDScript exports"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:7
|
|
msgid "Introduction to exports"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:9
|
|
msgid "In Godot, class members can be exported. This means their value gets saved along with the resource (such as the :ref:`scene <class_PackedScene>`) they're attached to. They will also be available for editing in the property editor. Exporting is done by using the ``export`` keyword::"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:18
|
|
msgid "An exported variable must be initialized to a constant expression or have an export hint in the form of an argument to the ``export`` keyword (see the *Examples* section below)."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:22
|
|
msgid "One of the fundamental benefits of exporting member variables is to have them visible and editable in the editor. This way, artists and game designers can modify values that later influence how the program runs. For this, a special export syntax is provided."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:29
|
|
msgid "Exporting properties can also be done in other languages such as C#. The syntax varies depending on the language."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:33
|
|
msgid "Examples"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:136
|
|
msgid "It must be noted that even if the script is not being run while in the editor, the exported properties are still editable. This can be used in conjunction with a :ref:`script in \"tool\" mode <doc_gdscript_tool_mode>`."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:141
|
|
msgid "Exporting bit flags"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:143
|
|
msgid "Integers used as bit flags can store multiple ``true``/``false`` (boolean) values in one property. By using the export hint ``int, FLAGS, ...``, they can be set from the editor::"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:150
|
|
msgid "You must provide a string description for each flag. In this example, ``Fire`` has value 1, ``Water`` has value 2, ``Earth`` has value 4 and ``Wind`` corresponds to value 8. Usually, constants should be defined accordingly (e.g. ``const ELEMENT_WIND = 8`` and so on)."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:155
|
|
msgid "Export hints are also provided for the physics and render layers defined in the project settings::"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:162
|
|
msgid "Using bit flags requires some understanding of bitwise operations. If in doubt, use boolean variables instead."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:166
|
|
msgid "Exporting arrays"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:168
|
|
msgid "Exported arrays can have initializers, but they must be constant expressions."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:170
|
|
msgid "If the exported array specifies a type which inherits from Resource, the array values can be set in the inspector by dragging and dropping multiple files from the FileSystem dock at once."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:208
|
|
msgid "Setting exported variables from a tool script"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:210
|
|
msgid "When changing an exported variable's value from a script in :ref:`doc_gdscript_tool_mode`, the value in the inspector won't be updated automatically. To update it, call :ref:`property_list_changed_notify() <class_Object_method_property_list_changed_notify>` after setting the exported variable's value."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:217
|
|
msgid "Advanced exports"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:219
|
|
msgid "Not every type of export can be provided on the level of the language itself to avoid unnecessary design complexity. The following describes some more or less common exporting features which can be implemented with a low-level API."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:223
|
|
msgid "Before reading further, you should get familiar with the way properties are handled and how they can be customized with :ref:`_set() <class_Object_method__get_property_list>`, :ref:`_get() <class_Object_method__get_property_list>`, and :ref:`_get_property_list() <class_Object_method__get_property_list>` methods as described in :ref:`doc_accessing_data_or_logic_from_object`."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:230
|
|
msgid "For binding properties using the above methods in C++, see :ref:`doc_binding_properties_using_set_get_property_list`."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:233
|
|
msgid "The script must operate in the ``tool`` mode so the above methods can work from within the editor."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:237
|
|
msgid "Adding script categories"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:239
|
|
msgid "For better visual distinguishing of properties, a special script category can be embedded into the inspector to act as a separator. ``Script Variables`` is one example of a built-in category."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:256
|
|
msgid "``name`` is the name of a category to be added to the inspector;"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:258
|
|
msgid "``PROPERTY_USAGE_CATEGORY`` indicates that the property should be treated as a script category specifically, so the type ``TYPE_NIL`` can be ignored as it won't be actually used for the scripting logic, yet it must be defined anyway."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:263
|
|
msgid "Grouping properties"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:265
|
|
msgid "A list of properties with similar names can be grouped."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:279
|
|
msgid "``name`` is the name of a group which is going to be displayed as collapsible list of properties;"
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:282
|
|
msgid "every successive property added after the group property will be collapsed and shortened as determined by the prefix defined via the ``hint_string`` key. For instance, ``rotate_speed`` is going to be shortened to ``speed`` in this case."
|
|
msgstr ""
|
|
|
|
#: ../../docs/getting_started/scripting/gdscript/gdscript_exports.rst:286
|
|
msgid "``PROPERTY_USAGE_GROUP`` indicates that the property should be treated as a script group specifically, so the type ``TYPE_NIL`` can be ignored as it won't be actually used for the scripting logic, yet it must be defined anyway."
|
|
msgstr ""
|
|
|