guards in place for when scoreboard_host.txt is not present
This commit is contained in:
parent
6a68e025ea
commit
94ed6c6c68
3 changed files with 11 additions and 5 deletions
|
@ -35,9 +35,10 @@ class ScoreEntry:
|
|||
|
||||
func _ready() -> void:
|
||||
var file = File.new()
|
||||
file.open("res://scoreboard_host.txt", File.READ)
|
||||
server_host = file.get_line()
|
||||
file.close()
|
||||
var result = file.open("res://scoreboard_host.txt", File.READ)
|
||||
if result == OK:
|
||||
server_host = file.get_line()
|
||||
file.close()
|
||||
|
||||
http = HTTPRequest.new()
|
||||
http.download_chunk_size = 4096
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue