mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-25 14:34:52 +00:00
New Packet Things - WIP
This commit is contained in:
1 parent
17eac9a690
commit
be6c318619
9 files changed
+209
-68
No files matched your search
@@ -0,0 +1,40 @@
|
||||
package kamkeel.network.packets;
|
||||
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import kamkeel.network.AbstractPacket;
|
||||
import kamkeel.network.PacketChannel;
|
||||
import kamkeel.network.PacketHandler;
|
||||
import kamkeel.network.enums.EnumInfoPacket;
|
||||
import kamkeel.util.ByteBufUtils;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
public final class LoginPacket extends AbstractPacket {
|
||||
public static final String packetName = "CNPC+|LoginPacket";
|
||||
|
||||
public LoginPacket() {}
|
||||
|
||||
|
||||
@Override
|
||||
public Enum getType() {
|
||||
return EnumInfoPacket.LOGIN;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PacketChannel getChannel() {
|
||||
return PacketHandler.INFO_PACKET;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void sendData(ByteBuf out) throws IOException {
|
||||
// ByteBufUtils.writeUTF8String(out, this.data.player.getCommandSenderName());
|
||||
// ByteBufUtils.writeNBT(out,this.data.saveFromNBT(new NBTTagCompound()));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void receiveData(ByteBuf in, EntityPlayer player) throws IOException {
|
||||
String playerName = ByteBufUtils.readUTF8String(in);
|
||||
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user