about summary refs log blame commit diff stats
path: root/Archipelago/settings_buttons.gd
blob: 9193b6168c127c4126c33f949776092c63602da5 (plain) (tree)
1
2
3
4
5
6
7
8
9
10






                        
                            


                                                                          
                                                                                      
                                                                                           
                                                                                  
                               
 
                                  
                     

                                                     
                                      
extends Button


func _ready():
	pass


func _connect_pressed():
	self.disabled = true

	var apclient = global.get_node("Archipelago")
	apclient.ap_server = self.get_parent().get_node("server_box").text
	apclient.ap_user = self.get_parent().get_node("player_box").text
	apclient.ap_pass = self.get_parent().get_node("password_box").text
	apclient.confusify_world = self.get_parent().get_node("confusing_box").pressed
	apclient.enable_multiplayer = self.get_parent().get_node("multiplayer_box").pressed
	apclient.track_player = self.get_parent().get_node("position_box").pressed
	apclient.saveSettings()

	apclient.connectToServer()


func _back_pressed():
	var apclient = global.get_node("Archipelago")
	apclient.disconnect_from_ap()

	fader._fade_start("main_menu")