Options controller - part 3 of 4
func select_language(element_id: String, code: String) -> void:
var list: PCAListBox = control(element_id) as PCAListBox
if not is_instance_valid(list):
return
list.selected_ids.clear()
list.selected_ids.append(code)
list.refresh()func selected_language(element_id: String, fallback: String) -> String:
var list: PCAListBox = control(element_id) as PCAListBox
if not is_instance_valid(list) or list.selected_ids.is_empty():
return fallback
return list.selected_ids[0]Language selections are List Box item IDs. The voice item auto is a GUI convenience; it is converted to an empty voice-language override when applying.
Continue with the next part in the same options_tools record. Do not add another extends line.
