mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
new command /animation (#1026)
This commit is contained in:
parent
23870711a0
commit
87b2d3bf4a
9 changed files with 409 additions and 311 deletions
|
|
@ -1391,6 +1391,28 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
catch (ObjectDisposedException) { return false; }
|
||||
}
|
||||
|
||||
public bool SendAnimation(int animation)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (animation == 0 || animation == 1)
|
||||
{
|
||||
List<byte> packet = new List<byte>();
|
||||
packet.AddRange(dataTypes.GetVarInt(animation));
|
||||
|
||||
SendPacket(PacketOutgoingType.Animation, packet);
|
||||
return true;
|
||||
}
|
||||
else;
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
catch (SocketException) { return false; }
|
||||
catch (System.IO.IOException) { return false; }
|
||||
catch (ObjectDisposedException) { return false; }
|
||||
}
|
||||
|
||||
public bool SendCloseWindow(int windowId)
|
||||
{
|
||||
try
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue