Fix another instance of TTS rate set to 50 pseudo-percent rather than the normal rate.

This commit is contained in:
Nolan Darilek 2020-09-02 09:19:43 -05:00
parent 348ac32314
commit eef67a583c

View File

@ -23,7 +23,8 @@ func set_initial_screen_focus(screen):
func _enter_tree(): func _enter_tree():
var editor_accessibility_enabled = true var editor_accessibility_enabled = true
var rate = 50 add_autoload_singleton("TTS", "res://addons/godot-tts/TTS.gd")
var rate = TTS.normal_rate
var config = ConfigFile.new() var config = ConfigFile.new()
var err = config.load("res://.godot-accessibility-editor-settings.ini") var err = config.load("res://.godot-accessibility-editor-settings.ini")
if not err: if not err:
@ -31,7 +32,6 @@ func _enter_tree():
"global", "editor_accessibility_enabled", true "global", "editor_accessibility_enabled", true
) )
rate = config.get_value("speech", "rate", 50) rate = config.get_value("speech", "rate", 50)
add_autoload_singleton("TTS", "res://addons/godot-tts/TTS.gd")
if editor_accessibility_enabled: if editor_accessibility_enabled:
TTS.call_deferred("_set_rate", rate) TTS.call_deferred("_set_rate", rate)
screen_reader = ScreenReader.new() screen_reader = ScreenReader.new()