SpotAnimList

The spotanim list is a specialized extended info block with compression logic built into it, as the theoretical possibilities of this block are rather large. This extended info block will track the modified slots using a bitset. Instead of traversing the entire list at the end of a cycle to reset the properties, it will follow the bitset's enabled bits to identify which slots to reset, if any. As in most cases the answer is none - this should outperform array fills by quite a bit.

Parameters

encoders

the array of client-specific encoders for spotanims.

Constructors

Link copied to clipboard

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

The changelist that tracks all the slots which have been flagged for a spotanim update.

Link copied to clipboard
Link copied to clipboard

The array of spotanims on this avatar. This array utilizes the bitpacked representation of a SpotAnim.

Functions

Link copied to clipboard
open override fun clear()

Traverses the bit set to determine which spotanims to clear out.

Link copied to clipboard
fun getBuffer(oldSchoolClientType: OldSchoolClientType): ByteBuf?

Gets the latest pre-computed buffer for the given oldSchoolClientType.

Link copied to clipboard
fun getEncoder(oldSchoolClientType: OldSchoolClientType): PrecomputedExtendedInfoEncoder<SpotAnimList>?

Gets the encoder for a given oldSchoolClientType.

Link copied to clipboard
fun isPrecomputed(oldSchoolClientType: OldSchoolClientType): Boolean

Checks whether a buffer has been precomputed on the specified client type.

Link copied to clipboard
fun set(slot: Int, spotAnim: SpotAnim)

Sets the spotanim in slot slot. This function will also flag the given slot for a change.

Link copied to clipboard
fun setBuffer(clientTypeId: Int, buffer: ByteBuf)

Sets the client-specific buffer at index clientTypeId.