I was thinking instead of just need the quest item to proceed the dialogue, I want to create a “present item” button then opens up the inventory. After choosing the item, the dialogue will proceed according to the need whether it is the item or not.
Does that need to exit the dialogue then opens up the inventory? And once I managed to present the item, do I have to keep the current dialogue and node so that it continues to the next node with the condition item? Or is there another way to halt the dialogue to open up the inventory?
The actual opening of the Inventory shouldn’t halt the Dialogue window at all, as nothing will be telling the window to close or the PlayerConversant that the conversation is over.
This is, however, not the problem… the problem will be some way of “selecting” the Inventory Item to give to the speaker.
There are a couple of options here:
You could have the Dialogue open a specialized Inventory Window that presents each item as a button instead of the InventorySlotUI we’re using now. The OnClick() of the button will try to present the item and if it’s valid, remove it from Inventory and continue on.
Another method is to make the DialogueUI an InventoryItem container (I’m at work, so I don’t have all the interfaces, but you want the one where the DragItem can drop an item in, but not return one).
For this container, you want the MaxAcceptable to return 0 unless it is the item you are looking for, in which case the MaxAcceptable would be 1. When the item is successfully transferred, continue with the dialogue.
Sorry for the late reply and thanks for the suggestion. Currently, I am using the first option you have suggested as it is what I intend to do.
Just for clarification, would this mean the inventory window is considered as a single node in the dialogue editor? Then any OnClick of the button would send the item along with the dialogue’s Next function?
This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.