Ways to create global variable for dalogs

Hi all! I’m trying to create a dialogue system for a character. Now each character has a dialogue queue that decreases after each conversation with the character. The queue is implemented as an array inside an actor created specifically for this purpose. To add dialogue to the queue, you must first spawn the actor with this variable. But the point of interest that triggers the addition of the dialog is not fixed and may even be on a different level. I’m not sure this implementation is good enough. Are there better ways to form this array of dialogs?
Actors