Hi,
You'll want to set up the conversation similarly to this:
- barks.png (14.05 KiB) Viewed 63 times
Let's say you're using the
Relationship Lua Functions to keep track of how NPCs feel about the player.
For example, if the NPC hates the player, you use this Lua (e.g., in a Script field):
Code: Select all
SetRelationship(Actor["NPC1"], Actor["Player"], "like", -50)
Then you can set the first dialogue entry's Conditions to:
Code: Select all
GetRelationship(Actor["NPC1"], Actor["Player"], "like") <= -50
You'd set the second entry's Conditions to:
Code: Select all
GetRelationship(Actor["NPC1"], Actor["Player"], "like") >= 50
and the third entry's Conditions to:
Code: Select all
50 < GetRelationship(Actor["NPC1"], Actor["Player"], "like") and GetRelationship(Actor["NPC1"], Actor["Player"], "like") < 50
This will work, but it will only work for NPC1. To make it work for any NPC, you will need to change the Conditions. When the Dialogue System starts a bark or conversation, it sets Variable["ActorIndex"] to the NPC's name. (Technically it sets it to the
actor index.)
So instead of Actor["NPC1"] you can use Actor[Variable["ActorIndex"]]:
Code: Select all
GetRelationship(Actor[Variable["ActorIndex"]], Actor["Player"], "like") <= -50