Method HandleTransaction
HandleTransaction(Price, Payout, Inventory, Inventory, TransactionEvent, TransactionEvent)
Handles a single transaction with a single price and single payout.
Declaration
public static long HandleTransaction(Price price, Payout payout, Inventory sourceInventory = null, Inventory destinationInventory = null, TransactionManager.TransactionEvent onTransactionSuccess = null, TransactionManager.TransactionEvent onTransactionFail = null)
Parameters
| Type | Name | Description |
|---|---|---|
| Price | price | Contains information for the cost of this transaction. |
| Payout | payout | Contains information for the outcome of this transaction. |
| Inventory | sourceInventory | The inventory to read from and eventually deduct items from. |
| Inventory | destinationInventory | The inventory to place outputs to. |
| TransactionManager.TransactionEvent | onTransactionSuccess | Callback for a successful transaction. |
| TransactionManager.TransactionEvent | onTransactionFail | Callback for a failed transaction. |
Returns
| Type | Description |
|---|---|
| long |