mirror of
https://github.com/godotengine/godot-docs.git
synced 2026-01-04 14:11:02 +03:00
Move GDScript text onto tip in 2D Getting started 03 chapter (#5732)
This commit is contained in:
@@ -267,11 +267,11 @@ diagonal movement.
|
||||
We also check whether the player is moving so we can call ``play()`` or
|
||||
``stop()`` on the AnimatedSprite.
|
||||
|
||||
``$`` is shorthand for ``get_node()``. So in the code above,
|
||||
.. tip:: ``$`` is shorthand for ``get_node()``. So in the code above,
|
||||
``$AnimatedSprite.play()`` is the same as
|
||||
``get_node("AnimatedSprite").play()``.
|
||||
|
||||
.. tip:: In GDScript, ``$`` returns the node at the relative path from the
|
||||
In GDScript, ``$`` returns the node at the relative path from the
|
||||
current node, or returns ``null`` if the node is not found. Since
|
||||
AnimatedSprite is a child of the current node, we can use
|
||||
``$AnimatedSprite``.
|
||||
|
||||
Reference in New Issue
Block a user