Search in sources :

Example 1 with IMixinSPacketPlayerListItem

use of org.spongepowered.common.interfaces.network.play.server.IMixinSPacketPlayerListItem in project SpongeCommon by SpongePowered.

the class SpongeTabList method sendUpdate.

/**
 * Send an entry update.
 *
 * @param entry The entry to update
 * @param action The update action to perform
 */
protected void sendUpdate(TabListEntry entry, SPacketPlayerListItem.Action action) {
    SPacketPlayerListItem packet = new SPacketPlayerListItem();
    packet.action = action;
    ((IMixinSPacketPlayerListItem) packet).addEntry(entry);
    this.player.connection.sendPacket(packet);
}
Also used : SPacketPlayerListItem(net.minecraft.network.play.server.SPacketPlayerListItem) IMixinSPacketPlayerListItem(org.spongepowered.common.interfaces.network.play.server.IMixinSPacketPlayerListItem) IMixinSPacketPlayerListItem(org.spongepowered.common.interfaces.network.play.server.IMixinSPacketPlayerListItem)

Aggregations

SPacketPlayerListItem (net.minecraft.network.play.server.SPacketPlayerListItem)1 IMixinSPacketPlayerListItem (org.spongepowered.common.interfaces.network.play.server.IMixinSPacketPlayerListItem)1