mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2024-08-25 04:37:44 +00:00
Comment out/remove the /speed walk code, until the client properly supports this function.
This commit is contained in:
parent
65741403e0
commit
298f3dc3b2
|
@ -39,30 +39,38 @@ public class Commandspeed extends EssentialsCommand
|
|||
boolean isBypass = user.isAuthorized("essentials.speed.bypass");
|
||||
if (args.length == 1)
|
||||
{
|
||||
isFly = user.isFlying();
|
||||
//isFly = user.isFlying();
|
||||
isFly = true;
|
||||
speed = getMoveSpeed(args[0]);
|
||||
}
|
||||
else
|
||||
{
|
||||
isFly = isFlyMode(args[0]);
|
||||
speed = getMoveSpeed(args[1]);
|
||||
if (args.length > 2 && user.isAuthorized("essentials.speed.others"))
|
||||
//isFly = isFlyMode(args[0]);
|
||||
//speed = getMoveSpeed(args[1]);
|
||||
//if (args.length > 2 && user.isAuthorized("essentials.speed.others"))
|
||||
//{
|
||||
// speedOtherPlayers(server, user, isFly, isBypass, speed, args[2]);
|
||||
// return;
|
||||
//}
|
||||
isFly = true;
|
||||
speed = getMoveSpeed(args[0]);
|
||||
if (user.isAuthorized("essentials.speed.others"))
|
||||
{
|
||||
speedOtherPlayers(server, user, isFly, isBypass, speed, args[2]);
|
||||
speedOtherPlayers(server, user, isFly, isBypass, speed, args[1]);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (isFly)
|
||||
{
|
||||
//if (isFly)
|
||||
//{
|
||||
user.setFlySpeed(getRealMoveSpeed(speed, isFly, isBypass));
|
||||
user.sendMessage(_("moveSpeed", _("flying"), speed, user.getDisplayName()));
|
||||
}
|
||||
else
|
||||
{
|
||||
user.setWalkSpeed(getRealMoveSpeed(speed, isFly, isBypass));
|
||||
user.sendMessage(_("moveSpeed", _("walking"), speed, user.getDisplayName()));
|
||||
}
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// user.setWalkSpeed(getRealMoveSpeed(speed, isFly, isBypass));
|
||||
// user.sendMessage(_("moveSpeed", _("walking"), speed, user.getDisplayName()));
|
||||
//}
|
||||
}
|
||||
|
||||
private void speedOtherPlayers(final Server server, final CommandSender sender, final boolean isFly, final boolean isBypass, final float speed, final String target)
|
||||
|
|
|
@ -328,7 +328,7 @@ commands:
|
|||
aliases: [espawnmob,mob,emob]
|
||||
speed:
|
||||
description: Change your speed limits
|
||||
usage: /<command> [fly|walk] [speed] [player]
|
||||
usage: /<command> [speed] [player]
|
||||
aliases: [flyspeed,walkspeed,fspeed,wspeed,eflyspeed,ewalkspeed,efspeed,ewspeed,espeed]
|
||||
sudo:
|
||||
description: Make another user perform a command.
|
||||
|
|
Loading…
Reference in a new issue