From 711269721681c3756c7f5b366d08aaaa43e63e27 Mon Sep 17 00:00:00 2001 From: joylink_zhangsai <1021828630@qq.com> Date: Sun, 9 Oct 2022 15:09:17 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=89=A7=E6=9C=AC=E8=BF=90?= =?UTF-8?q?=E8=A1=8Cbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../cbtc/competition/CompetitionAndScriptManager.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/club/joylink/rtss/simulation/cbtc/competition/CompetitionAndScriptManager.java b/src/main/java/club/joylink/rtss/simulation/cbtc/competition/CompetitionAndScriptManager.java index 6f73898e5..a88003496 100644 --- a/src/main/java/club/joylink/rtss/simulation/cbtc/competition/CompetitionAndScriptManager.java +++ b/src/main/java/club/joylink/rtss/simulation/cbtc/competition/CompetitionAndScriptManager.java @@ -228,7 +228,10 @@ public class CompetitionAndScriptManager { case Conversation: if (unfinishedAction.isAudioPlaying()) { // 获取当前会话 - Conversation conversation = simulation.getSimulationConversationMap().get(unfinishedAction.getConversationId()); + Conversation conversation = simulation.findValidConversationBySimulationMember(unfinishedAction.getMember()); + if (conversation == null) { + throw new SimulationException(SimulationExceptionType.System_Fault, "剧本会话动作执行所需会话未创建"); + } if (conversation.getMemberList().stream().allMatch(m -> m.getMember().isRobot())) { // 会话人员全部是机器人 unfinishedAction.finish(); }