Fix prevent AntiCheat Block Breaking (In Scripts)

Fix prevent AntiCheat Block Breaking (In Scripts)
This commit is contained in:
Anon 2024-12-25 16:56:07 +01:00 committed by GitHub
commit 2409de2a2f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 100 additions and 16 deletions

View file

@ -651,9 +651,10 @@ public class WebSocketBot : ChatBot
var result = cmd.Parameters.Length switch
{
3 => DigBlock(location),
4 => DigBlock(location, (bool)cmd.Parameters[3]),
5 => DigBlock(location, (bool)cmd.Parameters[3], (bool)cmd.Parameters[4]),
// TODO Get blockFace direction from arguments
3 => DigBlock(location, Direction.Down),
4 => DigBlock(location, Direction.Down, (bool)cmd.Parameters[3]),
5 => DigBlock(location, Direction.Down, (bool)cmd.Parameters[3], (bool)cmd.Parameters[4]),
_ => false
};