PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua Class Reference

Adds Lua functions to the Dialogue System that control Opsive UCC characters. More...

Inheritance diagram for PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua:
Collaboration diagram for PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua:

Static Public Member Functions

static UltimateCharacterLocomotion FindCharacter (string characterName)
 Finds an UltimateCharacterLocomotion by GameObject name.
 
static bool FindCharacterWithInventory (string characterName, out UltimateCharacterLocomotion character, out InventoryBase inventory, out ItemCollection itemCollection)
 Finds an UltimateCharacterLocomotion and its Inventory and ItemCollection by GameObject name.
 
static double uccGetAttribute (string characterName, string attributeName)
 Returns the value of an attribute on a character.
 
static void uccSetAttribute (string characterName, string attributeName, double value)
 Sets the value of an attribute on a character.
 
static double uccGetItemCount (string characterName, string itemName)
 Returns the amount of an item that a character has in its inventory.
 
static void uccAddItem (string characterName, string itemName, double amount)
 Adds an amount of an item to a character's inventory.
 
static void uccRemoveItem (string characterName, string itemName, double amount)
 Removes an item from a character's inventory.
 
static void uccEquipItem (string characterName, string itemName)
 Equips an item.
 
static void uccUnequipItem (string characterName, string itemName)
 Unequips an item.
 
static void uccNotifyOnEquip (bool value)
 Set true to notify others when item is equipped – for example to play equip sound.
 

Static Public Attributes

static bool notifyOthersOnPickup = false
 

Static Protected Member Functions

static ItemType FindItemType (InventoryBase inventory, ItemCollection itemCollection, string itemName)
 Finds an ItemType by name in an ItemCollection.
 
static int GetItemSlot (InventoryBase inventory, ItemType itemType)
 

Static Protected Attributes

static bool registered = false
 

Detailed Description

Adds Lua functions to the Dialogue System that control Opsive UCC characters.

Member Function Documentation

◆ FindCharacter()

static UltimateCharacterLocomotion PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.FindCharacter ( string  characterName)
inlinestatic

Finds an UltimateCharacterLocomotion by GameObject name.

If the GameObject name is blank, finds the GameObject tagged 'Player'.

◆ FindCharacterWithInventory()

static bool PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.FindCharacterWithInventory ( string  characterName,
out UltimateCharacterLocomotion  character,
out InventoryBase  inventory,
out ItemCollection  itemCollection 
)
inlinestatic

Finds an UltimateCharacterLocomotion and its Inventory and ItemCollection by GameObject name.

If the name is blank, finds the GameObject tagged 'Player'.

◆ FindItemType()

static ItemType PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.FindItemType ( InventoryBase  inventory,
ItemCollection  itemCollection,
string  itemName 
)
inlinestaticprotected

Finds an ItemType by name in an ItemCollection.

◆ GetItemSlot()

static int PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.GetItemSlot ( InventoryBase  inventory,
ItemType  itemType 
)
inlinestaticprotected

◆ uccAddItem()

static void PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccAddItem ( string  characterName,
string  itemName,
double  amount 
)
inlinestatic

Adds an amount of an item to a character's inventory.

Parameters
characterNameGameObject name of character, or blank for player.
itemNameItem type name.
amountAmount to add.

◆ uccEquipItem()

static void PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccEquipItem ( string  characterName,
string  itemName 
)
inlinestatic

Equips an item.

Assumes the item is already in the character's inventory.

Parameters
characterNameGameObject name of character, or blank for player.
itemNameItem type name to equip.

◆ uccGetAttribute()

static double PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccGetAttribute ( string  characterName,
string  attributeName 
)
inlinestatic

Returns the value of an attribute on a character.

Parameters
characterNameGameObject name of character, or blank for player.
attributeNameAttribute name.

◆ uccGetItemCount()

static double PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccGetItemCount ( string  characterName,
string  itemName 
)
inlinestatic

Returns the amount of an item that a character has in its inventory.

Parameters
characterNameGameObject name of character, or blank for player.
itemNameItem type name.

◆ uccNotifyOnEquip()

static void PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccNotifyOnEquip ( bool  value)
inlinestatic

Set true to notify others when item is equipped – for example to play equip sound.

◆ uccRemoveItem()

static void PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccRemoveItem ( string  characterName,
string  itemName,
double  amount 
)
inlinestatic

Removes an item from a character's inventory.

Parameters
characterNameGameObject name of character, or blank for player.
itemNameItem type name.
amountAmount to remove.

◆ uccSetAttribute()

static void PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccSetAttribute ( string  characterName,
string  attributeName,
double  value 
)
inlinestatic

Sets the value of an attribute on a character.

Parameters
characterNameGameObject name of character, or blank for player.
attributeNameAttribute name.
valueNew value of attribute.

◆ uccUnequipItem()

static void PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.uccUnequipItem ( string  characterName,
string  itemName 
)
inlinestatic

Unequips an item.

Assumes the item is already in the character's inventory.

Parameters
characterNameGameObject name of character, or blank for player.
itemNameItem type name to unequip.

Member Data Documentation

◆ notifyOthersOnPickup

bool PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.notifyOthersOnPickup = false
static

◆ registered

bool PixelCrushers.DialogueSystem.OpsiveUCCSupport.UCCLua.registered = false
staticprotected

The documentation for this class was generated from the following file: