Inspector: Dropdown Menu for Dialogue Entry
Posted: Fri Feb 17, 2023 4:44 am
Hi,
Summary of the concept I try to achieve:
In my game, there are multiple short stories that all follow the same structure. Part of the structure is that an NPC comments on the player's action at certain points. The structure looks like this:
Story -> NPC comment -> Player decides between 2-4 Options -> choice results in one of 3-8 outcomes -> NPC comments the outcome -> end.
Since there can be up to 9 comments per short story (depending on the number of options that varies from story to story), I want to have them in one conversation in the dialouge database and call them by dialogue entry (instead of having an own conversation for each comment. The comments are quite short: 1-3 entries.)
What I want to do:
I have a script that tracks which comment should be played next -> for example it checks the outcome of the player's decision and should play the respective comment (dialogue entry).
It receives the information from a ScriptableObject. I want to be able to assign the conversation and dialogue entry in the ScriptableObject's inspector.
My main question:
Is there a possibility to select dialoge entry via dropdown in the inspector? (Like the Attribute for picking a conversation [ConversationPopup] )
(I have considered using quests but they don't quite suit the concept. I have also considered dialogue database variables but this would require setting up conditions for the entries in the dialogue system itself when setting up a new short story. --> I want to avoid this if possible. I use ScriptableObjects to set up the short stories and I want to keep the process of setting them up "clean" and in one place: You create the comments in the dialogue system, then you go to the ScriptableObject, assign all the stuff and then you are done.)
Any help is appreaciated
Thanks in advance!
Best
Lorena
Summary of the concept I try to achieve:
In my game, there are multiple short stories that all follow the same structure. Part of the structure is that an NPC comments on the player's action at certain points. The structure looks like this:
Story -> NPC comment -> Player decides between 2-4 Options -> choice results in one of 3-8 outcomes -> NPC comments the outcome -> end.
Since there can be up to 9 comments per short story (depending on the number of options that varies from story to story), I want to have them in one conversation in the dialouge database and call them by dialogue entry (instead of having an own conversation for each comment. The comments are quite short: 1-3 entries.)
What I want to do:
I have a script that tracks which comment should be played next -> for example it checks the outcome of the player's decision and should play the respective comment (dialogue entry).
It receives the information from a ScriptableObject. I want to be able to assign the conversation and dialogue entry in the ScriptableObject's inspector.
My main question:
Is there a possibility to select dialoge entry via dropdown in the inspector? (Like the Attribute for picking a conversation [ConversationPopup] )
(I have considered using quests but they don't quite suit the concept. I have also considered dialogue database variables but this would require setting up conditions for the entries in the dialogue system itself when setting up a new short story. --> I want to avoid this if possible. I use ScriptableObjects to set up the short stories and I want to keep the process of setting them up "clean" and in one place: You create the comments in the dialogue system, then you go to the ScriptableObject, assign all the stuff and then you are done.)
Any help is appreaciated
Thanks in advance!
Best
Lorena