Switching Scenes Using Sequence
Re: Switching Scenes Using Sequence
Please do. That would be much appreciated
Re: Switching Scenes Using Sequence
Here's an example: SInventoryConversationExample_2017-02-03.unitypackage
It has a _README.txt file that explains how it's set up.
It has a _README.txt file that explains how it's set up.
Re: Switching Scenes Using Sequence
Thanks Tony This is exactly what I've been looking for. As for the "LastItem", how do I make a condition? For example, there is a specific vendor that sells a specific Item. If the player bought that specific Item, it will trigger a specific conversation. Can I compare it to a lua variable from the variables tab in the Dialogue Manager? or do I have to make a script for those?
Re: Switching Scenes Using Sequence
Hi,
To make a condition on the last (most recent) item that the player bought:
1. Add a variable named "LastItem" (with that exact spelling) to your dialogue database. This step is optional, but it makes it easier to use the Lua wizard to make a condition.
2. Check that variable in a Condition field in your conversation.
Here's an updated example that does this: SInventoryConversationExample_2017-02-04.unitypackage
On the other hand, to check if the player has an item, regardless of when he bought it or picked it up, use the GetItemAmount() Lua function. For example, you could put this in the Conditions field:
This checks if the Player has at least one Shield item.
To make a condition on the last (most recent) item that the player bought:
1. Add a variable named "LastItem" (with that exact spelling) to your dialogue database. This step is optional, but it makes it easier to use the Lua wizard to make a condition.
2. Check that variable in a Condition field in your conversation.
Here's an updated example that does this: SInventoryConversationExample_2017-02-04.unitypackage
On the other hand, to check if the player has an item, regardless of when he bought it or picked it up, use the GetItemAmount() Lua function. For example, you could put this in the Conditions field:
Code: Select all
GetItemAmount("Player", "Shield") >= 1
Re: Switching Scenes Using Sequence
Thanks a lot Tony! I also used the same method to tell the player that they sold the right Item to the vendor Thank you very much
Re: Switching Scenes Using Sequence
Glad to help!