MCPcopy Create free account
hub / github.com/RustOtomeLab/RustEng / play_bgm

Method play_bgm

src/executors/executor.rs:598–611  ·  view source on GitHub ↗
(&self, bgm: String)

Source from the content-addressed store, hash-verified

596
597 let mut script = self.script.borrow_mut();
598 script.set_explain(&format!("选择支:{explain}"));
599 let mut choose_branch = Vec::with_capacity(choices.len());
600 for (index, choice) in choices.iter().enumerate() {
601 choose_branch.push((index as i32, SharedString::from(choice.0.clone())));
602 }
603 script.push_backlog(
604 "选择支".to_shared_string(),
605 explain.to_shared_string(),
606 None,
607 );
608 window.set_choose_branch(Rc::new(VecModel::from(choose_branch)).into());
609 window.set_current_choose(choices.len() as i32);
610 }
611 Command::Dialogue { speaker, text } => {
612 {
613 let mut script = self.script.borrow_mut();
614 let voice = script.pre_voice();

Callers 1

apply_commandMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected