Example usage for io.netty.buffer ByteBufOutputStream writeLong

List of usage examples for io.netty.buffer ByteBufOutputStream writeLong

Introduction

In this page you can find the example usage for io.netty.buffer ByteBufOutputStream writeLong.

Prototype

@Override
    public void writeLong(long v) throws IOException 

Source Link

Usage

From source file:de.sanandrew.mods.claysoldiers.network.packet.PacketSoldierRender.java

License:Creative Commons License

@Override
@SuppressWarnings("unchecked")
public void writeData(ByteBufOutputStream stream, Tuple dataTuple) throws IOException {
    Triplet<Integer, long[], long[]> data = (Triplet) dataTuple;
    stream.writeInt(data.getValue0()); // entity id
    stream.writeLong(data.getValue1()[0]); // upgrade flags 1
    stream.writeLong(data.getValue1()[1]); // upgrade flags 2
    stream.writeLong(data.getValue2()[0]); // effect flags 1
    stream.writeLong(data.getValue2()[1]); // effect flags 2
}