This script synchronizes the Dialogue System's Lua environment with the UFPS player whenever a conversation starts or ends. More...
Public Member Functions | |
| void | OnConversationStart (Transform actor) |
| void | OnConversationEnd (Transform actor) |
Public Attributes | |
| bool | disableWeaponDuringConversations = true |
Set true to disable the player's weapon during conversations. More... | |
This script synchronizes the Dialogue System's Lua environment with the UFPS player whenever a conversation starts or ends.
To use it, add it to the player object.
It currently synchronizes: health and inventory.
Every weapon (e.g., "Pistol") has an associated Lua variable (e.g., Variable["Pistol"]) that is equal to the count or ammo count (if it uses ammo) if the player has the weapon or 0 if the player doesn't. During conversations, your dialogue entries can check and/or set the values using Lua conditions and scripts.
| void PixelCrushers.DialogueSystem.UFPS.FPSyncLuaPlayerOnConversation.OnConversationEnd | ( | Transform | actor | ) |
| void PixelCrushers.DialogueSystem.UFPS.FPSyncLuaPlayerOnConversation.OnConversationStart | ( | Transform | actor | ) |
| bool PixelCrushers.DialogueSystem.UFPS.FPSyncLuaPlayerOnConversation.disableWeaponDuringConversations = true |
Set true to disable the player's weapon during conversations.