summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2019-01-26 20:21:38 +0100
committerRémi Verschelde <rverschelde@gmail.com>2019-01-26 20:25:36 +0100
commit33d8c19999f28343a2fc2f7aef4d40f80c276145 (patch)
tree524d09c362c32717655674ff6afa05b0e775bb57
parentc2f59de212546e2005e4cbdde9515599cdaa3b78 (diff)
doc: Add caveat for File.file_exists for imported resources
Fixes #25347.
-rw-r--r--doc/classes/File.xml1
1 files changed, 1 insertions, 0 deletions
diff --git a/doc/classes/File.xml b/doc/classes/File.xml
index 1967349546..6462176c73 100644
--- a/doc/classes/File.xml
+++ b/doc/classes/File.xml
@@ -48,6 +48,7 @@
</argument>
<description>
Returns [code]true[/code] if the file exists in the given path.
+ Note that many resources types are imported (e.g. textures or sound files), and that their source asset will not be included in the exported game, as only the imported version is used (in the [code]res://.import[/code] folder). To check for the existence of such resources while taking into account the remapping to their imported location, use [method ResourceLoader.exists]. Typically, using [code]File.file_exists[/code] on an imported resource would work while you are developing in the editor (the source asset is present in [code]res://[/code], but fail when exported).
</description>
</method>
<method name="get_16" qualifiers="const">