gdsqlite-native
gdsqlite-native copied to clipboard
Using db.open(path) on a DB under res:// now uses open_buffered on non-editor builds
This pull request changes the behavior of SQLite.open(path)
. When path
points to a database file under res://
, it implicitly opens it using Godot's File
class, allowing the use of packed databases without the user needing additional boiler plate code to use open_buffered
.
This does not occur in scripts running in the editor, so tool
scripts will still be able to write to databases under res://
.
This has been tested on Windows 10 64-bit using the item_database
example.