Quest Items as Scriptable Objects
Posted: Sat Jan 21, 2023 9:35 am
Hello,
I've finished making my first quest with the dialogue system and so far it works incredibly well.
I'd like each quest to give a specific item to the player.
Right now my inventory system works with scriptable objects, and the item is given to the player through a method on a monobehavior that takes that scriptable object (and triggers UI components and all that jazz).
Question 1. is there a way to reference a scriptable object as a variable? so when the quest is complete I could somehow pass it through the method. (when I was looking at the variable system I thought, maybe I could make a reference table with integers, that refers to an item to give the player)
Question 2. How would I go about invoking a method that passes through that scriptable object?
alternatively, is there just a better way of doing this that is already designed into the dialogue system
Thanks so much for your time!
I've finished making my first quest with the dialogue system and so far it works incredibly well.
I'd like each quest to give a specific item to the player.
Right now my inventory system works with scriptable objects, and the item is given to the player through a method on a monobehavior that takes that scriptable object (and triggers UI components and all that jazz).
Question 1. is there a way to reference a scriptable object as a variable? so when the quest is complete I could somehow pass it through the method. (when I was looking at the variable system I thought, maybe I could make a reference table with integers, that refers to an item to give the player)
Question 2. How would I go about invoking a method that passes through that scriptable object?
alternatively, is there just a better way of doing this that is already designed into the dialogue system
Thanks so much for your time!
