|
|
|
@ -77,6 +77,8 @@ export function FreeFlow(){ |
|
|
|
const refCurrentCue= useRef(null); |
|
|
|
const refCurrentCue= useRef(null); |
|
|
|
const refData=useRef(data); |
|
|
|
const refData=useRef(data); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const refHintTimeout=useRef(); |
|
|
|
|
|
|
|
|
|
|
|
const { history, status, reset, sendMessage, setStatus, audioOutput, setAudioOutput, stop:stopChat, |
|
|
|
const { history, status, reset, sendMessage, setStatus, audioOutput, setAudioOutput, stop:stopChat, |
|
|
|
audioUrl }=useChat(); |
|
|
|
audioUrl }=useChat(); |
|
|
|
|
|
|
|
|
|
|
|
@ -121,7 +123,6 @@ export function FreeFlow(){ |
|
|
|
resetData(); |
|
|
|
resetData(); |
|
|
|
} |
|
|
|
} |
|
|
|
break; |
|
|
|
break; |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// Handle OSC messages here |
|
|
|
// Handle OSC messages here |
|
|
|
@ -327,7 +328,8 @@ export function FreeFlow(){ |
|
|
|
// if(cue.callback=='fade_out_light') refLight.current.fadeOut(); // Fade out light for conversation end |
|
|
|
// if(cue.callback=='fade_out_light') refLight.current.fadeOut(); // Fade out light for conversation end |
|
|
|
|
|
|
|
|
|
|
|
if(cue.hint!=null){ |
|
|
|
if(cue.hint!=null){ |
|
|
|
setTimeout(()=>{ |
|
|
|
if(refHintTimeout.current) clearTimeout(refHintTimeout.current); |
|
|
|
|
|
|
|
refHintTimeout.current=setTimeout(()=>{ |
|
|
|
sendOsc(OSC_ADDRESS.HINT, cue.hint); // Send OSC hint message |
|
|
|
sendOsc(OSC_ADDRESS.HINT, cue.hint); // Send OSC hint message |
|
|
|
}, cue.hint_time); |
|
|
|
}, cue.hint_time); |
|
|
|
} |
|
|
|
} |
|
|
|
|