0x1F S1FPacketSetExperience
Updates the player's experience bar (level, total XP, progress).
Published 2026-06-18 · Updated 2026-10-14
Fields
| Field | Type | Description |
|---|---|---|
| experienceBar | float | Progress to next level (0.0-1.0) |
| totalExperience | VarInt | Total accumulated XP |
| level | VarInt | Current XP level |
Wire Encoding
| Field | Type | Notes |
|---|---|---|
| XP Progress | float | 0.0-1.0 |
| Total XP | VarInt | |
| Level | VarInt |
MCP References
NetHandlerPlayClient.handleSetExperience()Handler Interface
INetHandlerPlayClientVanilla Source
| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 | |
| 24 | |
| 25 | |
| 26 | |
| 27 | |
| 28 | |
| 29 | |
| 30 | |
| 31 | |
| 32 | |
| 33 | |
| 34 | |
| 35 | |
| 36 | |
| 37 | |
| 38 | |
| 39 | |
| 40 | |
| 41 | |
| 42 | |
| 43 | |
| 44 | |
| 45 | |
| 46 | |
| 47 | |
| 48 | |
| 49 | |
| 50 | |
| 51 | |
| 52 | |
| 53 | |
| 54 | |
| 55 | |
| 56 | |
| 57 | |
| 58 | |
| 59 | |
| 60 | |
| 61 | |
| 62 | |
| 63 | |
| 64 | |
| 65 | |
| 66 | |
| 67 | |
Deobfuscated MCP 1.8.9 source of S1FPacketSetExperience, fetched directly from Marcelektro/MavenMCP-1.8.9 (net/minecraft/network/play/server/S1FPacketSetExperience.java) at build time and verified present.
Deep Dive
Role in the protocol
S1FPacketSetExperience synchronizes the player's XP bar: experienceBar float (0.0-1.0 progress to next level), totalExperience VarInt, level VarInt. The server sends it from EntityPlayerMP when XP changes (line 401 in the corpus) and from ServerConfigurationManager on respawn/join (line 477). It is a pure display-state push: the client stores the three values and the HUD renders from them; the client never reports XP back, so the server's XP math is the only authoritative copy.
Vanilla handling
NetHandlerPlayClient.handleSetExperience calls thePlayer.setXPStats(progress, totalXp, level), which writes the player's experience, experienceTotal and experienceLevel fields. GuiIngame draws the bar and the level number from those fields every frame. Unlike health (S06) there is no client-side regeneration model behind it: the packet is the entire state.
Why clients touch it
Exactly one module in the 8 clients references S1F: Rise 5.99 Disabler, whose Hypixel Slime mode cancels the packet in onPacketReceive. Rise 6.1.30/6.2.4 only register the class in NetworkAPI (clientbound index 74). The XPHUD/AutoEnchant entries from older packet docs have zero corpus hits in the reference clients: XP is read from the player object, not from the packet.
Exploit surface
Cancelling S1F freezes the client-side XP bar while the server continues its own XP bookkeeping. Because the client never acknowledges XP, the divergence is invisible in the packet stream, and enchanting/anvil costs are computed server-side so nothing gameplay-relevant is gained. The Rise 5.99 usage is a state-freeze side effect of the Hypixel Slime disabler mode, which cancels the XP sync together with slime sound and particle packets so the client's stored minigame state stays static during the bypass window.
Server-Side Handling
EntityPlayerMP sends S1F at line 401 whenever the player's XP fields change (addExperience, addExperienceLevel, onEnchant, the level-up path). ServerConfigurationManager sends it at line 477 when a player joins or respawns so the bar starts correct. There is no inbound validation because the packet is clientbound; the server trusts its own XP math entirely.
Protocol Analysis
Three fields in order: float progress (0.0-1.0), VarInt total XP, VarInt level. The float is written as a 32-bit IEEE value, so progress is exact to the wire format. The client stores all three as player fields; GuiIngame renders progress as the bar fill and level as the number. A cancelled S1F leaves the previous values in place, which is the freeze the Rise 5.99 mode relies on.
Anti-Cheat Landscape
No anti-cheat measures S1F. XP is never echoed by the client, so a frozen bar cannot be distinguished from a laggy one by packet inspection alone. Servers that need XP for gameplay (enchanting, anvils, spawners) compute it server-side, which is why cancelling the packet is safe and why no bypass value exists beyond cosmetics or minigame state sync.
implementation Implementation Cases
A three-field display push for the XP bar with a single module hit in the reference set: Rise 5.99 Disabler's Hypixel Slime mode cancels it to freeze client state. Everything else is vanilla or the Rise 6.x script registry.
The Hypixel Slime mode cancels S1FPacketSetExperience so the client's stored XP state stays frozen while the rest of the mode's state-freeze bypass runs.
In onPacketReceive, when the hypixelSlime toggle is enabled, the handler rewrites S02PacketChat type-2 messages that contain 'UNAVAILABLE', cancels S29PacketSoundEffect with sound name 'mob.slime.big', cancels S2APacketParticles of type SLIME, and cancels S1FPacketSetExperience. The XP cancel keeps the minigame's XP sync from mutating client state mid-bypass.
// ===== FILE: Rise 5.99, dev/rise/module/impl/other/Disabler.java =====
/*
Copyright Alan Wood 2021
None of this code to be reused without my written permission
Intellectual Rights owned by Alan Wood
*/
package dev.rise.module.impl.other;
import de.gerrygames.viarewind.utils.ChatUtil;
import dev.rise.Rise;
import dev.rise.event.impl.motion.PreMotionEvent;
import dev.rise.event.impl.motion.TeleportEvent;
import dev.rise.event.impl.other.AttackEvent;
import dev.rise.event.impl.other.StrafeEvent;
import dev.rise.event.impl.other.WorldChangedEvent;
import dev.rise.event.impl.packet.PacketReceiveEvent;
import dev.rise.event.impl.packet.PacketSendEvent;
import dev.rise.module.Module;
import dev.rise.module.api.ModuleInfo;
import dev.rise.module.enums.Category;
import dev.rise.module.impl.movement.Fly;
import dev.rise.module.impl.movement.LongJump;
import dev.rise.module.impl.player.Scaffold;
import dev.rise.notifications.NotificationType;
import dev.rise.setting.Setting;
import dev.rise.setting.impl.BooleanSetting;
import dev.rise.setting.impl.NoteSetting;
import dev.rise.util.math.MathUtil;
import dev.rise.util.math.TimeUtil;
import dev.rise.util.pathfinding.MainPathFinder;
import dev.rise.util.player.MoveUtil;
import dev.rise.util.player.PacketUtil;
import dev.rise.util.player.PlayerUtil;
import io.netty.buffer.Unpooled;
import net.minecraft.client.entity.EntityPlayerSP;
import net.minecraft.entity.player.PlayerCapabilities;
import net.minecraft.network.Packet;
import net.minecraft.network.PacketBuffer;
import net.minecraft.network.play.client.*;
import net.minecraft.network.play.server.*;
import net.minecraft.util.*;
import org.apache.commons.lang3.RandomUtils;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentLinkedDeque;
import java.util.concurrent.ConcurrentLinkedQueue;
/**
* This module is designed to disable an anticheat or some of its checks
* in order to make bypassing easier/having extreme bypasses.
*/
@ModuleInfo(name = "Disabler", description = "Disables some servers AntiCheats", category = Category.OTHER)
public final class Disabler extends Module {
private final NoteSetting modeSettings = new NoteSetting("Mode Settings", this);
private final BooleanSetting hypixel = new BooleanSetting("Hypixel", this, false);
private final BooleanSetting mineland = new BooleanSetting("Mineland", this, false);
private final BooleanSetting mmcKeepSprint = new BooleanSetting("Minemenclub Keepsprint Check", this, false);
private final BooleanSetting mmcReach = new BooleanSetting("Minemenclub Reach Semi", this, false);
private final BooleanSetting hypixelSlime = new BooleanSetting("Hypixel Slime", this, false);
private final BooleanSetting dynamicPvP = new BooleanSetting("Dynamic PvP", this, false);
private final BooleanSetting ghostlyCombat = new BooleanSetting("Ghostly Combat", this, false);
private final BooleanSetting ghostly = new BooleanSetting("Ghostly", this, false);
private final BooleanSetting lunar = new BooleanSetting("Lunar", this, false);
private final BooleanSetting position = new BooleanSetting("Position Edit", this, false);
private final BooleanSetting vulcanCombat = new BooleanSetting("Vulcan Reach A", this, false);
private final BooleanSetting verusCombat = new BooleanSetting("Verus Combat", this, false);
private final BooleanSetting verus = new BooleanSetting("Verus", this, false);
private final BooleanSetting blocksMC = new BooleanSetting("BlocksMC", this, false);
private final BooleanSetting sentinel = new BooleanSetting("Sentinel", this, false);
private final BooleanSetting shartemis = new BooleanSetting("Shartemis Movement", this, false);
//Any disabler after this line will be hidden if this is true
private final BooleanSetting hideOldDisablers = new BooleanSetting("Hide Old Disablers", this, true);
private final NoteSetting oldModeSettings = new NoteSetting("Old Mode Settings", this);
private final BooleanSetting verusOld = new BooleanSetting("Verus Old", this, false);
private final BooleanSetting spartan = new BooleanSetting("Spartan", this, false);
private final BooleanSetting voidTp = new BooleanSetting("Void TP", this, false);
private final BooleanSetting clip = new BooleanSetting("Clip", this, false);
private final BooleanSetting tecnioRaper = new BooleanSetting("Tecnio AC Disabler", this, false);
private final BooleanSetting convertMovingPackets = new BooleanSetting("Covert Moving Packets", this, false);
private final BooleanSetting reverseConvertMovingPackets = new BooleanSetting("Reverse Covert Moving Packets", this, false);
private final BooleanSetting funnyCraft = new BooleanSetting("Funcraft", this, false);
private final BooleanSetting oxygen = new BooleanSetting("Oxygen", this, false);
private final NoteSetting packetSettings = new NoteSetting("Packet Settings", this);
private final BooleanSetting coc = new BooleanSetting("PacketInput", this, false);
private final BooleanSetting c0f = new BooleanSetting("ConfirmTransaction", this, false);
private final BooleanSetting c00 = new BooleanSetting("PacketKeepAlive", this, false);
private final BooleanSetting c08 = new BooleanSetting("PacketPlayerBlockPlacement", this, false);
private final BooleanSetting c13 = new BooleanSetting("PacketPlayerAbilities", this, false);
private final BooleanSetting c16 = new BooleanSetting("PacketClientStatus", this, false);
private final BooleanSetting c18 = new BooleanSetting("PacketSpectate", this, false);
private final BooleanSetting c19 = new BooleanSetting("PacketResourcePacketStatus", this, false);
private final ConcurrentLinkedQueue<Packet<?>> packetList = new ConcurrentLinkedQueue<>();
private final ConcurrentLinkedQueue<Packet<?>> packetList2 = new ConcurrentLinkedQueue<>();
private final ConcurrentHashMap<Packet<?>, Long> packetHashMap = new ConcurrentHashMap<>();
private final ConcurrentLinkedQueue<Packet<?>> transactions = new ConcurrentLinkedQueue<>();
private final ConcurrentLinkedQueue<Packet<?>> keepAlives = new ConcurrentLinkedQueue<>();
public static final ConcurrentLinkedQueue<PacketUtil.TimedPacket> packets = new ConcurrentLinkedQueue<>();
public static boolean spoofing;
private int ticksSinceTeleport;
private long currentDelay;
private final TimeUtil timer = new TimeUtil();
private long nextSend;
private boolean teleported;
private boolean exempt;
private float previousYaw, previousPitch;
@Override
public void onAttackEvent(final AttackEvent event) {
if (event.getTarget() != null) {
if (ghostlyCombat.isEnabled()) {
final double distance = mc.thePlayer.getDistanceToEntity(event.getTarget()) - 0.5657;
if (distance > 2.9) {
if (mc.thePlayer.canEntityBeSeen(event.getTarget()))
PacketUtil.sendPacket(new C03PacketPlayer.C04PacketPlayerPosition(event.getTarget().posX, event.getTarget().posY, event.getTarget().posZ, false));
else
event.setCancelled(true);
}
}
}
}
@Override
public void onUpdateAlwaysInGui() {
boolean hideAllAfter = false;
for (final Setting setting : getSettings()) {
setting.hidden = hideAllAfter;
if (hideOldDisablers == setting && hideOldDisablers.isEnabled()) {
hideAllAfter = true;
}
}
}
@Override
protected void onEnable() {
if (mc.isIntegratedServerRunning())
return;
if (hypixel.isEnabled()) {
final ChatComponentText chatcomponenttext = new ChatComponentText("Rejoin");
mc.getNetHandler().getNetworkManager().closeChannel(chatcomponenttext);
}
if (mmcReach.isEnabled()) {
Rise.INSTANCE.getNotificationManager().registerNotification("You need low ping for this disabler to not kick.", NotificationType.WARNING);
}
transactions.clear();
keepAlives.clear();
teleported = false;
timer.reset();
}
@Override
protected void onDisable() {
packetList.forEach(PacketUtil::sendPacketWithoutEvent);
packetList.clear();
spoofing = false;
packetList2.forEach(PacketUtil::sendPacketWithoutEvent);
packetList2.clear();
transactions.clear();
keepAlives.clear();
packetHashMap.clear();
mc.timer.timerSpeed = 1;
}
@Override
public void onPreMotion(final PreMotionEvent event) {
if (mc.isIntegratedServerRunning())
return;
if (hypixel.isEnabled() && PlayerUtil.isOnServer("Hypixel")) {
spoofing = true;
for (final PacketUtil.TimedPacket p : packets) {
if (System.currentTimeMillis() > p.getTime() + currentDelay) {
PacketUtil.sendPacketWithoutEvent(p.getPacket());
packets.remove(p);
this.currentDelay = Math.round(MathUtil.getRandom(200,250));
}
}
}
if (verusOld.isEnabled()) {
PacketUtil.sendPacketWithoutEvent(new C0CPacketInput());
PacketUtil.sendPacketWithoutEvent(new C18PacketSpectate(UUID.randomUUID()));
}
if (blocksMC.isEnabled()) {
if (mc.thePlayer.ticksExisted % 100 == 0) {
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C04PacketPlayerPosition(mc.thePlayer.posX, mc.thePlayer.posY, mc.thePlayer.posZ, mc.thePlayer.onGround));
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C04PacketPlayerPosition(mc.thePlayer.posX, -0.015625, mc.thePlayer.posZ, false));
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C04PacketPlayerPosition(mc.thePlayer.posX, mc.thePlayer.posY, mc.thePlayer.posZ, mc.thePlayer.onGround));
teleported = true;
}
if (timer.hasReached(500L) && !transactions.isEmpty()) {
PacketUtil.sendPacketWithoutEvent(transactions.poll());
timer.reset();
}
if (timer.hasReached(400L) && !keepAlives.isEmpty()) {
PacketUtil.sendPacketWithoutEvent(keepAlives.poll());
timer.reset();
}
}
if (hypixelSlime.isEnabled() && mc.thePlayer.capabilities.allowFlying) {
if (PlayerUtil.isOnServer("Hypixel")) {
final PlayerCapabilities playerCapabilities = new PlayerCapabilities();
playerCapabilities.isFlying = true;
PacketUtil.sendPacket(new C13PacketPlayerAbilities(playerCapabilities));
} else
PacketUtil.sendPacket(new C0BPacketEntityAction(mc.thePlayer, C0BPacketEntityAction.Action.RIDING_JUMP));
}
if (vulcanCombat.isEnabled()) {
if (timer.hasReached((long) (5000 + (Math.random() * 1000)))) {
packetList2.forEach(PacketUtil::sendPacketWithoutEvent);
packetList2.clear();
timer.reset();
}
}
if (sentinel.isEnabled()) {
for (final Iterator<Map.Entry<Packet<?>, Long>> iterator = packetHashMap.entrySet().iterator(); iterator.hasNext(); ) {
final Map.Entry<Packet<?>, Long> entry = iterator.next();
if (entry.getValue() < System.currentTimeMillis()) {
PacketUtil.sendPacket(entry.getKey());
iterator.remove();
}
}
}
if (mmcReach.isEnabled()) {
if (timer.hasReached((long) (500 + (Math.random() * 600)))) {
packetList.forEach(PacketUtil::sendPacketWithoutEvent);
packetList.clear();
timer.reset();
}
}
if (oxygen.isEnabled() && mc.thePlayer.onGround) {
event.setY(event.getY() + 0.42F);
event.setGround(false);
}
if (voidTp.isEnabled() && mc.thePlayer.ticksExisted % 20 == 0)
event.setY(event.getY() - 20 - Math.random());
if (clip.isEnabled()) {
if (mc.thePlayer.ticksExisted % 20 == 0) {
event.setY(event.getY() - 0.42);
event.setGround(false);
}
}
if (coc.isEnabled()) {
PacketUtil.sendPacketWithoutEvent(new C0CPacketInput(0.98F, 0.0F, false, false));
}
if (c08.isEnabled()) {
PacketUtil.sendPacketWithoutEvent(new C08PacketPlayerBlockPlacement(mc.thePlayer.getHeldItem()));
}
if (c13.isEnabled() || shartemis.isEnabled()) {
final C13PacketPlayerAbilities abilities = new C13PacketPlayerAbilities();
abilities.setAllowFlying(true);
abilities.setFlying(true);
PacketUtil.sendPacketWithoutEvent(abilities);
}
if (c16.isEnabled() || shartemis.isEnabled()) {
PacketUtil.sendPacketWithoutEvent(new C16PacketClientStatus(C16PacketClientStatus.EnumState.PERFORM_RESPAWN));
}
if (c18.isEnabled() || shartemis.isEnabled()) {
PacketUtil.sendPacketWithoutEvent(new C18PacketSpectate(mc.thePlayer.getUniqueID()));
}
if (c19.isEnabled()) {
PacketUtil.sendPacketWithoutEvent(new C19PacketResourcePackStatus("", C19PacketResourcePackStatus.Action.ACCEPTED));
}
if (tecnioRaper.isEnabled()) {
for (int i = 0; i < 10; i++) {
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C06PacketPlayerPosLook(
mc.thePlayer.posX, mc.thePlayer.posY, Double.MAX_VALUE, 0.0F, 0.0F, true
));
}
for (int i = 0; i < 40; i++) {
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C06PacketPlayerPosLook(
Double.MAX_VALUE, mc.thePlayer.posY, mc.thePlayer.posZ, 0.0F, 0.0F, true
));
}
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer(true));
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer(true));
tecnioRaper.setEnabled(false);
}
if (funnyCraft.isEnabled()) {
if (mc.thePlayer.ticksExisted % 4 == 0) {
PacketUtil.sendPacketWithoutEvent(new C0CPacketInput(Float.MAX_VALUE, Float.MAX_VALUE, false, false));
}
}
}
@Override
public void onTeleportEvent(final TeleportEvent event) {
if (blocksMC.isEnabled()) {
if (teleported) {
event.setCancelled(true);
}
teleported = false;
}
if(hypixel.isEnabled() && PlayerUtil.isOnServer("Hypixel")){
if (mc.thePlayer.ticksExisted < 100) {
event.setCancelled(true);
return;
}
this.ticksSinceTeleport = 0;
}
// if (mc.thePlayer.getDistance(event.getPosX(), event.getPosY(), event.getPosZ()) <= 9.5) {
// PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C06PacketPlayerPosLook(event.getPosX(), event.getPosY(), event.getPosZ(), event.getYaw(), event.getPitch(), false));
// event.setCancelled(true);
// }
// teleported = false;
}
@Override
public void onPacketReceive(final PacketReceiveEvent event) {
if (mc.isIntegratedServerRunning()) return;
final Packet<?> p = event.getPacket();
if (hypixel.isEnabled()) {
final Packet<?> packet = event.getPacket();
if (packet instanceof S08PacketPlayerPosLook) {
nextSend = 0;
}
}
if (hypixelSlime.isEnabled()) {
if (p instanceof S02PacketChat) {
final S02PacketChat chatMessage = (S02PacketChat) event.getPacket();
if (chatMessage.getType() == 2 && chatMessage.getChatComponent().getUnformattedText().contains("UNAVAILABLE")) {
chatMessage.chatComponent = new ChatComponentText("§aDOUBLE JUMP AVAILABLE§r");
}
}
if (p instanceof S29PacketSoundEffect) {
final S29PacketSoundEffect packetSoundEffect = (S29PacketSoundEffect) event.getPacket();
if (packetSoundEffect.getSoundName().equals("mob.slime.big")) {
event.setCancelled(true);
}
}
if (p instanceof S2APacketParticles) {
final S2APacketParticles particle = (S2APacketParticles) event.getPacket();
if (particle.getParticleType() == EnumParticleTypes.SLIME) {
event.setCancelled(true);
}
}
if (p instanceof S1FPacketSetExperience) {
event.setCancelled(true);
}
}
if (verus.isEnabled()) {
if (p instanceof S08PacketPlayerPosLook && timer.hasReached(1000)) {
final S08PacketPlayerPosLook packet = (S08PacketPlayerPosLook) p;
if (mc.thePlayer.getDistanceSq(packet.x, packet.y, packet.z) <= 9.5) {
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C06PacketPlayerPosLook(packet.x, packet.y, packet.z, packet.yaw, packet.pitch, false));
event.setCancelled(true);
}
teleported = false;
timer.reset();
}
}
}
@Override
public void onPacketSend(final PacketSendEvent event) {
if (mc.isIntegratedServerRunning())
return;
final Packet<?> packet = event.getPacket();
if (hypixel.isEnabled() && PlayerUtil.isOnServer("Hypixel")) {
if (packet instanceof C03PacketPlayer) {
final C03PacketPlayer wrapper = (C03PacketPlayer) packet;
if (wrapper instanceof C03PacketPlayer.C06PacketPlayerPosLook && ticksSinceTeleport <= 50 && mc.thePlayer.sendQueue.doneLoadingTerrain) {
event.setPacket(new C03PacketPlayer.C04PacketPlayerPosition(wrapper.x + Double.MIN_NORMAL, wrapper.y, wrapper.z - Double.MIN_NORMAL, ((C03PacketPlayer.C06PacketPlayerPosLook) wrapper).isOnGround()));
}
}
ticksSinceTeleport++;
if (mc.thePlayer == null || !mc.thePlayer.sendQueue.doneLoadingTerrain) {
packets.clear();
return;
}
if (mc.thePlayer.isDead || mc.isSingleplayer()) {
packets.forEach(p -> PacketUtil.sendPacketWithoutEvent(p.getPacket()));
packets.clear();
return;
}
if (spoofing) {
if (packet instanceof C0FPacketConfirmTransaction || packet instanceof C00PacketKeepAlive) {
packets.add(new PacketUtil.TimedPacket(packet, System.currentTimeMillis()));
event.setCancelled(true);
}
} else if (packet instanceof C03PacketPlayer) {
packets.forEach(p -> PacketUtil.sendPacketWithoutEvent(p.getPacket()));
packets.clear();
}
}
if (vulcanCombat.isEnabled() && packet instanceof C0FPacketConfirmTransaction) {
packetList2.add(packet);
event.setCancelled(true);
}
if (mineland.isEnabled()) {
if (event.getPacket() instanceof C03PacketPlayer && !mc.thePlayer.isSwingInProgress && !mc.thePlayer.isUsingItem() && !((C03PacketPlayer) event.getPacket()).isMoving()) {
event.setCancelled(true);
}
}
if (blocksMC.isEnabled()) {
if (packet instanceof C0FPacketConfirmTransaction) {
transactions.add(packet);
event.setCancelled(true);
if (transactions.size() > 300) {
PacketUtil.sendPacketWithoutEvent(transactions.poll());
}
}
if (packet instanceof C00PacketKeepAlive) {
final C00PacketKeepAlive c00 = (C00PacketKeepAlive) packet;
c00.key -= 30;
keepAlives.add(c00);
event.setCancelled(true);
}
if (packet instanceof C0BPacketEntityAction) {
final C0BPacketEntityAction c0B = (C0BPacketEntityAction) packet;
if (c0B.getAction().equals(C0BPacketEntityAction.Action.START_SPRINTING)) {
if (mc.thePlayer.serverSprintState) {
PacketUtil.sendPacketWithoutEvent(new C0BPacketEntityAction(mc.thePlayer, C0BPacketEntityAction.Action.STOP_SPRINTING));
mc.thePlayer.serverSprintState = false;
}
event.setCancelled(true);
}
if (c0B.getAction().equals(C0BPacketEntityAction.Action.STOP_SPRINTING)) {
event.setCancelled(true);
}
}
if (packet instanceof C03PacketPlayer && !mc.thePlayer.isSwingInProgress &&
!mc.thePlayer.isUsingItem() && !((C03PacketPlayer) packet).isMoving()) {
event.setCancelled(true);
}
}
if (verus.isEnabled()) {
if (packet instanceof C0BPacketEntityAction) {
final C0BPacketEntityAction c0B = (C0BPacketEntityAction) packet;
if (c0B.getAction().equals(C0BPacketEntityAction.Action.START_SPRINTING)) {
if (EntityPlayerSP.serverSprintState) {
PacketUtil.sendPacketWithoutEvent(new C0BPacketEntityAction(mc.thePlayer, C0BPacketEntityAction.Action.STOP_SPRINTING));
EntityPlayerSP.serverSprintState = false;
}
event.setCancelled(true);
}
if (c0B.getAction().equals(C0BPacketEntityAction.Action.STOP_SPRINTING)) {
event.setCancelled(true);
}
}
if (packet instanceof C00PacketKeepAlive) {
final C00PacketKeepAlive c00 = (C00PacketKeepAlive) packet;
c00.key = -c00.key;
}
if (packet instanceof C03PacketPlayer) {
final C03PacketPlayer c03 = (C03PacketPlayer) packet;
mc.timer.timerSpeed = 0.75F;
if (c03.y % 0.015625 == 0)
c03.setOnGround(true);
if (timer.hasReached(1000) && !teleported) {
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C04PacketPlayerPosition());
teleported = true;
}
if (mc.thePlayer.ticksExisted % 100 == 0)
teleported = false;
}
}
if (verusCombat.isEnabled() && mc.thePlayer.ticksExisted > 20 && !mc.thePlayer.capabilities.allowFlying) {
if (packet instanceof C0FPacketConfirmTransaction)
event.setCancelled(true);
}
if (position.isEnabled() && packet instanceof C03PacketPlayer) {
final C03PacketPlayer c03 = (C03PacketPlayer) event.getPacket();
c03.setY(c03.getY() + 0.015625);
}
if (ghostly.isEnabled()) {
if (packet instanceof C03PacketPlayer) {
PacketUtil.sendPacketWithoutEvent(new C0CPacketInput());
C03PacketPlayer c03PacketPlayer = ((C03PacketPlayer) packet);
double mathGround = Math.round(c03PacketPlayer.y / 0.015625) * 0.015625;
c03PacketPlayer.y = mathGround;
c03PacketPlayer.setOnGround(true);
event.setPacket(c03PacketPlayer);
}
if (packet instanceof C0BPacketEntityAction) {
final C0BPacketEntityAction c0B = (C0BPacketEntityAction) packet;
if (c0B.getAction().equals(C0BPacketEntityAction.Action.START_SPRINTING)) {
if (EntityPlayerSP.serverSprintState) {
PacketUtil.sendPacketWithoutEvent(new C0BPacketEntityAction(mc.thePlayer, C0BPacketEntityAction.Action.STOP_SPRINTING));
EntityPlayerSP.serverSprintState = false;
}
event.setCancelled(true);
}
if (c0B.getAction().equals(C0BPacketEntityAction.Action.STOP_SPRINTING)) {
event.setCancelled(true);
}
}
}
if (dynamicPvP.isEnabled()) {
if (packet instanceof C03PacketPlayer) {
if (mc.thePlayer.ticksExisted % 3 == 0)
event.setCancelled(true);
final C03PacketPlayer packetPlayer = (C03PacketPlayer) event.getPacket();
double x = mc.thePlayer.posX, y = mc.thePlayer.posY, z = mc.thePlayer.posZ;
if (packetPlayer.isMoving()) {
x = packetPlayer.getPositionX();
y = packetPlayer.getPositionY();
z = packetPlayer.getPositionZ();
}
if (mc.thePlayer.ticksExisted % 20 == 0)
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C04PacketPlayerPosition(x, y, z, packetPlayer.isOnGround()));
event.setPacket(new C03PacketPlayer.C06PacketPlayerPosLook(x, y, z, mc.thePlayer.rotationYaw, mc.thePlayer.rotationPitch, packetPlayer.isOnGround()));
}
if (packet instanceof C0FPacketConfirmTransaction || packet instanceof C00PacketKeepAlive)
event.setCancelled(true);
if (packet instanceof C0BPacketEntityAction) {
final C0BPacketEntityAction c0B = (C0BPacketEntityAction) packet;
if (c0B.getAction().equals(C0BPacketEntityAction.Action.START_SPRINTING)) {
if (EntityPlayerSP.serverSprintState) {
PacketUtil.sendPacketWithoutEvent(new C0BPacketEntityAction(mc.thePlayer, C0BPacketEntityAction.Action.STOP_SPRINTING));
EntityPlayerSP.serverSprintState = false;
}
event.setCancelled(true);
}
if (c0B.getAction().equals(C0BPacketEntityAction.Action.STOP_SPRINTING)) {
event.setCancelled(true);
}
}
}
if (spartan.isEnabled()) {
PacketUtil.sendPacketWithoutEvent(new C03PacketPlayer.C06PacketPlayerPosLook(mc.thePlayer.posX, mc.thePlayer.posY, mc.thePlayer.posZ, mc.thePlayer.rotationYaw, 91, mc.thePlayer.onGround));
}
if (sentinel.isEnabled()) {
if (packet instanceof C0FPacketConfirmTransaction || packet instanceof C00PacketKeepAlive) {
// packetHashMap.put(p, System.currentTimeMillis() + RandomUtils.nextLong(15000, 25000));
event.setCancelled(true);
}
if (packet instanceof C03PacketPlayer.C04PacketPlayerPosition) {
final C03PacketPlayer.C04PacketPlayerPosition packetPlayerPosition = (C03PacketPlayer.C04PacketPlayerPosition) packet;
event.setPacket(new C03PacketPlayer.C06PacketPlayerPosLook(packetPlayerPosition.getX(), packetPlayerPosition.getY(), packetPlayerPosition.getZ(), mc.thePlayer.rotationYaw + (mc.thePlayer.ticksExisted % 2 == 0 ? RandomUtils.nextFloat(0.05F, 0.1F) : -RandomUtils.nextFloat(0.05F, 0.1F)), mc.thePlayer.rotationPitch, packetPlayerPosition.isOnGround()));
}
}
if (c0f.isEnabled() || shartemis.isEnabled()) {
if (packet instanceof C0FPacketConfirmTransaction)
event.setCancelled(true);
}
if (c00.isEnabled()) {
if (packet instanceof C00PacketKeepAlive)
event.setCancelled(true);
}
if (lunar.isEnabled()) {
if (packet instanceof C0FPacketConfirmTransaction || packet instanceof C00PacketKeepAlive)
event.setCancelled(true);
if (packet instanceof C0BPacketEntityAction) {
final C0BPacketEntityAction c0B = (C0BPacketEntityAction) packet;
if (c0B.getAction().equals(C0BPacketEntityAction.Action.START_SPRINTING)) {
if (EntityPlayerSP.serverSprintState) {
PacketUtil.sendPacketWithoutEvent(new C0BPacketEntityAction(mc.thePlayer, C0BPacketEntityAction.Action.STOP_SPRINTING));
EntityPlayerSP.serverSprintState = false;
}
event.setCancelled(true);
}
if (c0B.getAction().equals(C0BPacketEntityAction.Action.STOP_SPRINTING)) {
event.setCancelled(true);
}
}
if (packet instanceof C03PacketPlayer.C04PacketPlayerPosition) {
final C03PacketPlayer.C04PacketPlayerPosition packetPlayerPosition = (C03PacketPlayer.C04PacketPlayerPosition) packet;
event.setPacket(new C03PacketPlayer.C06PacketPlayerPosLook(packetPlayerPosition.getX(), packetPlayerPosition.getY(), packetPlayerPosition.getZ(), mc.thePlayer.rotationYaw + (mc.thePlayer.ticksExisted % 2 == 0 ? RandomUtils.nextFloat(0.05F, 0.1F) : -RandomUtils.nextFloat(0.05F, 0.1F)), mc.thePlayer.rotationPitch, packetPlayerPosition.isOnGround()));
}
}
if (reverseConvertMovingPackets.isEnabled()) {
if (packet instanceof C03PacketPlayer.C06PacketPlayerPosLook) {
final C03PacketPlayer.C06PacketPlayerPosLook packetPlayerPosition = (C03PacketPlayer.C06PacketPlayerPosLook) packet;
event.setPacket(new C03PacketPlayer.C04PacketPlayerPosition(packetPlayerPosition.getX(), packetPlayerPosition.getY(), packetPlayerPosition.getZ(), packetPlayerPosition.isOnGround()));
}
}
if (convertMovingPackets.isEnabled()) {
if (packet instanceof C03PacketPlayer.C04PacketPlayerPosition) {
final C03PacketPlayer.C04PacketPlayerPosition packetPlayerPosition = (C03PacketPlayer.C04PacketPlayerPosition) packet;
event.setPacket(new C03PacketPlayer.C06PacketPlayerPosLook(packetPlayerPosition.getX(), packetPlayerPosition.getY(), packetPlayerPosition.getZ(), mc.thePlayer.rotationYaw + (mc.thePlayer.ticksExisted % 2 == 0 ? RandomUtils.nextFloat(0.05F, 0.1F) : -RandomUtils.nextFloat(0.05F, 0.1F)), mc.thePlayer.rotationPitch, packetPlayerPosition.isOnGround()));
}
}
if (mmcKeepSprint.isEnabled()) {
if (packet instanceof C0BPacketEntityAction) {
final C0BPacketEntityAction c0B = (C0BPacketEntityAction) packet;
if (c0B.getAction().equals(C0BPacketEntityAction.Action.START_SPRINTING)) {
if (EntityPlayerSP.serverSprintState) {
PacketUtil.sendPacketWithoutEvent(new C0BPacketEntityAction(mc.thePlayer, C0BPacketEntityAction.Action.STOP_SPRINTING));
EntityPlayerSP.serverSprintState = false;
}
event.setCancelled(true);
}
if (c0B.getAction().equals(C0BPacketEntityAction.Action.STOP_SPRINTING)) {
event.setCancelled(true);
}
}
}
if (mmcReach.isEnabled() && (PlayerUtil.isOnServer("minemen") || PlayerUtil.isOnServer("mineman"))) {
if (packet instanceof C0FPacketConfirmTransaction) {
event.setCancelled(true);
}
}
}
@Override
public void onStrafe(final StrafeEvent event) {
if (mineland.isEnabled()) {
PacketUtil.sendPacket(new C18PacketSpectate(UUID.randomUUID()));
}
}
@Override
public void onWorldChanged(final WorldChangedEvent event) {
}
}
// NOTE (AI): The S1FPacketSetExperience hit lives in the Hypixel Slime mode of
// this disabler (line ~391 in onPacketReceive). The mode cancels the XP sync
// packet together with the slime sound (S29PacketSoundEffect "mob.slime.big")
// and slime particle (S2APacketParticles SLIME) packets and a chat rewrite, as
// part of a state-freeze bypass for the Hypixel Slime minigame. The rest of the
// file is kept verbatim because the schema requires the full file; it shows the
// full mode matrix (Hypixel, Mineland, MMC, Dynamic PvP, Ghostly, Lunar, Verus,
// Spartan, BlocksMC, Sentinel, Funcraft) of the Rise 5.99 disabler.anticheat Anti-Cheat Checks
The experience packet has no detection story. The corpus shows one functional use: Intave writes S1F itself as a telemetry channel, packing ping and simulation data into the level field, and Artemis registers a PacketPlayServerExperience interface in its wrapper tree. The other hits are incidental: Negativity lists the packet in a type enum, NCP prints the player's exp in an admin inspect command, and the Photon hit is a keyword collision with SPAWN_EXPERIENCE_ORB (S11), not S1F. No anticheat reads S1F to detect anything.
Reuse the experience packet as a covert data channel: Intave sends S1F with the level field packed with telemetry instead of real XP.
sendPacketWithExperience builds an EXPERIENCE packet with progress 0 and total XP 0, writes the level field to a packed value, and sends it to the player. ConnectionMetadata encodes ping averages (ping times 1000 plus short ping) when LATENCY_PING_AS_XP_LEVEL is on; Physics.java sends the simulation rate limiter counter; StorageLoader replays a storage tag as a recurring level set.
// ===== FILE: intave-intave, src/main/java/de/jpx3/intave/user/meta/ConnectionMetadata.java =====
package de.jpx3.intave.user.meta;
import com.comphenix.protocol.PacketType;
import com.comphenix.protocol.ProtocolLibrary;
import com.comphenix.protocol.events.PacketContainer;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import com.google.gson.JsonObject;
import de.jpx3.intave.IntaveControl;
import de.jpx3.intave.annotate.DispatchTarget;
import de.jpx3.intave.annotate.Nullable;
import de.jpx3.intave.executor.RateLimiter;
import de.jpx3.intave.math.Occurrences;
import de.jpx3.intave.module.feedback.DelayedPacket;
import de.jpx3.intave.module.feedback.FeedbackQueue;
import de.jpx3.intave.module.feedback.FeedbackRequest;
import de.jpx3.intave.module.feedback.PendingCountingFeedbackObserver;
import de.jpx3.intave.module.tracker.entity.Entity;
import de.jpx3.intave.packet.PacketSender;
import org.bukkit.entity.Player;
import java.util.*;
import java.util.concurrent.CopyOnWriteArrayList;
import java.util.concurrent.DelayQueue;
import java.util.concurrent.ThreadLocalRandom;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.locks.ReentrantLock;
public final class ConnectionMetadata {
private final Player player;
private final FeedbackQueue feedbackQueue = new FeedbackQueue();
public final ReentrantLock feedbackLock = new ReentrantLock();
private final Map<Long, Queue<FeedbackRequest<?>>> transactionOptionalAppendMap = Maps.newConcurrentMap();
private final Map<Integer, Entity> entitiesById = Maps.newConcurrentMap();
private final Map<Integer, Integer> entityVehicles = Maps.newConcurrentMap();
private final Map<Integer, Set<Integer>> entityMounts = Maps.newConcurrentMap();
private final Set<Integer> entityIds = new HashSet<>();
private final List<Entity> synchronizedEntities = Lists.newCopyOnWriteArrayList();
public PendingCountingFeedbackObserver pendingBlockUpdates;
private List<Entity> tickedEntities = new CopyOnWriteArrayList<>();
private final Map<Long, Long> remainingPingPacketTimestamps = Maps.newConcurrentMap();
private final List<Long> latencyDifferenceBalance = Lists.newCopyOnWriteArrayList();
// not used
private final Map<Integer, Integer> localEntityIdsToGlobalIds = Maps.newConcurrentMap();
private final Map<Integer, Integer> globalEntityIdsToLocalIds = Maps.newConcurrentMap();
private final Set<Integer> globalEntityIdsForRemoval = new HashSet<>();
public final Queue<Runnable> nextFeedbackSubscribers = new LinkedList<>();
public final Map<Integer, Integer> duplicationOwners = new HashMap<>();
public final Map<Integer, DecoySide> decoySides = new HashMap<>();
public final Set<Integer> duplicatedEntityIds = new HashSet<>();
public final Set<Integer> shouldNotBeAttacked = new HashSet<>();
@Deprecated
public boolean markAttackInvalid;
public boolean debugEntityTracing = false;
public RateLimiter refreshBlockRatelimit = new RateLimiter(400, 2, TimeUnit.SECONDS);
public final Random feedbackUserKeyRandom = new Random();
public int lastFeedbackUserKey = Integer.MIN_VALUE;
public int generatorRunningNum = 0;
public int simulatedBlockAckNum;
public int windowClickId;
public int transactionKeepAliveInvalidOrderVL;
public enum DecoySide {
FIRST_IS_DECOY,
SECOND_IS_DECOY,
}
// private final Set<Integer> takenLocalEntityIds = new HashSet<>();
private int localEntityIdCounter = 1;
public long lastCCCInfoMessageSent = 0;
public boolean sendAsyncMessage = false;
public boolean eligibleForTransactionTimeout = false;
public int speculativeMovementTicks = 0;
public int randomTransactionIdShift = ThreadLocalRandom.current().nextInt(1, 2000);
public int attacksQueued;
public long lastAttackQueueRequest;
private final Deque<Object> bufferEnqueue = new ArrayDeque<>(8500);
private final DelayQueue<DelayedPacket> delayQueue = new DelayQueue<>();
public long lastBufferNotification = 0;
public long lastDelayNotification = 0;
public long lastDelaySlot = 0;
public long lastBufferEnqueue = 0;
public long timestampRequiredForAttack = 0;
public boolean ignorePacketEnqueue;
public long delayedPackets = 0;
public long lastDelayRequest = 0;
public long blinkDeactivated = 0;
public long lastRespawn = 0;
public long firstEnqueue = 0;
public boolean lastBlinkState = false;
// Client Synchronization
public int latency;
public long lastKeepAliveDifference;
public int latencyJitter;
public long transactionNumCounter = 0;
public long lastReceivedTransactionNum = -1;
public long lastSynchronization = System.nanoTime();
public long transactionPacketCounter;
public long transactionPacketCounterReset;
public long feedbackFaults = 0;
public int nextWindowOpenSlots = 0;
public boolean assumeWindowOpen = false;
// Lag identification
private long lastMovementTimestamps;
private final List<Long> movementLagSpikeHistory = new ArrayList<>();
private static final long DELAY_PURGE_INTERVAL = 1000 * 60;
public final Occurrences<Integer> attackDelays = new Occurrences<>(DELAY_PURGE_INTERVAL);
public final Occurrences<Integer> feedbackDelays = new Occurrences<>(DELAY_PURGE_INTERVAL);
// labymod data
public JsonObject labyModData = new JsonObject();
public ConnectionMetadata(Player player) {
this.player = player;
this.globalEntityIdsToLocalIds.put(-1, -1);
this.localEntityIdsToGlobalIds.put(-1, -1);
this.globalEntityIdsToLocalIds.put(0, 0);
this.localEntityIdsToGlobalIds.put(0, 0);
if (player != null) {
int entityId = player.getEntityId();
this.globalEntityIdsToLocalIds.put(entityId, entityId);
this.localEntityIdsToGlobalIds.put(entityId, entityId);
}
}
@DispatchTarget
public void receiveMovement() {
long now = System.currentTimeMillis();
if (this.lastMovementTimestamps != 0) {
long difference = now - lastMovementTimestamps;
movementLagSpikeHistory.add(difference);
if (movementLagSpikeHistory.size() > 3) {
movementLagSpikeHistory.remove(0);
}
}
this.lastMovementTimestamps = now;
}
public long lastMovementPacket() {
return lastMovementTimestamps;
}
public double averageMovementPacketTimestamp() {
return averageOf(movementLagSpikeHistory);
}
private double averageOf(List<? extends Number> data) {
double sum = 0;
for (Number element : data) {
sum += element.doubleValue();
}
if (sum == 0) {
return 0;
}
return sum / data.size();
}
private long transactionSum = 0;
private long transactionNum = 0;
private long shortTransactionSum = 0;
private long shortTransactionNum = 0;
private long lastShortReset = System.currentTimeMillis();
public void receivedTransactionAfter(long milliseconds) {
long cappedMillis = Math.min(milliseconds, 1000);
transactionSum += cappedMillis;
transactionNum++;
shortTransactionSum += cappedMillis;
shortTransactionNum++;
if (transactionNum > 4096) {
transactionSum /= 2;
transactionNum /= 2;
}
if (System.currentTimeMillis() - lastShortReset > 4000) {
shortTransactionSum /= 2;
shortTransactionNum /= 2;
lastShortReset = System.currentTimeMillis();
}
feedbackDelays.occurred(Math.min(40, (int) milliseconds / 50));
if (IntaveControl.LATENCY_PING_AS_XP_LEVEL && transactionNum % 10 == 0) {
sendPacketWithExperience(player, (int) ((int) transactionPingAverage() * 1000 + shortTransactionPingAverage()));
}
}
private void sendPacketWithExperience(Player player, int level) {
PacketContainer packet = ProtocolLibrary.getProtocolManager().createPacket(PacketType.Play.Server.EXPERIENCE);
packet.getFloat().write(0, 0f);
packet.getIntegers().write(0, 0);
packet.getIntegers().write(1, level);
PacketSender.sendServerPacket(player, packet);
}
public long transactionPingAverage() {
return transactionNum == 0 ? 0 : transactionSum / transactionNum;
}
public long shortTransactionPingAverage() {
return shortTransactionNum == 0 ? 0 : shortTransactionSum / shortTransactionNum;
}
// public void receivedTransactionAfter(long milliseconds) {
// if (transactionPings.size() > 1024 * 8) {
// transactionPings.remove(0);
// }
// transactionPings.add(milliseconds);
// }
//
// private long transactionPingCache = -1;
// private long lastTPCRefresh = 0;
//
// public long transactionPingAverage() {
// if (System.currentTimeMillis() - lastTPCRefresh > 5000) {
// long sum = 0;
// for (Long transactionPing : transactionPings) {
// sum += Math.min(transactionPing, 500);
// }
// lastTPCRefresh = System.currentTimeMillis();
// transactionPingCache = sum / transactionPings.size();
// }
// return transactionPingCache;
// }
public FeedbackQueue feedbackQueue() {
return feedbackQueue;
}
public Map<Long, Queue<FeedbackRequest<?>>> transactionAppendMap() {
return transactionOptionalAppendMap;
}
public Integer globalEntityIdFromLocal(Integer localEntityId) {
return localEntityIdsToGlobalIds.getOrDefault(localEntityId, -1);
}
public Integer localEntityIdFromGlobal(Integer globalEntityId) {
return globalEntityIdsToLocalIds.getOrDefault(globalEntityId, -1);
}
public Map<Integer, Integer> globalEntityIdsToLocalIds() {
return new HashMap<>(globalEntityIdsToLocalIds);
}
public void insertIdTranslations(Map<Integer, Integer> globalToLocal) {
int highestLocalId = 0;
for (Map.Entry<Integer, Integer> entry : globalToLocal.entrySet()) {
globalEntityIdsToLocalIds.put(entry.getKey(), entry.getValue());
localEntityIdsToGlobalIds.put(entry.getValue(), entry.getKey());
if (entry.getValue() > highestLocalId) {
highestLocalId = entry.getValue();
}
}
localEntityIdCounter = highestLocalId + 1;
}
public synchronized Integer newLocalIdFor(int globalEntityId) {
int localEntityId = localEntityIdCounter++;
int attempt = 0;
while (localEntityIdsToGlobalIds.containsKey(localEntityId)) {
localEntityId = localEntityIdCounter += 7;
if (attempt++ > 50) {
localEntityId = localEntityIdCounter += 100;
}
}
globalEntityIdsForRemoval.remove(globalEntityId);
localEntityIdsToGlobalIds.put(localEntityId, globalEntityId);
globalEntityIdsToLocalIds.put(globalEntityId, localEntityId);
return localEntityId;
}
public synchronized void markIdAsDeprecated(int globalEntityId) {
globalEntityIdsForRemoval.add(globalEntityId);
}
public synchronized void removeId(int globalEntityId) {
if (globalEntityId == -1 || globalEntityId == 0 || player == null || globalEntityId == player.getEntityId()) {
return;
}
if (!globalEntityIdsForRemoval.remove(globalEntityId)) {
return;
}
Integer localEntityId = globalEntityIdsToLocalIds.remove(globalEntityId);
if (localEntityId != null) {
localEntityIdsToGlobalIds.remove(localEntityId);
// localEntityIdCounter = Math.min(localEntityIdCounter, localEntityId);
}
}
public void noteMount(int entityId, int vehicleId) {
entityVehicles.put(entityId, vehicleId);
entityMounts.computeIfAbsent(vehicleId, k -> new HashSet<>()).add(entityId);
}
public void noteDismount(int entityId) {
Integer vehicleId = entityVehicles.remove(entityId);
if (vehicleId != null) {
Set<Integer> mounts = entityMounts.get(vehicleId);
if (mounts != null) {
mounts.remove(entityId);
if (mounts.isEmpty()) {
entityMounts.remove(vehicleId);
}
}
}
}
public Integer vehicleOf(int entityId) {
return entityVehicles.get(entityId);
}
public List<Integer> sittingOn(int entityId) {
return entityMounts.get(entityId) == null ? Collections.emptyList() : new ArrayList<>(entityMounts.get(entityId));
}
@Deprecated
public Collection<Entity> entities() {
return entitiesById.values();
}
@Nullable
public Entity entityBy(int identifier) {
return entitiesById.get(identifier);
}
public void enterEntity(Entity entity) {
entitiesById.put(entity.entityId(), entity);
entityIds.add(entity.entityId());
// entities.add(entity);
// tickedEntities.add(entity);
}
public Entity markForDeletion(int entityId) {
Entity old = entitiesById.put(entityId, Entity.destroyedEntity());
entityIds.remove(entityId);
// we will not override the entity collection, as it would require a lot of performance and seems quite redundant in the first place
// for (int i = 0, entitiesSize = entities.size(); i < entitiesSize; i++) {
// EntityShade entity = entities.get(i);
// if (entity.entityId() == entityId) {
// entities.set(i, EntityShade.destroyedEntity());
// }
// }
// using removeIf requires the least amount of locking and array modifications for CopyOnWriteArrayLists
// entities.removeIf(entity -> entity.entityId() == entityId);
return old;
}
public void removeEntityIfMarked(int entityId) {
if (entitiesById.get(entityId) instanceof Entity.Destroyed) {
entitiesById.remove(entityId);
}
}
public void queueToNextTransaction(Runnable runnable) {
nextFeedbackSubscribers.add(runnable);
}
public DelayQueue<DelayedPacket> delayedPackets() {
return delayQueue;
}
public List<Entity> tracedEntities() {
return synchronizedEntities;
}
public List<Entity> tickedEntities() {
return tickedEntities;
}
public void setTickedEntities(List<Entity> ticked) {
this.tickedEntities = ticked;
}
public Map<Long, Long> pingPackets() {
return remainingPingPacketTimestamps;
}
public List<Long> latencyDifferenceBalance() {
return latencyDifferenceBalance;
}
public Deque<Object> enqueuedPackets() {
return bufferEnqueue;
}
public Set<Integer> entityIds() {
return entityIds;
}
}
// NOTE (AI): sendPacketWithExperience (lines 202-208) and the LATENCY_PING_AS_XP_LEVEL branch (lines 197-199) are the S1F-relevant parts; the rest of the file is transaction ping bookkeeping.Related Packets
Wiki Cross-Reference
Clientbound 0x1F: float bar progress 0.0-1.0, VarInt level, VarInt total XP.
Pure display sync for HUD bar and level number; server keeps authoritative XP.
Sent on XP change, join and respawn; client never echoes XP back.
MCP 1.8.9 S1FPacketSetExperience implements Packet
1.8.9 callers: EntityPlayerMP.onUpdateEntity sends new S1FPacketSetExperience (line 422) +1 more: https://github.com/Marcelektro/MavenMCP-1.8.9/blob/master/src/main/java/net/minecraft/entity/player/EntityPlayerMP.java
Cross-checked against minecraft.wiki (CC BY-SA 3.0) for 1.8.9 accuracy.
Vanilla Internals
Full 1.8.9 logic-class sources that send or handle this packet, stored verbatim.