Make paths absolute to fix permissions issues
on Android
This commit is contained in:
@@ -49,7 +49,7 @@ func PollWebsocket():
|
|||||||
print("trying to open " + result_path)
|
print("trying to open " + result_path)
|
||||||
var resut_file = FileAccess.open(result_path,FileAccess.READ)
|
var resut_file = FileAccess.open(result_path,FileAccess.READ)
|
||||||
result_value = "{path}:{data}".format({
|
result_value = "{path}:{data}".format({
|
||||||
"path":result_path,
|
"path": result_path.get_file(),
|
||||||
"data": Marshalls.raw_to_base64(resut_file.get_buffer(resut_file.get_length()))
|
"data": Marshalls.raw_to_base64(resut_file.get_buffer(resut_file.get_length()))
|
||||||
})
|
})
|
||||||
var debugFile = FileAccess.open("user://debug.log", FileAccess.WRITE)
|
var debugFile = FileAccess.open("user://debug.log", FileAccess.WRITE)
|
||||||
|
|||||||
5
Main.gd
5
Main.gd
@@ -23,9 +23,8 @@ func _ready():
|
|||||||
|
|
||||||
print("Starting render node")
|
print("Starting render node")
|
||||||
|
|
||||||
var directory = DirAccess.open(".")
|
DirAccess.make_dir_absolute(output_dir)
|
||||||
directory.make_dir(output_dir)
|
DirAccess.make_dir_absolute(cache_dir)
|
||||||
directory.make_dir(cache_dir)
|
|
||||||
$JobServer.InitWebsocket()
|
$JobServer.InitWebsocket()
|
||||||
|
|
||||||
func FinishedRendering():
|
func FinishedRendering():
|
||||||
|
|||||||
@@ -2,6 +2,6 @@
|
|||||||
auth_key=ay1234
|
auth_key=ay1234
|
||||||
websocket_url="ws://localhost:6980"
|
websocket_url="ws://localhost:6980"
|
||||||
public_path="http://localhost:8899/"
|
public_path="http://localhost:8899/"
|
||||||
output_dir="./output"
|
output_dir="user://output"
|
||||||
cache_dir="./cache"
|
cache_dir="user://cache"
|
||||||
serve_mode="local"
|
serve_mode="local"
|
||||||
|
|||||||
Reference in New Issue
Block a user