mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
New entity status packet event (#1506)
This commit is contained in:
parent
49603db657
commit
c15b071cad
4 changed files with 35 additions and 0 deletions
|
|
@ -113,6 +113,7 @@ namespace MinecraftClient
|
|||
public bool GetNetworkPacketCaptureEnabled() { return networkPacketCaptureEnabled; }
|
||||
public int GetProtocolVersion() { return protocolversion; }
|
||||
public ILogger GetLogger() { return this.Log; }
|
||||
public int GetPlayerEntityID() { return playerEntityID; }
|
||||
|
||||
// get bots list for unloading them by commands
|
||||
public List<ChatBot> GetLoadedChatBots()
|
||||
|
|
@ -2076,6 +2077,19 @@ namespace MinecraftClient
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Called when the status of an entity have been changed
|
||||
/// </summary>
|
||||
/// <param name="entityID">Entity ID</param>
|
||||
/// <param name="status">Status ID</param>
|
||||
public void OnEntityStatus(int entityID, byte status)
|
||||
{
|
||||
if (entityID == playerEntityID)
|
||||
{
|
||||
DispatchBotEvent(bot => bot.OnPlayerStatus(status));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Called when server sent a Time Update packet.
|
||||
/// </summary>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue