Action queue/list for NPCs in point and click adventure.
Hi all.
I'm making a point and click adventure in the spirit of the old lucasart games. I need to have a list/queue (FIFO) which contains a sequence of NPC actions like walkTo, ,giveItem, sayLine and so on. I need to be able to add an action to the list, along with it's parameters, (the dialogue string, duration to display text, text color and so on), but I can't think of a simple way to do this.
Ideally I'd like to say something like:
actionList.Add(Say, BarKeep, "You drinkin' or just lookin'?", 2.0f, green);
actionList.Add(walkTo, BarKeep, beerPumpLocation);
Can anyone advise on different ways to approach the issue? I'll code it myself, I'm just looking for advice on the most elegant solution.
I've already looked through this ace video https://www.youtube.com/watch?v=o6CaB-hmqoE&feature=youtu.be but I'm stuck on how to achieve the above format for adding actions.
Thanks
Dan