From dfb5e32803e4e2f28b6f13765f89b88959888525 Mon Sep 17 00:00:00 2001 From: Joshua Barretto Date: Sun, 2 Apr 2023 18:47:54 +0100 Subject: [PATCH] Don't interact forever --- server/src/sys/agent/behavior_tree.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/server/src/sys/agent/behavior_tree.rs b/server/src/sys/agent/behavior_tree.rs index 6e40207ca8..f261ecd937 100644 --- a/server/src/sys/agent/behavior_tree.rs +++ b/server/src/sys/agent/behavior_tree.rs @@ -490,11 +490,15 @@ fn handle_rtsim_actions(bdata: &mut BehaviorData) -> bool { &bdata.read_data, target, ) { - bdata.controller.push_utterance(UtteranceKind::Greeting); bdata.controller.push_action(ControlAction::Talk); + bdata.controller.push_utterance(UtteranceKind::Greeting); bdata .agent_data .chat_npc("npc-speech-villager", &mut bdata.event_emitter); + bdata + .agent + .timer + .start(bdata.read_data.time.0, TimerAction::Interact); } } }