mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Fix prevent AntiCheat Block Breaking (In Scripts)
Fix prevent AntiCheat Block Breaking (In Scripts)
This commit is contained in:
commit
2409de2a2f
7 changed files with 100 additions and 16 deletions
|
|
@ -1075,11 +1075,12 @@ namespace MinecraftClient.Scripting
|
|||
/// Attempt to dig a block at the specified location
|
||||
/// </summary>
|
||||
/// <param name="location">Location of block to dig</param>
|
||||
/// <param name="direction">Example: if your player is under a block that is being destroyed, use Down</param>
|
||||
/// <param name="swingArms">Also perform the "arm swing" animation</param>
|
||||
/// <param name="lookAtBlock">Also look at the block before digging</param>
|
||||
protected bool DigBlock(Location location, bool swingArms = true, bool lookAtBlock = true)
|
||||
protected bool DigBlock(Location location, Direction direction, bool swingArms = true, bool lookAtBlock = true)
|
||||
{
|
||||
return Handler.DigBlock(location, swingArms, lookAtBlock);
|
||||
return Handler.DigBlock(location, direction, swingArms, lookAtBlock);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
@ -1633,6 +1634,15 @@ namespace MinecraftClient.Scripting
|
|||
return Handler.GetProtocolVersion();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the horizontal direction of the takeoff.
|
||||
/// </summary>
|
||||
/// <returns>Return direction of view</returns>
|
||||
protected Direction GetHorizontalFacing()
|
||||
{
|
||||
return Handler.GetHorizontalFacing();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Invoke a task on the main thread, wait for completion and retrieve return value.
|
||||
/// </summary>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue