diff options
Diffstat (limited to 'doc/classes/PackedScene.xml')
-rw-r--r-- | doc/classes/PackedScene.xml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/classes/PackedScene.xml b/doc/classes/PackedScene.xml index 97595a6984..7ca1d5d60d 100644 --- a/doc/classes/PackedScene.xml +++ b/doc/classes/PackedScene.xml @@ -41,7 +41,7 @@ # Only `node` and `body` are now packed. var result = scene.pack(node) if result == OK: - var error = ResourceSaver.save("res://path/name.tscn", scene) # Or "user://..." + var error = ResourceSaver.save(scene, "res://path/name.tscn") # Or "user://..." if error != OK: push_error("An error occurred while saving the scene to disk.") [/gdscript] @@ -63,7 +63,7 @@ Error result = scene.Pack(node); if (result == Error.Ok) { - Error error = ResourceSaver.Save("res://path/name.tscn", scene); // Or "user://..." + Error error = ResourceSaver.Save(scene, "res://path/name.tscn"); // Or "user://..." if (error != Error.Ok) { GD.PushError("An error occurred while saving the scene to disk."); |