【如果会话中全部为机器人,则直接完成】

This commit is contained in:
weizhihong 2022-07-28 10:55:09 +08:00
parent 84b591ae9d
commit 8e5a49628d

View File

@ -237,7 +237,9 @@ public class CompetitionAndScriptManager {
if (scriptExecuteService.executeAction(simulation, unfinishedAction, correctSystemTime)) {
unfinishedAction.playAudio();
}
if (unfinishedAction.getMember().isRobot()) { // 在音频播放后如果是机器人则直接完成操作
// 获取当前会话
Conversation conversation = simulation.getSimulationConversationMap().get(unfinishedAction.getConversationId());
if (conversation.getMemberList().stream().allMatch(m -> m.getMember().isRobot())) { // 会话人员全部是机器人
unfinishedAction.finish();
}
break;