Hello,
in my project, I have a DialogManager. This Manager can handle a Dialog parsed by a XML-Reader. This works fine. But now, I have more than one dialog.
My idea (or my question): Get the name, or id of this NPC, if the player collides with them.
Process: Player collides with NPC A - press ‘E’ and a dialog (specified to NPC A) appears. The Player moves forward and collides with NPC B - press ‘E’ and a other(!) dialog appears.
Am I correct in this way?
Structure:
Player has a script ‘DialogManger.cs’
NPCs have a script ‘ShowName.cs’ - there is a variable ‘NPCName’ - this variable should be used for open different dialogs.
Thanks for reading.
Greetings,
V4mpy