mirror of
https://github.com/godotengine/godot-docs.git
synced 2026-01-04 14:11:02 +03:00
docs: fix for File -> FileAccess change
This commit is contained in:
@@ -294,10 +294,9 @@ method. Our sample code is a bit long, so let's split in a few parts:
|
||||
::
|
||||
|
||||
func _import(source_file, save_path, options, r_platform_variants, r_gen_files):
|
||||
var file = File.new()
|
||||
var err = file.open(source_file, File.READ)
|
||||
if err != OK:
|
||||
return err
|
||||
var file = FileAccess.open(source_file, FileAccess.READ)
|
||||
if file == null:
|
||||
return FileAccess.get_open_error()
|
||||
|
||||
var line = file.get_line()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user