Struct EquipmentReconcileEntry
Lightweight reconcile entry for a single equipped item slot. Only filled slots are serialized — empty slots are omitted.
public struct EquipmentReconcileEntry : IEquatable<EquipmentReconcileEntry>
- Implements
- Inherited Members
Fields
ItemID
The item's identity — its character_item row id, and the same value the attribute
ledger keys its contribution by.
public long ItemID
Field Value
Remarks
This used to be called InstanceID and carried a number that could not identify an
item: rows were keyed (character_id, slot) across three tables with three identity
sequences, so it changed when the item moved and collided across containers. The owner's
reconcile could therefore not match a runtime item to its entry, and materialised a clone
into the slot while the original stayed in the inventory. One table, one identity, and the
match works.
Zero for an item the database has not written yet. EquipmentController treats that
as "cannot be matched" rather than as a value.
MaxEntries
Maximum number of equipment entries per reconcile payload.
public const int MaxEntries = 64
Field Value
Seed
Item generation seed (0 if not generated).
public int Seed
Field Value
Slot
Equipment slot index (byte cast of ItemSlot).
public byte Slot
Field Value
TemplateID
Item template ID (0 = empty slot, omitted from reconcile).
public int TemplateID
Field Value
Methods
Equals(EquipmentReconcileEntry)
Returns true if this entry matches the other entry on all fields.
public bool Equals(EquipmentReconcileEntry other)
Parameters
otherEquipmentReconcileEntryThe other entry to compare.
Returns
- bool
True if all fields match.
Equals(object)
Returns true if obj is an EquipmentReconcileEntry with matching fields.
public override bool Equals(object obj)
Parameters
objobjectThe object to compare.
Returns
- bool
True if obj is an identical EquipmentReconcileEntry.
GetHashCode()
Returns a hash code combining all fields for use in dictionaries and sets.
public override int GetHashCode()
Returns
- int
Hash code for this entry.
ReadArrayDelta(Reader, EquipmentReconcileEntry[])
Reads a delta-encoded array of reconcile entries previously written by WriteArrayDelta(Writer, EquipmentReconcileEntry[], EquipmentReconcileEntry[], DeltaSerializerOption). Handles both full-array and index-delta formats based on the header flag.
public static EquipmentReconcileEntry[] ReadArrayDelta(Reader reader, EquipmentReconcileEntry[] prev)
Parameters
readerReaderReader to deserialize from.
prevEquipmentReconcileEntry[]Previous reconcile snapshot to base deltas on, or null.
Returns
- EquipmentReconcileEntry[]
Reconstructed reconcile array, or null if empty.
ReadFrom(Reader)
Reads a single entry from a FishNet Reader.
public static EquipmentReconcileEntry ReadFrom(Reader reader)
Parameters
readerReaderThe Reader to read from.
Returns
- EquipmentReconcileEntry
The deserialized EquipmentReconcileEntry.
WriteArrayDelta(Writer, EquipmentReconcileEntry[], EquipmentReconcileEntry[], DeltaSerializerOption)
Delta-encodes an array of reconcile entries by comparing against a previous snapshot. Writes a full array when lengths differ or force-write is requested; writes index-delta when lengths match. Returns true if any data was written.
public static bool WriteArrayDelta(Writer writer, EquipmentReconcileEntry[] prev, EquipmentReconcileEntry[] next, DeltaSerializerOption option)
Parameters
writerWriterWriter to serialize to.
prevEquipmentReconcileEntry[]Previous reconcile snapshot, or null.
nextEquipmentReconcileEntry[]Current reconcile snapshot, or null.
optionDeltaSerializerOptionDelta serializer option (Unset = auto, otherwise force).
Returns
- bool
True if data was written; false if unchanged.
WriteTo(Writer, EquipmentReconcileEntry)
Writes a single entry to a FishNet Writer.
public static void WriteTo(Writer writer, EquipmentReconcileEntry entry)
Parameters
writerWriterThe Writer to write to.
entryEquipmentReconcileEntryThe entry to serialize.