mirror of
https://github.com/HibiscusMC/HMCCosmetics.git
synced 2025-12-29 03:49:19 +00:00
Added skin overlay on wardrobe
This commit is contained in:
@@ -191,6 +191,12 @@ public class PacketManager {
|
||||
return playerPackets.getPlayerInfoPacket(player, uuid);
|
||||
}
|
||||
|
||||
public static PacketContainer getPlayerOverlayPacket(final int playerId) throws IllegalStateException {
|
||||
if (playerPackets == null)
|
||||
throw new IllegalStateException("This cannot be used in version: " + Bukkit.getVersion());
|
||||
return playerPackets.getOverlayPacket(playerId);
|
||||
}
|
||||
|
||||
public static PacketContainer getRemovePlayerPacket(final Player player, final UUID uuid, final int entityId) {
|
||||
if (playerPackets == null)
|
||||
throw new IllegalStateException("This cannot be used in version: " + Bukkit.getVersion());
|
||||
|
||||
@@ -105,8 +105,13 @@ public class Wardrobe extends User {
|
||||
PacketManager.sendPacket(viewer, playerInfoPacket, playerSpawnPacket);
|
||||
this.spawnArmorStand(viewer, this.currentLocation, this.plugin.getSettings().getCosmeticSettings());
|
||||
this.updateArmorStand(viewer, plugin.getSettings(), this.currentLocation);
|
||||
PacketManager.sendPacket(viewer, PacketManager.getLookPacket(this.getEntityId(), this.currentLocation));
|
||||
PacketManager.sendPacket(viewer, PacketManager.getRotationPacket(this.getEntityId(), this.currentLocation));
|
||||
PacketManager.sendPacket(
|
||||
viewer,
|
||||
PacketManager.getLookPacket(this.getEntityId(), this.currentLocation),
|
||||
PacketManager.getRotationPacket(this.getEntityId(), this.currentLocation),
|
||||
PacketManager.getPlayerOverlayPacket(this.getEntityId())
|
||||
);
|
||||
viewer.sendMessage("Sent overlay");
|
||||
|
||||
this.spawned = true;
|
||||
this.startSpinTask(viewer);
|
||||
|
||||
Reference in New Issue
Block a user