diff options
Diffstat (limited to 'Archipelago/settings_screen.gd')
-rw-r--r-- | Archipelago/settings_screen.gd | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Archipelago/settings_screen.gd b/Archipelago/settings_screen.gd new file mode 100644 index 0000000..91f233d --- /dev/null +++ b/Archipelago/settings_screen.gd | |||
@@ -0,0 +1,21 @@ | |||
1 | extends Spatial | ||
2 | |||
3 | |||
4 | func _ready(): | ||
5 | # Undo the load screen removing our cursor | ||
6 | get_tree().get_root().set_disable_input(false) | ||
7 | Input.set_mouse_mode(Input.MOUSE_MODE_VISIBLE) | ||
8 | |||
9 | # Read AP settings from file, if there are any | ||
10 | var file = File.new() | ||
11 | if file.file_exists("user://settings/archipelago"): | ||
12 | file.open("user://settings/archipelago", File.READ) | ||
13 | var data = file.get_var(true) | ||
14 | file.close() | ||
15 | |||
16 | if data.size() > 0: | ||
17 | self.get_node("Panel/server_box").text = data[0] | ||
18 | if data.size() > 1: | ||
19 | self.get_node("Panel/player_box").text = data[1] | ||
20 | if data.size() > 2: | ||
21 | self.get_node("Panel/password_box").text = data[2] | ||