Use `[codeblock lang=text]` more often in class ref

This commit is contained in:
Micky 2024-03-09 16:58:44 +01:00
parent dc91479082
commit 328b00774b
15 changed files with 46 additions and 46 deletions

View File

@ -368,7 +368,7 @@
<param index="1" name="curve" type="float" /> <param index="1" name="curve" type="float" />
<description> <description>
Returns an "eased" value of [param x] based on an easing function defined with [param curve]. This easing function is based on an exponent. The [param curve] can be any floating-point number, with specific values leading to the following behaviors: Returns an "eased" value of [param x] based on an easing function defined with [param curve]. This easing function is based on an exponent. The [param curve] can be any floating-point number, with specific values leading to the following behaviors:
[codeblock] [codeblock lang=text]
- Lower than -1.0 (exclusive): Ease in-out - Lower than -1.0 (exclusive): Ease in-out
- 1.0: Linear - 1.0: Linear
- Between -1.0 and 0.0 (exclusive): Ease out-in - Between -1.0 and 0.0 (exclusive): Ease out-in
@ -460,8 +460,8 @@
var x = i * 0.5 - 1.5 var x = i * 0.5 - 1.5
print("%4.1f %4.1f | %4.1f" % [x, fmod(x, 1.5), fposmod(x, 1.5)]) print("%4.1f %4.1f | %4.1f" % [x, fmod(x, 1.5), fposmod(x, 1.5)])
[/codeblock] [/codeblock]
Produces: Prints:
[codeblock] [codeblock lang=text]
(x) (fmod(x, 1.5)) (fposmod(x, 1.5)) (x) (fmod(x, 1.5)) (fposmod(x, 1.5))
-1.5 -0.0 | 0.0 -1.5 -0.0 | 0.0
-1.0 -1.0 | 0.5 -1.0 -1.0 | 0.5
@ -818,8 +818,8 @@
for i in range(-3, 4): for i in range(-3, 4):
print("%2d %2d | %2d" % [i, i % 3, posmod(i, 3)]) print("%2d %2d | %2d" % [i, i % 3, posmod(i, 3)])
[/codeblock] [/codeblock]
Produces: Prints:
[codeblock] [codeblock lang=text]
(i) (i % 3) (posmod(i, 3)) (i) (i % 3) (posmod(i, 3))
-3 0 | 0 -3 0 | 0
-2 -2 | 1 -2 -2 | 1
@ -1457,7 +1457,7 @@
[/csharp] [/csharp]
[/codeblocks] [/codeblocks]
Prints: Prints:
[codeblock] [codeblock lang=text]
{ {
"a": 1, "a": 1,
"b": 2 "b": 2

View File

@ -5,7 +5,7 @@
</brief_description> </brief_description>
<description> <description>
This helper class can be used to store [Variant] values on the filesystem using INI-style formatting. The stored values are identified by a section and a key: This helper class can be used to store [Variant] values on the filesystem using INI-style formatting. The stored values are identified by a section and a key:
[codeblock] [codeblock lang=text]
[section] [section]
some_key=42 some_key=42
string_example="Hello World3D!" string_example="Hello World3D!"

View File

@ -249,7 +249,7 @@
<param index="0" name="position" type="Vector2i" /> <param index="0" name="position" type="Vector2i" />
<description> <description>
Returns the ID of the window at the specified screen [param position] (in pixels). On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this: Returns the ID of the window at the specified screen [param position] (in pixels). On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this:
[codeblock] [codeblock lang=text]
* (0, 0) +-------+ * (0, 0) +-------+
| | | |
+-------------+ | | +-------------+ | |
@ -282,7 +282,7 @@
[b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag]. [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -308,7 +308,7 @@
[b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag]. [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -334,7 +334,7 @@
[b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag]. [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -361,7 +361,7 @@
[b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag]. [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -386,7 +386,7 @@
[b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag]. [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -415,7 +415,7 @@
[b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag]. [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -441,7 +441,7 @@
[b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag]. [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -459,7 +459,7 @@
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value. Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -479,7 +479,7 @@
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value. Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -495,7 +495,7 @@
Removes all items from the global menu with ID [param menu_root]. Removes all items from the global menu with ID [param menu_root].
[b]Note:[/b] This method is implemented only on macOS. [b]Note:[/b] This method is implemented only on macOS.
[b]Supported system menu IDs:[/b] [b]Supported system menu IDs:[/b]
[codeblock] [codeblock lang=text]
"_main" - Main menu (macOS). "_main" - Main menu (macOS).
"_dock" - Dock popup menu (macOS). "_dock" - Dock popup menu (macOS).
"_apple" - Apple menu (macOS, custom items added before "Services"). "_apple" - Apple menu (macOS, custom items added before "Services").
@ -1022,7 +1022,7 @@
Returns the dots per inch density of the specified screen. If [param screen] is [constant SCREEN_OF_MAIN_WINDOW] (the default value), a screen with the main window will be used. Returns the dots per inch density of the specified screen. If [param screen] is [constant SCREEN_OF_MAIN_WINDOW] (the default value), a screen with the main window will be used.
[b]Note:[/b] On macOS, returned value is inaccurate if fractional display scaling mode is used. [b]Note:[/b] On macOS, returned value is inaccurate if fractional display scaling mode is used.
[b]Note:[/b] On Android devices, the actual screen densities are grouped into six generalized densities: [b]Note:[/b] On Android devices, the actual screen densities are grouped into six generalized densities:
[codeblock] [codeblock lang=text]
ldpi - 120 dpi ldpi - 120 dpi
mdpi - 160 dpi mdpi - 160 dpi
hdpi - 240 dpi hdpi - 240 dpi
@ -1072,7 +1072,7 @@
<param index="0" name="screen" type="int" default="-1" /> <param index="0" name="screen" type="int" default="-1" />
<description> <description>
Returns the screen's top-left corner position in pixels. On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this: Returns the screen's top-left corner position in pixels. On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this:
[codeblock] [codeblock lang=text]
* (0, 0) +-------+ * (0, 0) +-------+
| | | |
+-------------+ | | +-------------+ | |
@ -1674,7 +1674,7 @@
<param index="1" name="window_id" type="int" default="0" /> <param index="1" name="window_id" type="int" default="0" />
<description> <description>
Sets the position of the given window to [param position]. On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this: Sets the position of the given window to [param position]. On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this:
[codeblock] [codeblock lang=text]
* (0, 0) +-------+ * (0, 0) +-------+
| | | |
+-------------+ | | +-------------+ | |

View File

@ -17,7 +17,7 @@
<description> <description>
Returns the absolute path to the user's cache folder. This folder should be used for temporary data that can be removed safely whenever the editor is closed (such as generated resource thumbnails). Returns the absolute path to the user's cache folder. This folder should be used for temporary data that can be removed safely whenever the editor is closed (such as generated resource thumbnails).
[b]Default paths per platform:[/b] [b]Default paths per platform:[/b]
[codeblock] [codeblock lang=text]
- Windows: %LOCALAPPDATA%\Godot\ - Windows: %LOCALAPPDATA%\Godot\
- macOS: ~/Library/Caches/Godot/ - macOS: ~/Library/Caches/Godot/
- Linux: ~/.cache/godot/ - Linux: ~/.cache/godot/
@ -29,7 +29,7 @@
<description> <description>
Returns the absolute path to the user's configuration folder. This folder should be used for [i]persistent[/i] user configuration files. Returns the absolute path to the user's configuration folder. This folder should be used for [i]persistent[/i] user configuration files.
[b]Default paths per platform:[/b] [b]Default paths per platform:[/b]
[codeblock] [codeblock lang=text]
- Windows: %APPDATA%\Godot\ (same as `get_data_dir()`) - Windows: %APPDATA%\Godot\ (same as `get_data_dir()`)
- macOS: ~/Library/Application Support/Godot/ (same as `get_data_dir()`) - macOS: ~/Library/Application Support/Godot/ (same as `get_data_dir()`)
- Linux: ~/.config/godot/ - Linux: ~/.config/godot/
@ -41,7 +41,7 @@
<description> <description>
Returns the absolute path to the user's data folder. This folder should be used for [i]persistent[/i] user data files such as installed export templates. Returns the absolute path to the user's data folder. This folder should be used for [i]persistent[/i] user data files such as installed export templates.
[b]Default paths per platform:[/b] [b]Default paths per platform:[/b]
[codeblock] [codeblock lang=text]
- Windows: %APPDATA%\Godot\ (same as `get_config_dir()`) - Windows: %APPDATA%\Godot\ (same as `get_config_dir()`)
- macOS: ~/Library/Application Support/Godot/ (same as `get_config_dir()`) - macOS: ~/Library/Application Support/Godot/ (same as `get_config_dir()`)
- Linux: ~/.local/share/godot/ - Linux: ~/.local/share/godot/

View File

@ -131,7 +131,7 @@
Returns the next value of the file in CSV (Comma-Separated Values) format. You can pass a different delimiter [param delim] to use other than the default [code]","[/code] (comma). This delimiter must be one-character long, and cannot be a double quotation mark. Returns the next value of the file in CSV (Comma-Separated Values) format. You can pass a different delimiter [param delim] to use other than the default [code]","[/code] (comma). This delimiter must be one-character long, and cannot be a double quotation mark.
Text is interpreted as being UTF-8 encoded. Text values must be enclosed in double quotes if they include the delimiter character. Double quotes within a text value can be escaped by doubling their occurrence. Text is interpreted as being UTF-8 encoded. Text values must be enclosed in double quotes if they include the delimiter character. Double quotes within a text value can be escaped by doubling their occurrence.
For example, the following CSV lines are valid and will be properly parsed as two strings each: For example, the following CSV lines are valid and will be properly parsed as two strings each:
[codeblock] [codeblock lang=text]
Alice,"Hello, Bob!" Alice,"Hello, Bob!"
Bob,Alice! What a surprise! Bob,Alice! What a surprise!
Alice,"I thought you'd reply with ""Hello, world""." Alice,"I thought you'd reply with ""Hello, world""."

View File

@ -66,7 +66,7 @@
Represents the localized label printed on the key in the current keyboard layout, which corresponds to one of the [enum Key] constants or any valid Unicode character. Represents the localized label printed on the key in the current keyboard layout, which corresponds to one of the [enum Key] constants or any valid Unicode character.
For keyboard layouts with a single label on the key, it is equivalent to [member keycode]. For keyboard layouts with a single label on the key, it is equivalent to [member keycode].
To get a human-readable representation of the [InputEventKey], use [code]OS.get_keycode_string(event.key_label)[/code] where [code]event[/code] is the [InputEventKey]. To get a human-readable representation of the [InputEventKey], use [code]OS.get_keycode_string(event.key_label)[/code] where [code]event[/code] is the [InputEventKey].
[codeblock] [codeblock lang=text]
+-----+ +-----+ +-----+ +-----+
| Q | | Q | - "Q" - keycode | Q | | Q | - "Q" - keycode
| Й | | ض | - "Й" and "ض" - key_label | Й | | ض | - "Й" and "ض" - key_label
@ -76,7 +76,7 @@
<member name="keycode" type="int" setter="set_keycode" getter="get_keycode" enum="Key" default="0"> <member name="keycode" type="int" setter="set_keycode" getter="get_keycode" enum="Key" default="0">
Latin label printed on the key in the current keyboard layout, which corresponds to one of the [enum Key] constants. Latin label printed on the key in the current keyboard layout, which corresponds to one of the [enum Key] constants.
To get a human-readable representation of the [InputEventKey], use [code]OS.get_keycode_string(event.keycode)[/code] where [code]event[/code] is the [InputEventKey]. To get a human-readable representation of the [InputEventKey], use [code]OS.get_keycode_string(event.keycode)[/code] where [code]event[/code] is the [InputEventKey].
[codeblock] [codeblock lang=text]
+-----+ +-----+ +-----+ +-----+
| Q | | Q | - "Q" - keycode | Q | | Q | - "Q" - keycode
| Й | | ض | - "Й" and "ض" - key_label | Й | | ض | - "Й" and "ض" - key_label

View File

@ -383,7 +383,7 @@
Fetches a node. The [NodePath] can either be a relative path (from this node), or an absolute path (from the [member SceneTree.root]) to a node. If [param path] does not point to a valid node, generates an error and returns [code]null[/code]. Attempts to access methods on the return value will result in an [i]"Attempt to call &lt;method&gt; on a null instance."[/i] error. Fetches a node. The [NodePath] can either be a relative path (from this node), or an absolute path (from the [member SceneTree.root]) to a node. If [param path] does not point to a valid node, generates an error and returns [code]null[/code]. Attempts to access methods on the return value will result in an [i]"Attempt to call &lt;method&gt; on a null instance."[/i] error.
[b]Note:[/b] Fetching by absolute path only works when the node is inside the scene tree (see [method is_inside_tree]). [b]Note:[/b] Fetching by absolute path only works when the node is inside the scene tree (see [method is_inside_tree]).
[b]Example:[/b] Assume this method is called from the Character node, inside the following tree: [b]Example:[/b] Assume this method is called from the Character node, inside the following tree:
[codeblock] [codeblock lang=text]
┖╴root ┖╴root
┠╴Character (you are here!) ┠╴Character (you are here!)
┃ ┠╴Sword ┃ ┠╴Sword
@ -514,8 +514,8 @@
<return type="String" /> <return type="String" />
<description> <description>
Returns the tree as a [String]. Used mainly for debugging purposes. This version displays the path relative to the current node, and is good for copy/pasting into the [method get_node] function. It also can be used in game UI/UX. Returns the tree as a [String]. Used mainly for debugging purposes. This version displays the path relative to the current node, and is good for copy/pasting into the [method get_node] function. It also can be used in game UI/UX.
[b]Example output:[/b] May print, for example:
[codeblock] [codeblock lang=text]
TheGame TheGame
TheGame/Menu TheGame/Menu
TheGame/Menu/Label TheGame/Menu/Label
@ -529,8 +529,8 @@
<return type="String" /> <return type="String" />
<description> <description>
Similar to [method get_tree_string], this returns the tree as a [String]. This version displays a more graphical representation similar to what is displayed in the Scene Dock. It is useful for inspecting larger trees. Similar to [method get_tree_string], this returns the tree as a [String]. This version displays a more graphical representation similar to what is displayed in the Scene Dock. It is useful for inspecting larger trees.
[b]Example output:[/b] May print, for example:
[codeblock] [codeblock lang=text]
┖╴TheGame ┖╴TheGame
┠╴Menu ┠╴Menu
┃ ┠╴Label ┃ ┠╴Label
@ -716,8 +716,8 @@
<return type="void" /> <return type="void" />
<description> <description>
Prints the node and its children to the console, recursively. The node does not have to be inside the tree. This method outputs [NodePath]s relative to this node, and is good for copy/pasting into [method get_node]. See also [method print_tree_pretty]. Prints the node and its children to the console, recursively. The node does not have to be inside the tree. This method outputs [NodePath]s relative to this node, and is good for copy/pasting into [method get_node]. See also [method print_tree_pretty].
[b]Example output:[/b] May print, for example:
[codeblock] [codeblock lang=text]
. .
Menu Menu
Menu/Label Menu/Label
@ -731,8 +731,8 @@
<return type="void" /> <return type="void" />
<description> <description>
Prints the node and its children to the console, recursively. The node does not have to be inside the tree. Similar to [method print_tree], but the graphical representation looks like what is displayed in the editor's Scene dock. It is useful for inspecting larger trees. Prints the node and its children to the console, recursively. The node does not have to be inside the tree. Similar to [method print_tree], but the graphical representation looks like what is displayed in the editor's Scene dock. It is useful for inspecting larger trees.
[b]Example output:[/b] May print, for example:
[codeblock] [codeblock lang=text]
┖╴TheGame ┖╴TheGame
┠╴Menu ┠╴Menu
┃ ┠╴Label ┃ ┠╴Label

View File

@ -969,7 +969,7 @@
The command-line arguments to append to Godot's own command line when running the project. This doesn't affect the editor itself. The command-line arguments to append to Godot's own command line when running the project. This doesn't affect the editor itself.
It is possible to make another executable run Godot by using the [code]%command%[/code] placeholder. The placeholder will be replaced with Godot's own command line. Program-specific arguments should be placed [i]before[/i] the placeholder, whereas Godot-specific arguments should be placed [i]after[/i] the placeholder. It is possible to make another executable run Godot by using the [code]%command%[/code] placeholder. The placeholder will be replaced with Godot's own command line. Program-specific arguments should be placed [i]before[/i] the placeholder, whereas Godot-specific arguments should be placed [i]after[/i] the placeholder.
For example, this can be used to force the project to run on the dedicated GPU in an NVIDIA Optimus system on Linux: For example, this can be used to force the project to run on the dedicated GPU in an NVIDIA Optimus system on Linux:
[codeblock] [codeblock lang=text]
prime-run %command% prime-run %command%
[/codeblock] [/codeblock]
</member> </member>
@ -2855,7 +2855,7 @@
<member name="rendering/vrs/texture" type="String" setter="" getter="" default="&quot;&quot;"> <member name="rendering/vrs/texture" type="String" setter="" getter="" default="&quot;&quot;">
If [member rendering/vrs/mode] is set to [b]Texture[/b], this is the path to default texture loaded as the VRS image. If [member rendering/vrs/mode] is set to [b]Texture[/b], this is the path to default texture loaded as the VRS image.
The texture [i]must[/i] use a lossless compression format so that colors can be matched precisely. The following VRS densities are mapped to various colors, with brighter colors representing a lower level of shading precision: The texture [i]must[/i] use a lossless compression format so that colors can be matched precisely. The following VRS densities are mapped to various colors, with brighter colors representing a lower level of shading precision:
[codeblock] [codeblock lang=text]
- 1×1 = rgb(0, 0, 0) - #000000 - 1×1 = rgb(0, 0, 0) - #000000
- 1×2 = rgb(0, 85, 0) - #005500 - 1×2 = rgb(0, 85, 0) - #005500
- 2×1 = rgb(85, 0, 0) - #550000 - 2×1 = rgb(85, 0, 0) - #550000

View File

@ -2576,7 +2576,7 @@
<description> <description>
Set the entire data to use for drawing the [param multimesh] at once to [param buffer] (such as instance transforms and colors). [param buffer]'s size must match the number of instances multiplied by the per-instance data size (which depends on the enabled MultiMesh fields). Otherwise, an error message is printed and nothing is rendered. See also [method multimesh_get_buffer]. Set the entire data to use for drawing the [param multimesh] at once to [param buffer] (such as instance transforms and colors). [param buffer]'s size must match the number of instances multiplied by the per-instance data size (which depends on the enabled MultiMesh fields). Otherwise, an error message is printed and nothing is rendered. See also [method multimesh_get_buffer].
The per-instance data size and expected data order is: The per-instance data size and expected data order is:
[codeblock] [codeblock lang=text]
2D: 2D:
- Position: 8 floats (8 floats for Transform2D) - Position: 8 floats (8 floats for Transform2D)
- Position + Vertex color: 12 floats (8 floats for Transform2D, 4 floats for Color) - Position + Vertex color: 12 floats (8 floats for Transform2D, 4 floats for Color)

View File

@ -6,7 +6,7 @@
<description> <description>
Comma-separated values are a plain text table storage format. The format's simplicity makes it easy to edit in any text editor or spreadsheet software. This makes it a common choice for game localization. Comma-separated values are a plain text table storage format. The format's simplicity makes it easy to edit in any text editor or spreadsheet software. This makes it a common choice for game localization.
[b]Example CSV file:[/b] [b]Example CSV file:[/b]
[codeblock] [codeblock lang=text]
keys,en,es,ja keys,en,es,ja
GREET,"Hello, friend!","Hola, amigo!",こんにちは GREET,"Hello, friend!","Hola, amigo!",こんにちは
ASK,How are you?,Cómo está?,元気ですか ASK,How are you?,Cómo está?,元気ですか

View File

@ -6,7 +6,7 @@
<description> <description>
A [SkeletonProfile] as a preset that is optimized for the human form. This exists for standardization, so all parameters are read-only. A [SkeletonProfile] as a preset that is optimized for the human form. This exists for standardization, so all parameters are read-only.
A humanoid skeleton profile contains 54 bones divided in 4 groups: [code]"Body"[/code], [code]"Face"[/code], [code]"LeftHand"[/code], and [code]"RightHand"[/code]. It is structured as follows: A humanoid skeleton profile contains 54 bones divided in 4 groups: [code]"Body"[/code], [code]"Face"[/code], [code]"LeftHand"[/code], and [code]"RightHand"[/code]. It is structured as follows:
[codeblock] [codeblock lang=text]
Root Root
└─ Hips └─ Hips
├─ LeftUpperLeg ├─ LeftUpperLeg

View File

@ -7,13 +7,13 @@
By configuring various properties of this style box, you can achieve many common looks without the need of a texture. This includes optionally rounded borders, antialiasing, shadows, and skew. By configuring various properties of this style box, you can achieve many common looks without the need of a texture. This includes optionally rounded borders, antialiasing, shadows, and skew.
Setting corner radius to high values is allowed. As soon as corners overlap, the stylebox will switch to a relative system. Setting corner radius to high values is allowed. As soon as corners overlap, the stylebox will switch to a relative system.
[b]Example:[/b] [b]Example:[/b]
[codeblock] [codeblock lang=text]
height = 30 height = 30
corner_radius_top_left = 50 corner_radius_top_left = 50
corner_radius_bottom_left = 100 corner_radius_bottom_left = 100
[/codeblock] [/codeblock]
The relative system now would take the 1:2 ratio of the two left corners to calculate the actual corner width. Both corners added will [b]never[/b] be more than the height. Result: The relative system now would take the 1:2 ratio of the two left corners to calculate the actual corner width. Both corners added will [b]never[/b] be more than the height. Result:
[codeblock] [codeblock lang=text]
corner_radius_top_left: 10 corner_radius_top_left: 10
corner_radius_bottom_left: 20 corner_radius_bottom_left: 20
[/codeblock] [/codeblock]

View File

@ -394,7 +394,7 @@
<member name="vrs_texture" type="Texture2D" setter="set_vrs_texture" getter="get_vrs_texture"> <member name="vrs_texture" type="Texture2D" setter="set_vrs_texture" getter="get_vrs_texture">
Texture to use when [member vrs_mode] is set to [constant Viewport.VRS_TEXTURE]. Texture to use when [member vrs_mode] is set to [constant Viewport.VRS_TEXTURE].
The texture [i]must[/i] use a lossless compression format so that colors can be matched precisely. The following VRS densities are mapped to various colors, with brighter colors representing a lower level of shading precision: The texture [i]must[/i] use a lossless compression format so that colors can be matched precisely. The following VRS densities are mapped to various colors, with brighter colors representing a lower level of shading precision:
[codeblock] [codeblock lang=text]
- 1×1 = rgb(0, 0, 0) - #000000 - 1×1 = rgb(0, 0, 0) - #000000
- 1×2 = rgb(0, 85, 0) - #005500 - 1×2 = rgb(0, 85, 0) - #005500
- 2×1 = rgb(85, 0, 0) - #550000 - 2×1 = rgb(85, 0, 0) - #550000

View File

@ -12,7 +12,7 @@
<members> <members>
<member name="application/additional_plist_content" type="String" setter="" getter=""> <member name="application/additional_plist_content" type="String" setter="" getter="">
Additional data added to the root [code]&lt;dict&gt;[/code] section of the [url=https://developer.apple.com/documentation/bundleresources/information_property_list]Info.plist[/url] file. The value should be an XML section with pairs of key-value elements, e.g.: Additional data added to the root [code]&lt;dict&gt;[/code] section of the [url=https://developer.apple.com/documentation/bundleresources/information_property_list]Info.plist[/url] file. The value should be an XML section with pairs of key-value elements, e.g.:
[codeblock] [codeblock lang=text]
&lt;key&gt;key_name&lt;/key&gt; &lt;key&gt;key_name&lt;/key&gt;
&lt;string&gt;value&lt;/string&gt; &lt;string&gt;value&lt;/string&gt;
[/codeblock] [/codeblock]

View File

@ -12,7 +12,7 @@
<members> <members>
<member name="application/additional_plist_content" type="String" setter="" getter=""> <member name="application/additional_plist_content" type="String" setter="" getter="">
Additional data added to the root [code]&lt;dict&gt;[/code] section of the [url=https://developer.apple.com/documentation/bundleresources/information_property_list]Info.plist[/url] file. The value should be an XML section with pairs of key-value elements, e.g.: Additional data added to the root [code]&lt;dict&gt;[/code] section of the [url=https://developer.apple.com/documentation/bundleresources/information_property_list]Info.plist[/url] file. The value should be an XML section with pairs of key-value elements, e.g.:
[codeblock] [codeblock lang=text]
&lt;key&gt;key_name&lt;/key&gt; &lt;key&gt;key_name&lt;/key&gt;
&lt;string&gt;value&lt;/string&gt; &lt;string&gt;value&lt;/string&gt;
[/codeblock] [/codeblock]