RuneHive-Game
Loading...
Searching...
No Matches
SendInterfaceConfig.java
Go to the documentation of this file.
1package com.runehive.net.packet.out;
2
3
4import com.runehive.net.codec.ByteOrder;
5import com.runehive.game.world.entity.mob.player.Player;
6import com.runehive.net.packet.OutgoingPacket;
7
8public class SendInterfaceConfig extends OutgoingPacket {
9
10 private final int main;
11 private final int sub1;
12 private final int sub2;
13
14 public SendInterfaceConfig(int main, int sub1, int sub2) {
15 super(246, 6);
16 this.main = main;
17 this.sub1 = sub1;
18 this.sub2 = sub2;
19 }
20
21 @Override
22 public boolean encode(Player player) {
23 builder.writeShort(main, ByteOrder.LE)
24 .writeShort(sub1)
25 .writeShort(sub2);
26 return true;
27 }
28
29}
This class represents a character controlled by a player.
Definition Player.java:125
OutgoingPacket(int opcode, int capacity)
Represents the order in which bytes are written.
Definition ByteOrder.java:8
LE
Represents Little-endian.