godot-psd-training/trainings/training1.gd

20 lines
684 B
GDScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

extends Node
## 实训名称
@export var trainingName: String = "实训"
## 场景描述
@export var trainingDesc: String = "场景描述"
var a_sd = preload("res://Assets/training_speech/sd.mp3")
var a_xt_pslgbztmwx = preload("res://Assets/training_speech/xt_pslgbztmwx.mp3")
var a_zby_ztmjczc = preload("res://Assets/training_speech/zby_ztmjczc.mp3")
func _ready():
$TrainingDescDialog.title = trainingName
$TrainingDescDialog.updateSceneDesc(trainingDesc)
func _on_training_desc_dialog_start_training():
await $VoiceCommunication.play_reply(a_xt_pslgbztmwx)
await $VoiceCommunication.speech_record_check("值班员上行2号门关门故障使用LCB关闭站台门")