Thanks, WillieSea. But that won't work. I did think about that. Let me explain the script:
Let HighAINPC := ar_Construct Array ---> Initializes an array
Let HighAINPC := GetHighActors ---> Sets the array to the function, which returns an array, in which a reference is set as an element for every NPC in the current cell and adjacent surrounding cells.
ForEach ActorRef <- HighAINPC ---> Starts a loop that walks through every single element in the array set by "GetHighActors"
Let CurrentActor := ActorRef["value"] ---> special function that sets "CurrentActor" to the first ref returned by "GetHighActors"
Let TalkingActor := CurrentActor.GetCurrentAIPackage == 6 ---> Sets TalkingActor to the first actor that is talking
If TalkingActor
Set NPCIsTalking to 1
Endif
Loop
So, if I were to use the "else" condition, if the very first actor returned by "gethighactors" was talking, but the next actor wasn't, it would set "NPCIsTalking" to 0, even though the first actor may still be talking. What I'm doing is writing a buffer purging script. Because of the bug with that function (thanks Bethesda), if an actor is talking while that function is called, the voice sound get cut off. So all you get is lips moving, but no sound. With this section of script, I'm trying to determine if one or more actors are talking, and when the last actor has stopped talking. When that happens, NPCIsTalking should get set to zero, and the rest of my script will continue, allowing buffers to be purged circumventing the "sound" bug. I understand you are not familiar with OBSE functions and scripting additions, but do you think you could tap into your "real" programming language skills to help.
Thanks a bunch