RuneHive-Game
Loading...
Searching...
No Matches
SendItemModelOnInterface.java
Go to the documentation of this file.
1package com.runehive.net.packet.out;
2
3import com.runehive.net.codec.ByteOrder;
4import com.runehive.game.world.entity.mob.player.Player;
5import com.runehive.net.packet.OutgoingPacket;
6
8
9 private final int id;
10 private final int zoom;
11 private final int model;
12
13 public SendItemModelOnInterface(int id, int zoom, int model) {
14 super(246, 6);
15 this.id = id;
16 this.zoom = zoom;
17 this.model = model;
18 }
19
20 @Override
21 public boolean encode(Player player) {
22 builder.writeShort(id, ByteOrder.LE)
23 .writeShort(zoom)
24 .writeShort(model);
25 return true;
26 }
27
28}
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.