mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Add Chatbot API for Sneaking / Unsneaking without using SendAction
This commit is contained in:
parent
b2075bb811
commit
799bc814c5
1 changed files with 15 additions and 1 deletions
|
|
@ -676,9 +676,23 @@ namespace MinecraftClient
|
|||
Handler.UseItemOnHand();
|
||||
}
|
||||
/// <summary>
|
||||
/// start Sneaking
|
||||
/// </summary>
|
||||
protected bool Sneak()
|
||||
{
|
||||
return SendAction(Protocol.ActionType.StartSneaking);
|
||||
}
|
||||
/// <summary>
|
||||
/// Sends UnSneak
|
||||
/// </summary>
|
||||
protected bool UnSneak()
|
||||
{
|
||||
return SendAction(Protocol.ActionType.StopSneaking);
|
||||
}
|
||||
/// <summary>
|
||||
/// Send Entity Action
|
||||
/// </summary>
|
||||
protected bool SendAction(Protocol.ActionType action)
|
||||
private bool SendAction(Protocol.ActionType action)
|
||||
{
|
||||
return Handler.sendEntityAction(action);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue