Solved bed crashes

This commit is contained in:
Andrew 2013-10-18 13:58:05 +13:00
parent eb01397c7d
commit d82ce55ff7

View File

@ -1180,6 +1180,15 @@ public class PacketsManager {
// Else if the disguise is attempting to send players a forbidden packet // Else if the disguise is attempting to send players a forbidden packet
case Packets.Server.ARM_ANIMATION: case Packets.Server.ARM_ANIMATION:
{
if (disguise.getType().isMisc() || (packets[0].getIntegers().read(1) == 3 && !disguise.getType().isPlayer())) {
packets = new PacketContainer[0];
}
break;
}
case Packets.Server.COLLECT: case Packets.Server.COLLECT:
{ {
@ -1227,7 +1236,7 @@ public class PacketsManager {
break; break;
} }
case Packets.Server.BED: case Packets.Server.ENTITY_LOCATION_ACTION:
{ {
if (!disguise.getType().isPlayer()) { if (!disguise.getType().isPlayer()) {
@ -1235,7 +1244,6 @@ public class PacketsManager {
} }
break; break;
} }
default: default:
break; break;
} }