Guest User

Untitled

a guest
Jul 27th, 2014
405
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.55 KB | None | 0 0
  1. package lavaInfusionPackets;
  2.  
  3. import io.netty.buffer.ByteBuf;
  4. import cpw.mods.fml.common.network.simpleimpl.IMessage;
  5.  
  6. public class MagmaChargePacket implements IMessage
  7. {
  8.     public int magmaFoundationChargeAmount;
  9.    
  10.     public MagmaChargePacket(){}
  11.    
  12.     public MagmaChargePacket(int num)
  13.     {
  14.         this.magmaFoundationChargeAmount = num;
  15.     }
  16.    
  17.     @Override
  18.     public void fromBytes(ByteBuf buf)
  19.     {
  20.         this.magmaFoundationChargeAmount = buf.readInt();
  21.     }
  22.  
  23.     @Override
  24.     public void toBytes(ByteBuf buf)
  25.     {
  26.         buf.writeInt(magmaFoundationChargeAmount);
  27.     }
  28. }
Advertisement
Add Comment
Please, Sign In to add comment