Table of Contents

Struct InventorySplitItemBroadcast

Namespace
FishMMO.Shared
Assembly
FishMMO.Shared.dll

Client request to split part of a stack off into an inventory slot. Issue #198.

public struct InventorySplitItemBroadcast : IBroadcast
Implements
IBroadcast
Inherited Members

Remarks

Shaped like InventorySwapItemSlotsBroadcast on purpose: the destination is always an inventory slot, FromInventory names where the stack is, and the two indices travel in the same fields — so the failure message, the client's pending-slot bookkeeping and the server's banker check all treat it exactly as they treat a swap.

Never echoed. A swap is acknowledged by echoing the request, because the client can apply a swap from the two indices alone. A split creates an item the client has never seen, so the server answers with the ordinary set-slot messages for both slots instead, the same way it reports a granted item.

Fields

Amount

How much to take. At least 1 and less than the stack holds; anything else is refused.

public uint Amount

Field Value

uint

From

Slot holding the stack being split, in FromInventory.

public int From

Field Value

int

FromInventory

Container holding the stack being split.

public InventoryType FromInventory

Field Value

InventoryType

To

Inventory slot the split half goes to: empty, or a matching stack with room.

public int To

Field Value

int