Gintarus

C00PacketLoginStart

Jul 1st, 2025 (edited)
11
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.47 KB | None | 0 0
  1. package net.minecraft.network.login.client;
  2.  
  3. import com.mojang.authlib.GameProfile;
  4. import java.io.IOException;
  5. import java.util.UUID;
  6. import net.minecraft.network.INetHandler;
  7. import net.minecraft.network.Packet;
  8. import net.minecraft.network.PacketBuffer;
  9. import net.minecraft.network.login.INetHandlerLoginServer;
  10.  
  11. public class C00PacketLoginStart extends Packet
  12. {
  13. private GameProfile field_149305_a;
  14. private static final String __OBFID = "CL_00001379";
  15.  
  16. public C00PacketLoginStart() {}
  17.  
  18. public C00PacketLoginStart(GameProfile p_i45270_1_)
  19. {
  20. this.field_149305_a = p_i45270_1_;
  21. }
  22.  
  23. /**
  24. * Reads the raw packet data from the data stream.
  25. */
  26. public void readPacketData(PacketBuffer p_148837_1_) throws IOException
  27. {
  28. this.field_149305_a = new GameProfile((UUID)null, p_148837_1_.readStringFromBuffer(32));
  29. }
  30.  
  31. /**
  32. * Writes the raw packet data to the data stream.
  33. */
  34. public void writePacketData(PacketBuffer p_148840_1_) throws IOException
  35. {
  36. p_148840_1_.writeStringToBuffer(this.field_149305_a.getName());
  37. }
  38.  
  39. public void processPacket(INetHandlerLoginServer p_148833_1_)
  40. {
  41. p_148833_1_.processLoginStart(this);
  42. }
  43.  
  44. public GameProfile func_149304_c()
  45. {
  46. return this.field_149305_a;
  47. }
  48.  
  49. public void processPacket(INetHandler p_148833_1_)
  50. {
  51. this.processPacket((INetHandlerLoginServer)p_148833_1_);
  52. }
  53. }
  54.  
Advertisement
Add Comment
Please, Sign In to add comment