feat: updated engine version to 4.4-rc1
This commit is contained in:
parent
ee00efde1f
commit
21ba8e33af
5459 changed files with 1128836 additions and 198305 deletions
|
|
@ -57,7 +57,7 @@
|
|||
<description>
|
||||
Constructs a [NodePath] from a [String]. The created path is absolute if prefixed with a slash (see [method is_absolute]).
|
||||
The "subnames" optionally included after the path to the target node can point to properties, and can also be nested.
|
||||
Examples of strings that could be node paths:
|
||||
The following strings can be valid node paths:
|
||||
[codeblock]
|
||||
# Points to the Sprite2D node.
|
||||
"Level/RigidBody2D/Sprite2D"
|
||||
|
|
@ -100,7 +100,7 @@
|
|||
|
||||
// propertyPath points to the "position" in the "x" axis of this node.
|
||||
NodePath propertyPath = nodePath.GetAsPropertyPath();
|
||||
GD.Print(propertyPath); // Prints ":position:x".
|
||||
GD.Print(propertyPath); // Prints ":position:x"
|
||||
[/csharp]
|
||||
[/codeblocks]
|
||||
</description>
|
||||
|
|
@ -118,11 +118,11 @@
|
|||
[codeblocks]
|
||||
[gdscript]
|
||||
var node_path = ^"Sprite2D:texture:resource_name"
|
||||
print(node_path.get_concatenated_subnames()) # Prints "texture:resource_name".
|
||||
print(node_path.get_concatenated_subnames()) # Prints "texture:resource_name"
|
||||
[/gdscript]
|
||||
[csharp]
|
||||
var nodePath = new NodePath("Sprite2D:texture:resource_name");
|
||||
GD.Print(nodePath.GetConcatenatedSubnames()); // Prints "texture:resource_name".
|
||||
GD.Print(nodePath.GetConcatenatedSubnames()); // Prints "texture:resource_name"
|
||||
[/csharp]
|
||||
[/codeblocks]
|
||||
</description>
|
||||
|
|
@ -135,15 +135,15 @@
|
|||
[codeblocks]
|
||||
[gdscript]
|
||||
var sprite_path = NodePath("../RigidBody2D/Sprite2D")
|
||||
print(sprite_path.get_name(0)) # Prints "..".
|
||||
print(sprite_path.get_name(1)) # Prints "RigidBody2D".
|
||||
print(sprite_path.get_name(2)) # Prints "Sprite".
|
||||
print(sprite_path.get_name(0)) # Prints ".."
|
||||
print(sprite_path.get_name(1)) # Prints "RigidBody2D"
|
||||
print(sprite_path.get_name(2)) # Prints "Sprite"
|
||||
[/gdscript]
|
||||
[csharp]
|
||||
var spritePath = new NodePath("../RigidBody2D/Sprite2D");
|
||||
GD.Print(spritePath.GetName(0)); // Prints "..".
|
||||
GD.Print(spritePath.GetName(1)); // Prints "PathFollow2D".
|
||||
GD.Print(spritePath.GetName(2)); // Prints "Sprite".
|
||||
GD.Print(spritePath.GetName(0)); // Prints ".."
|
||||
GD.Print(spritePath.GetName(1)); // Prints "PathFollow2D"
|
||||
GD.Print(spritePath.GetName(2)); // Prints "Sprite"
|
||||
[/csharp]
|
||||
[/codeblocks]
|
||||
</description>
|
||||
|
|
@ -163,13 +163,13 @@
|
|||
[codeblocks]
|
||||
[gdscript]
|
||||
var path_to_name = NodePath("Sprite2D:texture:resource_name")
|
||||
print(path_to_name.get_subname(0)) # Prints "texture".
|
||||
print(path_to_name.get_subname(1)) # Prints "resource_name".
|
||||
print(path_to_name.get_subname(0)) # Prints "texture"
|
||||
print(path_to_name.get_subname(1)) # Prints "resource_name"
|
||||
[/gdscript]
|
||||
[csharp]
|
||||
var pathToName = new NodePath("Sprite2D:texture:resource_name");
|
||||
GD.Print(pathToName.GetSubname(0)); // Prints "texture".
|
||||
GD.Print(pathToName.GetSubname(1)); // Prints "resource_name".
|
||||
GD.Print(pathToName.GetSubname(0)); // Prints "texture"
|
||||
GD.Print(pathToName.GetSubname(1)); // Prints "resource_name"
|
||||
[/csharp]
|
||||
[/codeblocks]
|
||||
</description>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue