mirror of
https://github.com/stan220/godot-docs.git
synced 2026-09-08 18:29:11 +00:00
4.0: Convert Sprite references to Sprite2D
Some screenshots will need to be updated so that the scene structures shown in screenshot fit what the code blocks are referring to.
This commit is contained in:
@@ -146,7 +146,7 @@ following code:
|
||||
# Convert Image to ImageTexture.
|
||||
var tex = ImageTexture.new()
|
||||
tex.create_from_image(img)
|
||||
# Set Sprite Texture.
|
||||
# Set sprite texture.
|
||||
$sprite.texture = tex
|
||||
|
||||
But if you use this in ``_ready()`` or from the first frame of the :ref:`Viewport's <class_Viewport>` initialization,
|
||||
|
||||
Reference in New Issue
Block a user