Table of Contents

Interface IEquipmentAutomation

Namespace
AcDream.Plugin.Abstractions
Assembly
AcDream.Plugin.Abstractions.dll

Reads what the player owns that can be worn or wielded, and asks the server to equip a chosen item.

public interface IEquipmentAutomation

Properties

IsAvailable

True when this surface can be used: the session is in the world and the host wired up equipping.

bool IsAvailable { get; }

Property Value

bool

IsBusy

True while an equip the client started is still running.

bool IsBusy { get; }

Property Value

bool

Methods

CaptureOwnedEquipment()

Everything the character owns that can be worn or wielded, in a defined order: what is equipped first, then by name, then by object id. Clients rely on that order — "the first wand" means the one being held if any wand is — so a host must not hand back an arbitrary sequence. Lists every owned item that can occupy an equipment slot, equipped items first and then by name. Returns an empty list when the surface is unavailable.

IReadOnlyList<PluginEquipmentItem> CaptureOwnedEquipment()

Returns

IReadOnlyList<PluginEquipmentItem>

CaptureWorldPlacementsInOrder()

Current equipment placements in the world object's enumeration order. This preserves the order of the underlying object table and includes objects without a usable equipment profile.

IReadOnlyList<PluginEquipmentPlacement> CaptureWorldPlacementsInOrder()

Returns

IReadOnlyList<PluginEquipmentPlacement>

Equip(uint, uint)

Asks the server to wear or wield an owned item, the same way dragging it onto the character does. Pass zero for requestedLocation to let the client pick the slot, or a slot bit mask to ask for a specific one.

PluginEquipmentCommandResult Equip(uint objectId, uint requestedLocation = 0)

Parameters

objectId uint
requestedLocation uint

Returns

PluginEquipmentCommandResult

EquipSecondary(uint)

Requests the secondary hand. A melee item can be placed there even when its ordinary valid-location mask only lists a weapon slot. The client resolves the resulting slot and any blocking item.

PluginEquipmentCommandResult EquipSecondary(uint objectId)

Parameters

objectId uint

Returns

PluginEquipmentCommandResult

Events

PlacementObserved

Raised for a server-confirmed placement or removal, including an item that enters the world already equipped. Optimistic inventory moves and ordinary world movement do not raise this event.

event Action<PluginEquipmentObservation> PlacementObserved

Event Type

Action<PluginEquipmentObservation>