mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Latency improve (#1244)
* Update ChatBot.cs * Update McClient.cs * Update ChatBot.cs * Update ChatBot.cs * Update McClient.cs
This commit is contained in:
parent
02e294e3e8
commit
de9dcd6d77
2 changed files with 30 additions and 2 deletions
|
|
@ -780,7 +780,7 @@ namespace MinecraftClient
|
|||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get all Entityes
|
||||
/// Get all Entities
|
||||
/// </summary>
|
||||
/// <returns>All Entities</returns>
|
||||
public Dictionary<int, Entity> GetEntities()
|
||||
|
|
@ -788,6 +788,15 @@ namespace MinecraftClient
|
|||
return entities;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get all players latency
|
||||
/// </summary>
|
||||
/// <returns>All players latency</returns>
|
||||
public Dictionary<string, int> GetPlayersLatency()
|
||||
{
|
||||
return playersLatency;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get client player's inventory items
|
||||
/// </summary>
|
||||
|
|
@ -2082,6 +2091,7 @@ namespace MinecraftClient
|
|||
if (ent.Value.UUID == uuid && ent.Value.Name == playerName)
|
||||
{
|
||||
ent.Value.Latency = latency;
|
||||
DispatchBotEvent(bot => bot.OnLatencyUpdate(ent.Value, playerName, uuid, latency));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue