mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
tiny improve of sneak command
This commit is contained in:
parent
d6a3ea0726
commit
5da55a2f9a
1 changed files with 4 additions and 2 deletions
|
|
@ -16,13 +16,15 @@ namespace MinecraftClient.Commands
|
||||||
if (sneaking)
|
if (sneaking)
|
||||||
{
|
{
|
||||||
var result = handler.sendEntityAction(Protocol.EntityActionType.StopSneaking);
|
var result = handler.sendEntityAction(Protocol.EntityActionType.StopSneaking);
|
||||||
sneaking = false;
|
if (result)
|
||||||
|
sneaking = false;
|
||||||
return result ? "You aren't sneaking anymore" : "Fail";
|
return result ? "You aren't sneaking anymore" : "Fail";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var result = handler.sendEntityAction(Protocol.EntityActionType.StartSneaking);
|
var result = handler.sendEntityAction(Protocol.EntityActionType.StartSneaking);
|
||||||
sneaking = true;
|
if (result)
|
||||||
|
sneaking = true;
|
||||||
return result ? "You are sneaking now" : "Fail";
|
return result ? "You are sneaking now" : "Fail";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue