Player Info Protocol
The player info protocol is responsible for tracking everything player info related within the given world. This class holds every avatar, their state, and provides means to allocate new player info instances.
Parameters
the ByteBuf allocator responsible for allocating the primary buffer the is written out to the pipeline, as well as any intermediate buffers used by extended info blocks. The allocator should ideally be pooled, as we acquire a new instance with each cycle. This is because there isn't necessarily a guarantee that Netty threads have fully written the information out to the network by the time the next cycle comes along and starts writing into this buffer. A direct implementation is also preferred, as this avoids unnecessary copying from and to the heap.
the worker responsible for executing the blocks of code found in player info. The default worker will remain single-threaded if there are less than coreCount * 4 players in the world. Otherwise, it will use ForkJoinPool to execute these jobs. Both of these are configurable within the DefaultProtocolWorker constructor.
Constructors
Functions
Allocates a new player info instance at index idx
Deallocates the player info object, releasing it back into the pool to be used by another player.