JcInventory Wikia
Advertisement

CHARACTER FUNCTIONS

Character functions are network supported functions that can be used to do basic functions in JcInventory.

These are things such as adding and removing items, equipping items and other things that game logic will need to be tied to.

To implement them, drag a pin from the character that is preforming the action and call one of the interfaces. the interfaces will need to be set up

HowToUse
AddItems

Adding Items

RPC AddItemAmountToStack Interface

Specify a target inventory (if left clear will use the characters inventory) and an index. If an item is in that index the amount will be added to it. Only use positive values! If there is a remainder it will attempt to add it to the inventory!

RPC AddItemToInventoryInterface

Will add an item from specified item data to the selected inventory (if left clear will use the characters inventory). This function will scan for a empty slot in the inventory and add the item if there is space. NOTE! If the inventory is full, the item will be spawned in world space in front of the character that called this interface!

RPC AddItemToActorByClass Interface

NOT A CORE FUNCTION. There to be extended. Not in use in demo material.

RPC AddItemsToSlotInterface

Adds quantity to a already existing item in a slot. Will not go over the slots max value. Remainder will attempt to be added to inventory. On failing, the items will be removed!

RPC EquiptSlotByIndex Interface

Equips an item on a equipment slot index.

RemoveItems

Remove or Modify items

RPC Remove Item from slot interface

Removes an item from a index slot and sets it to blank.

RPC Subtract Item From Interface

Removes an amount from a specified inventory index. If the item runs out of quantity units it will be removed.

UserFunctions

Additional User Functions

RPC BubbleSort By Name Interface

Shuffles the inventory to sort it by name.

RPC Bubblesort by Size Interface

Shuffles the inventory to sort items by there size, biggest first.

RPC Spawn Item At Player Interface

Spawns an item with proper server replication at the specified pawn.

RPC OpenContainerWindowOnClientInterface

Opens a container window of the specified container for the client. Just specify what JcItemContainer.

Advertisement